[PATCH] make rm demuxer skip too short packages
Hello, this is a hack for bug #930 (rtsp://real.zmml.uni-bremen.de/lecture/extern/nachh/003.rm not working). The problem is that there is a very short packet that MPlayer interprets as audio and overreads, and thus getting completely confused. Attached patch "fixes" it the lazy way by ignoring audio packets smaller than 256 bytes. This probably only avoids the problem though: firstly I think the packet in question actually belongs to an extra data stream and not the audio stream. Secondly the code that gives the audio packets some special treatment ideally should be fixed to always read exactly the size of the packet, not more or less. Comments? Greetings, Reimar Döffinger
Il Sunday 04 November 2007 15:19:09 Reimar Döffinger ha scritto:
Hello, this is a hack for bug #930 (rtsp://real.zmml.uni-bremen.de/lecture/extern/nachh/003.rm not working). The problem is that there is a very short packet that MPlayer interprets as audio and overreads, and thus getting completely confused. Attached patch "fixes" it the lazy way by ignoring audio packets smaller than 256 bytes. This probably only avoids the problem though: firstly I think the packet in question actually belongs to an extra data stream and not the audio stream. Secondly the code that gives the audio packets some special treatment ideally should be fixed to always read exactly the size of the packet, not more or less. Comments?
Greetings, Reimar Döffinger
IMO it's better keeping the bug open that committing hacks that don't have a plausible reason to exist
On Sun, 4 Nov 2007 15:19:09 +0100 Reimar Döffinger <Reimar.Doeffinger@stud.uni-karlsruhe.de> wrote:
Hello, this is a hack for bug #930 (rtsp://real.zmml.uni-bremen.de/lecture/extern/nachh/003.rm not working). The problem is that there is a very short packet that MPlayer interprets as audio and overreads, and thus getting completely confused. Attached patch "fixes" it the lazy way by ignoring audio packets smaller than 256 bytes. This probably only avoids the problem though: firstly I think the packet in question actually belongs to an extra data stream and not the audio stream. Secondly the code that gives the audio packets some special treatment ideally should be fixed to always read exactly the size of the packet, not more or less. Comments?
Bug fixed, the problem was in the realrtsp stream code (the short packet got id=0 instead of id=2). I'll address the overread problem anyway, but the threshold for skipping the packet will have to depend on the interleaver used. Ciao, Roberto -- Better is the enemy of good enough.
participants (3)
-
Nico Sabbi -
Reimar Döffinger -
Roberto Togni