From: Jaroslav Kysela Date: Wed, 20 Jan 2016 15:22:34 +0000 (+0100) Subject: timeshift: fix wrong time position when LIVE, fixes #3505 X-Git-Tag: v4.2.1~1139 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=735cd18fc75760f4d6974c430c29d9ef5c6e5b18;p=thirdparty%2Ftvheadend.git timeshift: fix wrong time position when LIVE, fixes #3505 --- diff --git a/src/timeshift/timeshift_reader.c b/src/timeshift/timeshift_reader.c index bb49d871e..4e625518c 100644 --- a/src/timeshift/timeshift_reader.c +++ b/src/timeshift/timeshift_reader.c @@ -483,10 +483,14 @@ static void timeshift_fill_status start = _timeshift_first_time(ts, &active); end = ts->buf_time; - if (current_time < 0) - current_time = 0; - if (current_time > end) + if (ts->state <= TS_LIVE) { current_time = end; + } else { + if (current_time < 0) + current_time = 0; + if (current_time > end) + current_time = end; + } status->full = ts->full; tvhtrace("timeshift", "ts %d status start %"PRId64" end %"PRId64 " current %"PRId64" state %d",