X-Git-Url: http://git.efficios.com/?p=babeltrace.git;a=blobdiff_plain;f=lib%2Fgraph%2Fnotification%2Fevent.c;h=4b50d7fefe5496135eff1ad29b69d75ab273d6e5;hp=6251979d266a20f845334277302a1ea18077e725;hb=44c440bc5fe8219cc17d1b786d91fd83c4c9860a;hpb=c800eb3790218d2f33df01e77ec38cbd43cc02a1 diff --git a/lib/graph/notification/event.c b/lib/graph/notification/event.c index 6251979d..4b50d7fe 100644 --- a/lib/graph/notification/event.c +++ b/lib/graph/notification/event.c @@ -84,7 +84,6 @@ struct bt_notification *bt_notification_event_create( struct bt_notification_event *notification = NULL; struct bt_event *event; struct bt_graph *graph; - int ret; BT_ASSERT_PRE_NON_NULL(notif_iter, "Notification iterator"); BT_ASSERT_PRE_NON_NULL(event_class, "Event class"); @@ -104,20 +103,6 @@ struct bt_notification *bt_notification_event_create( goto error; } - /* - * Set packet's properties. This can fail so it happens before - * creating the notification below. We freeze it after we know - * this function succeeds. - */ - if (unlikely(!packet->props_are_set)) { - ret = bt_packet_set_properties(packet); - if (ret) { - BT_LIB_LOGE("Cannot update packet's properties: " - "%![prev-packet-]+a", packet); - goto error; - } - } - /* * Create notification from pool _after_ we have everything * (in this case, a valid event object) so that we never have an @@ -145,7 +130,7 @@ struct bt_notification *bt_notification_event_create( BT_ASSERT(!notification->event); notification->event = event; bt_packet_set_is_frozen(packet, true); - bt_packet_validate_properties(packet); + bt_event_class_freeze(event_class); BT_LOGD("Created event notification object: " "event-addr=%p, event-class-addr=%p, " "event-class-name=\"%s\", event-class-id=%" PRId64 ", "