Permalink
Browse files

Catch first frame corrupting unsigned count

Fixes #9801

Signed-off-by: Gavin Hurlbut <ghurlbut@mythtv.org>
(cherry picked from commit c4ee599)
  • Loading branch information...
1 parent 6021234 commit 03cff208162704985d1dfe36f8a302da4f2b4251 User committed with Beirdo Nov 29, 2011
Showing with 2 additions and 1 deletion.
  1. +2 −1 mythtv/libs/libmythtv/nuppeldecoder.cpp
@@ -1129,7 +1129,8 @@ bool NuppelDecoder::GetFrame(DecodeType decodetype)
else if (frameheader.comptype == 'V')
{
lastKey = frameheader.timecode;
- framesPlayed = frameheader.timecode - 1;
+ framesPlayed = (frameheader.timecode > 0 ?
+ frameheader.timecode - 1 : 0);
if (!hasFullPositionMap)
{

0 comments on commit 03cff20

Please sign in to comment.