[MPlayer-users] MPlayer [demuxer] crashes on one particular RTSP stream

Roberto Togni r_togni at tiscali.it
Tue Jul 6 23:10:53 CEST 2004


On 2004.07.06 21:55, Roberto Togni wrote:
> On 2004.07.06 14:34, Josh Goes wrote:
>> Hi all.
>> 
>> I have spoken to a few people about this and all receive this  
>> problem.
>> Trying to play the following RTSP stream results in MPlayer  
>> crashing:
>> rtsp://play.rbn.com.au/broadcast/bb4_broadband.rm
>>
> Confirmed with current cvs, problem in realrtsp code, asmrp.c:558  
> (but probably is on line 555), abort().
> 
> Crashes also xine and realplayer8, start playing with realplayer beta  
> from helix, but have random crashes.
> 
>> Thanks for your time!
Got the problem.
The server sends back a ruleset with a sintax error and asmrp.c abort  
on it.

There are two problems:
1 - trash server, should not send broken rules
2 - never abort() in mplayer code (i know, this is imported code and i  
know, i imported it :) ).

This is the broken ruleset
#($Bandwidth >= 117959) && ($Bandwidth < 192959), 
AverageBandwidth=117959,Priority=9;#($Bandwidth >= 117959) &&  
($Bandwidth < 192959),AverageBandwidth=0,Priority=5,OnDepend=\"0\";# 
($Bandwidth < 117959),TimestampDelivery=T,DropByN=T,priority=9;# 
($Bandwidth >= 192959),AverageBandwidth=192959,Priority=9;,OnDepend=\"3 
\";

According to the grammar from asmrp.h

   rule_book  = { '#' rule ';'}
   rule       = condition {',' assignment}
   assignment = id '=' const
   const      = ( number | string )
   condition  = comp_expr { ( '&&' | '||' ) comp_expr }
   comp_expr  = operand { ( '<' | '<=' | '==' | '>=' | '>' ) operand }
   operand    = ( '$' id | num | '(' condition ')' )

the comma after semicolon on 2nd line from bottom is not allowed.

Attached you can find a quick and dirty workaround for this specific  
stream, that simply ingnores a comma at the beginning of a rule (except  
from the first rule, because of the place where i put the check).

Feel free to use it, but please update to CVS (at least to pre4)  
because a lot of buffer overflows in realrtsp code were fixed in pre4.

The stream works perfectly with mplayer (no much to see, just some  
people sleeping), we don't have all that nice random crashes like  
realplayer beta :)

Ciao,
 Roberto
-------------- next part --------------
A non-text attachment was scrubbed...
Name: realhack.diff
Type: text/x-patch
Size: 507 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-users/attachments/20040706/29265974/attachment.bin>


More information about the MPlayer-users mailing list