From: David Goulet Date: Fri, 27 Sep 2013 19:18:13 +0000 (-0400) Subject: Fix: add index destruction in destroy stream call X-Git-Tag: v2.4.0-rc1~136 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=efc8a87fb1ec94af764008a13b3576e793ae288c;p=lttng-tools.git Fix: add index destruction in destroy stream call Signed-off-by: David Goulet --- diff --git a/src/bin/lttng-relayd/main.c b/src/bin/lttng-relayd/main.c index e426469a3..59888c280 100644 --- a/src/bin/lttng-relayd/main.c +++ b/src/bin/lttng-relayd/main.c @@ -802,6 +802,9 @@ static void destroy_stream(struct relay_stream *stream, vstream->total_index_received = stream->total_index_received; } + /* Cleanup index of that stream. */ + relay_index_destroy_by_stream_id(stream->stream_handle); + iter.iter.node = &stream->stream_n.node; delret = lttng_ht_del(relay_streams_ht, &iter); assert(!delret); @@ -841,8 +844,6 @@ void relay_delete_session(struct relay_command *cmd, if (stream->session == cmd->session) { destroy_stream(stream, cmd->ctf_traces_ht); } - /* Cleanup index of that stream. */ - relay_index_destroy_by_stream_id(stream->stream_handle); } /* Make this session not visible anymore. */