From: Jaroslav Kysela Date: Mon, 10 Nov 2014 18:53:41 +0000 (+0100) Subject: http streaming: DVR file - fix wrong lseek check X-Git-Tag: v4.1~790 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c3c767549bbfec3c068eb2a5814167f8f4d95412;p=thirdparty%2Ftvheadend.git http streaming: DVR file - fix wrong lseek check --- diff --git a/src/webui/webui.c b/src/webui/webui.c index eba5dbb6a..abd79b0d6 100644 --- a/src/webui/webui.c +++ b/src/webui/webui.c @@ -1172,7 +1172,7 @@ page_dvrfile(http_connection_t *hc, const char *remain, void *opaque) file_start, file_end, (size_t)st.st_size); if(file_start > 0) - if (lseek(fd, file_start, SEEK_SET)) { + if (lseek(fd, file_start, SEEK_SET) != file_start) { close(fd); return HTTP_STATUS_INTERNAL; }