X-Git-Url: https://git.cweiske.de/enigma2.git/blobdiff_plain/d176ba17e809d7c8d917ba98efc79a12c604965e..406b024501ad0bf0473d08b345de5e94c370804b:/lib/dvb/tstools.cpp diff --git a/lib/dvb/tstools.cpp b/lib/dvb/tstools.cpp index 06e8ba0f..a9eef406 100644 --- a/lib/dvb/tstools.cpp +++ b/lib/dvb/tstools.cpp @@ -662,7 +662,8 @@ int eDVBTSTools::findNextPicture(off_t &offset, size_t &len, int &distance, int off_t new_offset = offset; size_t new_len = len; - + int first = 1; + while (distance > 0) { int dir = direction; @@ -676,8 +677,9 @@ int eDVBTSTools::findNextPicture(off_t &offset, size_t &len, int &distance, int // eDebug("we moved %d, %d to go frames (now at %llx)", dir, distance, new_offset); - if (distance >= 0) + if (distance >= 0 || first) { + first = 0; offset = new_offset; len = new_len; nr_frames += abs(dir);