X-Git-Url: http://git.efficios.com/?p=babeltrace.git;a=blobdiff_plain;f=tests%2Flib%2Ftest_remove_destruction_listener_in_destruction_listener.c;h=2cc1b76c5de277d0f3799c84dd552e696da46bc0;hp=7bf4713365368fcdb8623cb6cde06072930ba8c8;hb=a3f0c7db90f4cfc81090a83a7442b7bc624d5789;hpb=fca28f7526e7f67c7314df3a113470e7bd109062 diff --git a/tests/lib/test_remove_destruction_listener_in_destruction_listener.c b/tests/lib/test_remove_destruction_listener_in_destruction_listener.c index 7bf47133..2cc1b76c 100644 --- a/tests/lib/test_remove_destruction_listener_in_destruction_listener.c +++ b/tests/lib/test_remove_destruction_listener_in_destruction_listener.c @@ -240,18 +240,19 @@ bt_component_class_initialize_method_status hello_init( } static -bt_component_class_message_iterator_next_method_status hello_iter_next( +bt_message_iterator_class_next_method_status hello_iter_next( bt_self_message_iterator *message_iterator, bt_message_array_const msgs, uint64_t capacity, uint64_t *count) { BT_ASSERT(false); - return BT_COMPONENT_CLASS_MESSAGE_ITERATOR_NEXT_METHOD_STATUS_OK; + return BT_MESSAGE_ITERATOR_CLASS_NEXT_METHOD_STATUS_OK; } int main(int argc, char **argv) { bt_graph *graph; + bt_message_iterator_class *msg_iter_cls; bt_component_class_source *source_cc; bt_component_class_set_method_status set_method_status; bt_graph_add_component_status add_component_status; @@ -259,7 +260,10 @@ int main(int argc, char **argv) plan_tests(NR_TESTS); - source_cc = bt_component_class_source_create("Hello", hello_iter_next); + msg_iter_cls = bt_message_iterator_class_create(hello_iter_next); + BT_ASSERT(msg_iter_cls); + + source_cc = bt_component_class_source_create("Hello", msg_iter_cls); BT_ASSERT(source_cc); set_method_status = bt_component_class_source_set_initialize_method( @@ -276,6 +280,7 @@ int main(int argc, char **argv) bt_component_source_put_ref(source); bt_component_class_source_put_ref(source_cc); + bt_message_iterator_class_put_ref(msg_iter_cls); bt_graph_put_ref(graph); return exit_status();