Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
darshan
darshan
Commits
246c491e
Commit
246c491e
authored
Jun 14, 2016
by
Shane Snyder
Browse files
parser shouldn't abort with no-name records
parent
fba89f42
Changes
1
Hide whitespace changes
Inline
Side-by-side
darshan-util/darshan-parser.c
View file @
246c491e
...
...
@@ -422,24 +422,35 @@ int main(int argc, char **argv)
{
char
*
mnt_pt
=
NULL
;
char
*
fs_type
=
NULL
;
char
*
rec_name
=
NULL
;
hash_entry_t
*
hfile
=
NULL
;
base_rec
=
(
struct
darshan_base_record
*
)
mod_buf
;
/* get the pathname for this record */
HASH_FIND
(
hlink
,
name_hash
,
&
(
base_rec
->
id
),
sizeof
(
darshan_record_id
),
ref
);
assert
(
ref
);
/* get mount point and fs type associated with this record */
for
(
j
=
0
;
j
<
mount_count
;
j
++
)
if
(
ref
)
{
if
(
strncmp
(
mnt_data_array
[
j
].
mnt_path
,
ref
->
name_record
->
name
,
strlen
(
mnt_data_array
[
j
].
mnt_path
))
==
0
)
rec_name
=
ref
->
name_record
->
name
;
/* get mount point and fs type associated with this record */
for
(
j
=
0
;
j
<
mount_count
;
j
++
)
{
mnt_pt
=
mnt_data_array
[
j
].
mnt_path
;
fs_type
=
mnt_data_array
[
j
].
mnt_type
;
break
;
if
(
strncmp
(
mnt_data_array
[
j
].
mnt_path
,
rec_name
,
strlen
(
mnt_data_array
[
j
].
mnt_path
))
==
0
)
{
mnt_pt
=
mnt_data_array
[
j
].
mnt_path
;
fs_type
=
mnt_data_array
[
j
].
mnt_type
;
break
;
}
}
}
else
{
if
(
i
==
DARSHAN_BGQ_MOD
)
rec_name
=
"darshan-bgq-record"
;
}
if
(
!
mnt_pt
)
mnt_pt
=
"UNKNOWN"
;
if
(
!
fs_type
)
...
...
@@ -448,7 +459,7 @@ int main(int argc, char **argv)
if
(
mask
&
OPTION_BASE
)
{
/* print the corresponding module data for this record */
mod_logutils
[
i
]
->
log_print_record
(
mod_buf
,
re
f
->
name_record
->
name
,
mod_logutils
[
i
]
->
log_print_record
(
mod_buf
,
re
c_
name
,
mnt_pt
,
fs_type
,
fd
->
mod_ver
[
i
]);
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment