From 31cd397f3c944351fb2cbaafc1511f047f6ade5b Mon Sep 17 00:00:00 2001 From: Jaroslav Kysela Date: Thu, 5 Feb 2015 12:44:57 +0100 Subject: [PATCH] timeshift: reader - fix the possible wrong ctrl variable usage --- src/timeshift/timeshift_reader.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/timeshift/timeshift_reader.c b/src/timeshift/timeshift_reader.c index d83ec7fb..cd46140c 100644 --- a/src/timeshift/timeshift_reader.c +++ b/src/timeshift/timeshift_reader.c @@ -809,6 +809,7 @@ void *timeshift_reader ( void *p ) cur_speed = 100; ctrl = streaming_msg_create_code(SMT_SPEED, cur_speed); streaming_target_deliver2(ts->output, ctrl); + ctrl = NULL; /* Flush timeshift buffer to live */ if (_timeshift_flush_to_live(ts, &cur_file, &sm, &wait) == -1) @@ -837,8 +838,8 @@ void *timeshift_reader ( void *p ) pause_time = last_time; ctrl = streaming_msg_create_code(SMT_SPEED, cur_speed); streaming_target_deliver2(ts->output, ctrl); + ctrl = NULL; } - ctrl = NULL; /* Flush unwanted */ } else if (ts->ondemand && cur_file) {