X-Git-Url: http://git.efficios.com/?p=babeltrace.git;a=blobdiff_plain;f=src%2Flib%2Ftrace-ir%2Fevent-class.c;h=22211cd1aae8a32d02d2801d5222bf06a01e01aa;hp=ba79f28b6ff7ca1eb5865f05e87b89216e04d426;hb=17f3083a0b4d318d3303c8a5bfa63db6a874ec73;hpb=6ecdcca3de0dea694cdfb252160c7939f7dc2ef1 diff --git a/src/lib/trace-ir/event-class.c b/src/lib/trace-ir/event-class.c index ba79f28b..22211cd1 100644 --- a/src/lib/trace-ir/event-class.c +++ b/src/lib/trace-ir/event-class.c @@ -178,6 +178,7 @@ end: struct bt_event_class *bt_event_class_create( struct bt_stream_class *stream_class) { + BT_ASSERT_PRE_NO_ERROR(); BT_ASSERT_PRE_NON_NULL(stream_class, "Stream class"); BT_ASSERT_PRE(stream_class->assigns_automatic_event_class_id, "Stream class does not automatically assigns event class IDs: " @@ -189,6 +190,7 @@ struct bt_event_class *bt_event_class_create( struct bt_event_class *bt_event_class_create_with_id( struct bt_stream_class *stream_class, uint64_t id) { + BT_ASSERT_PRE_NO_ERROR(); BT_ASSERT_PRE(!stream_class->assigns_automatic_event_class_id, "Stream class automatically assigns event class IDs: " "%![sc-]+S", stream_class); @@ -204,6 +206,7 @@ const char *bt_event_class_get_name(const struct bt_event_class *event_class) enum bt_event_class_set_name_status bt_event_class_set_name( struct bt_event_class *event_class, const char *name) { + BT_ASSERT_PRE_NO_ERROR(); BT_ASSERT_PRE_NON_NULL(event_class, "Event class"); BT_ASSERT_PRE_NON_NULL(name, "Name"); BT_ASSERT_PRE_DEV_EVENT_CLASS_HOT(event_class); @@ -251,6 +254,7 @@ enum bt_event_class_set_emf_uri_status bt_event_class_set_emf_uri( struct bt_event_class *event_class, const char *emf_uri) { + BT_ASSERT_PRE_NO_ERROR(); BT_ASSERT_PRE_NON_NULL(event_class, "Event class"); BT_ASSERT_PRE_NON_NULL(emf_uri, "EMF URI"); BT_ASSERT_PRE_DEV_EVENT_CLASS_HOT(event_class); @@ -304,6 +308,7 @@ bt_event_class_set_specific_context_field_class( .event_payload = NULL, }; + BT_ASSERT_PRE_NO_ERROR(); BT_ASSERT_PRE_NON_NULL(event_class, "Event class"); BT_ASSERT_PRE_NON_NULL(field_class, "Field class"); BT_ASSERT_PRE_DEV_EVENT_CLASS_HOT(event_class); @@ -368,6 +373,7 @@ bt_event_class_set_payload_field_class( .event_payload = field_class, }; + BT_ASSERT_PRE_NO_ERROR(); BT_ASSERT_PRE_NON_NULL(event_class, "Event class"); BT_ASSERT_PRE_NON_NULL(field_class, "Field class"); BT_ASSERT_PRE_DEV_EVENT_CLASS_HOT(event_class);