+ ret = bt_object_pool_initialize(&graph->event_notif_pool,
+ (bt_object_pool_new_object_func) bt_notification_event_new,
+ (bt_object_pool_destroy_object_func) destroy_notification_event,
+ graph);
+ if (ret) {
+ BT_LOGE("Failed to initialize event notification pool: ret=%d",
+ ret);
+ goto error;
+ }
+
+ ret = bt_object_pool_initialize(&graph->packet_begin_notif_pool,
+ (bt_object_pool_new_object_func) bt_notification_packet_begin_new,
+ (bt_object_pool_destroy_object_func) destroy_notification_packet_begin,
+ graph);
+ if (ret) {
+ BT_LOGE("Failed to initialize packet beginning notification pool: ret=%d",
+ ret);
+ goto error;
+ }
+
+ ret = bt_object_pool_initialize(&graph->packet_end_notif_pool,
+ (bt_object_pool_new_object_func) bt_notification_packet_end_new,
+ (bt_object_pool_destroy_object_func) destroy_notification_packet_end,
+ graph);
+ if (ret) {
+ BT_LOGE("Failed to initialize packet end notification pool: ret=%d",
+ ret);
+ goto error;
+ }
+
+ graph->notifications = g_ptr_array_new_with_free_func(
+ (GDestroyNotify) notify_notification_graph_is_destroyed);