projects
/
babeltrace.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix ctf-writer: Reject enumerations containing no mappings
[babeltrace.git]
/
formats
/
ctf
/
writer
/
event-fields.c
diff --git
a/formats/ctf/writer/event-fields.c
b/formats/ctf/writer/event-fields.c
index ff970c0a86959fee1ce87ddcd2138dcb2b1b4c92..ad4fcb5a06c1ed5d3ad4e5636fdfab603f832623 100644
(file)
--- a/
formats/ctf/writer/event-fields.c
+++ b/
formats/ctf/writer/event-fields.c
@@
-179,8
+179,8
@@
struct bt_ctf_field *bt_ctf_field_create(struct bt_ctf_field_type *type)
}
type_id = bt_ctf_field_type_get_type_id(type);
}
type_id = bt_ctf_field_type_get_type_id(type);
- if (type_id <= CTF_TYPE_UNKNOWN ||
-
type_id >= NR_CTF_TYPES
) {
+ if (type_id <= CTF_TYPE_UNKNOWN ||
type_id >= NR_CTF_TYPES ||
+
bt_ctf_field_type_validate(type)
) {
goto error;
}
goto error;
}
This page took
0.024422 seconds
and
4
git commands to generate.