Mailing List archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[linuxtv-softmpeg] MPEG header sizes



Hi Michael,

Sorry for not sending you the buffer check patch - I haven't yet connected
my machine back up to the network. I was busy last night trying to get it
working, as it still crashes :-(

I put some checks in softmpeg_handle_pes_data in softmpeg.c, as the PES
header length is read straight from the data stream (as per the spec.)
However, I found that during errored streams this length could be garbage.
In particular, it was possible for the header stream to be *longer* than the
PES packet - this caused a crash also.

I noticed empirically that the PES header length always seemed to be 14
bytes or 19 bytes - but looking at the MPEG spec it appears that it can be a
whole number of lengths depending on options. For now, I've chosen to ignore
the packet if it is smaller than 14 or larger than 19 bytes, but I'm not
sure if this is an entirely correct way of doing things.

However, I still get a crash which I cannot track down. Fortunately I
managed to record the stream that causes this, so I now have a VDR file
which I can play back and causes the decoder to crash. It's 200Mb so is too
large to put on the web (at least with my web space) so I'll see if I can
try and isolate the part of the file that causes the crash.

I *suspect* still that the stack is corrupted - for example, if I comment
out the call to the video decoder 'd->decode' in video.c I get no crash. If
I leave this call in, but make the first line of the decoder return then I
get a crash. This makes me suspect that it's either something in the audio
decoding part, or in the video buffering part, that is crashing, yet audio
plays OK (well, subject to loads of errors - lots of pops and squeaks).

Has anyone got any suggestions to help track this down?

Thanks,

Colin



-- 
Info:  To unsubscribe send a mail to ecartis@linuxtv.org with 
"unsubscribe linuxtv-softmpeg" as subject.



Home | Main Index | Thread Index