Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit c867a50e authored by Martin Storsjo's avatar Martin Storsjo
Browse files

MPEG2TSWriter: Fix an off-by-one in the condition for padding

This makes a remuxed file play without any decoding warnings,
while there still were some occasional warnings with the previous
version.

Change-Id: I31d73446ded1eeb3da10783c5ef841270563ca12
parent 64b3fe55
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -934,7 +934,7 @@ void MPEG2TSWriter::writeAccessUnit(

    size_t offset = copy;
    while (offset < accessUnit->size()) {
        bool lastAccessUnit = ((accessUnit->size() - offset) < 183);
        bool lastAccessUnit = ((accessUnit->size() - offset) < 184);
        // for subsequent fragments of "buffer":
        // 0x47
        // transport_error_indicator = b0