sap.c:

 * support incorrect announces that does not include parameters we don't
   parse anyway, change the corresponding msesage from Warn to Dbg.
 * convert UDP to udp, to get the right icon in the playlist
 * fixed a potential crash given away by gcc's warnings
parent 48d234df
......@@ -839,14 +839,12 @@ static int ParseConnection( vlc_object_t *p_obj, sdp_t *p_sdp )
if( psz_eof )
{
*psz_eof = 0;
psz_uri = strdup( psz_parse );
}
else
{
msg_Warn( p_obj, "unable to parse c field (3)");
return VLC_EGENERIC;
msg_Dbg( p_obj, "incorrect c field");
}
psz_uri = strdup( psz_parse );
}
......@@ -906,14 +904,12 @@ static int ParseConnection( vlc_object_t *p_obj, sdp_t *p_sdp )
if( psz_eof )
{
*psz_eof = '\0';
psz_proto = strdup( psz_parse );
}
else
{
msg_Warn( p_obj, "unable to parse m field (3)");
return VLC_EGENERIC;
msg_Dbg( p_obj, "incorrect m field");
}
psz_proto = strdup( psz_parse );
}
if( psz_proto && !strncmp( psz_proto, "RTP/AVP", 7 ) )
......@@ -921,6 +917,11 @@ static int ParseConnection( vlc_object_t *p_obj, sdp_t *p_sdp )
free( psz_proto );
psz_proto = strdup( "rtp" );
}
if( psz_proto && !strncmp( psz_proto, "UDP", 3 ) )
{
free( psz_proto );
psz_proto = strdup( "udp" );
}
/* FIXME: HTTP support */
......@@ -954,7 +955,7 @@ static sdp_t * ParseSDP( vlc_object_t *p_obj, char* psz_sdp )
if( psz_sdp == NULL )
{
return VLC_EGENERIC;
return NULL;
}
if( psz_sdp[0] != 'v' || psz_sdp[1] != '=' )
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment