From fc10f8f84f21d40e59ed785b8ee3082448853ac5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20P=C3=B6schel?= Date: Thu, 31 Dec 2015 12:30:11 +0100 Subject: [PATCH] MPEG VideoBuffer: fix search range --- src/mpegparser/MPEGVideoBuffer.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mpegparser/MPEGVideoBuffer.cpp b/src/mpegparser/MPEGVideoBuffer.cpp index 67982b0ad..99b6f03a0 100644 --- a/src/mpegparser/MPEGVideoBuffer.cpp +++ b/src/mpegparser/MPEGVideoBuffer.cpp @@ -44,7 +44,7 @@ int32_t MPEGVideoBuffer::FindStartCode(uint32_t startPos){ if(window < 4) //Make sure we have enough bytes to search. return -1; - for(unsigned int i = startPos; i < (window - 3); i++){ + for(unsigned int i = startPos; i < (startPos + window - 3); i++){ CircBuffer& buf = *myBuffer; binary a,b,c,d; a = buf[i];