X-Git-Url: http://git.efficios.com/?a=blobdiff_plain;f=plugins%2Fctf%2Flttng-live%2Fdata-stream.c;h=1692715139084bd1c70f0a1b3f7c495faec9e02d;hb=40f4ba76dd6f9508ca51b6220eaed57632281a07;hp=7bf4c29e18cbb39091509ac2c71100c56e0f7cd0;hpb=50842bdc4c21f3de2b63e29cdac730af8b6dcca6;p=babeltrace.git diff --git a/plugins/ctf/lttng-live/data-stream.c b/plugins/ctf/lttng-live/data-stream.c index 7bf4c29e..16927151 100644 --- a/plugins/ctf/lttng-live/data-stream.c +++ b/plugins/ctf/lttng-live/data-stream.c @@ -34,7 +34,7 @@ #include #include #include "../common/notif-iter/notif-iter.h" -#include +#include #include "data-stream.h" @@ -72,8 +72,8 @@ enum bt_notif_iter_medium_status medop_request_bytes( } static -struct bt_stream *medop_get_stream( - struct bt_stream_class *stream_class, +const struct bt_stream *medop_get_stream( + const struct bt_stream_class *stream_class, uint64_t stream_id, void *data) { struct lttng_live_stream_iterator *lttng_live_stream = data; @@ -181,7 +181,7 @@ struct lttng_live_stream_iterator *lttng_live_stream_iterator_create( stream->buflen = session->lttng_live->max_query_size; ret = lttng_live_add_port(lttng_live, stream); - assert(!ret); + BT_ASSERT(!ret); bt_list_add(&stream->node, &trace->streams); @@ -206,17 +206,17 @@ void lttng_live_stream_iterator_destroy(struct lttng_live_stream_iterator *strea lttng_live = stream->trace->session->lttng_live; ret = lttng_live_remove_port(lttng_live, stream->port); - assert(!ret); + BT_ASSERT(!ret); if (stream->stream) { - BT_PUT(stream->stream); + BT_OBJECT_PUT_REF_AND_RESET(stream->stream); } if (stream->notif_iter) { bt_notif_iter_destroy(stream->notif_iter); } g_free(stream->buf); - BT_PUT(stream->packet_end_notif_queue); + BT_OBJECT_PUT_REF_AND_RESET(stream->packet_end_notif_queue); bt_list_del(&stream->node); /* * Ensure we poke the trace metadata in the future, which is