From d3aac146d0800fe9820d51e5b9fa52e7543c1237 Mon Sep 17 00:00:00 2001 From: Julien Desfossez Date: Mon, 24 Feb 2014 13:02:19 -0500 Subject: [PATCH] Fix: wrong condition on startup for low-activity streams If we only received and sent one index, we should not be in the retry condition. The rstream->total_index_received == vstream->last_sent_index is checked before. Signed-off-by: Julien Desfossez Signed-off-by: David Goulet --- src/bin/lttng-relayd/live.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/bin/lttng-relayd/live.c b/src/bin/lttng-relayd/live.c index c60f7e4c9..468a7e587 100644 --- a/src/bin/lttng-relayd/live.c +++ b/src/bin/lttng-relayd/live.c @@ -1206,7 +1206,7 @@ static int check_index_status(struct relay_viewer_stream *vstream, index->status = htobe32(LTTNG_VIEWER_INDEX_INACTIVE); index->timestamp_end = htobe64(rstream->beacon_ts_end); goto index_ready; - } else if (rstream->total_index_received <= vstream->last_sent_index + } else if (rstream->total_index_received < vstream->last_sent_index && !vstream->close_write_flag) { /* * Reader and writer are working in the same tracefile, so we care -- 2.34.1