Ticket #1768: assemble_psip_off_by_one_error.diff

File assemble_psip_off_by_one_error.diff, 714 bytes (added by Janne <janne-mythtv@…>, 18 years ago)
  • libs/libmythtv/mpeg/mpegstreamdata.cpp

    old new PSIPTable* MPEGStreamData::AssemblePSIP( 
    199199        PSIPTable* psip = new PSIPTable(*partial);
    200200
    201201        // Advance to the next packet
    202         uint packetStart = partial->PSIOffset() + psip->SectionLength();
     202        // pesdata starts only at PSIOffset()+1
     203        uint packetStart = partial->PSIOffset() + 1 + psip->SectionLength();
    203204        if (packetStart < partial->TSSizeInBuffer())
    204205        {
    205206            if (partial->pesdata()[psip->SectionLength()] != 0xff)