[MPlayer-cvslog] r36641 - trunk/libmpdemux/demux_real.c

Reimar Döffinger Reimar.Doeffinger at gmx.de
Mon Jan 20 20:35:04 CET 2014


On Sun, Jan 19, 2014 at 04:12:47PM +0100, rtogni wrote:
> @@ -630,23 +639,26 @@ static int demux_real_fill_buffer(demuxe
>  	return 0;
>      }
>      if (len < 12){
> +    	unsigned int idx_streamid;
>  	mp_msg(MSGT_DEMUX, MSGL_V,"%08X: packet v%d len=%d  \n",(int)demuxer->filepos,(int)version,(int)len);
>  	mp_msg(MSGT_DEMUX, MSGL_WARN,"bad packet len (%d)\n", len);
>  	if ((unsigned)demuxer->video->id < MAX_STREAMS) {
> -	    if (priv->current_vpacket + 1 < priv->index_table_size[demuxer->video->id]) {
> -		stream_seek(demuxer->stream, priv->index_table[demuxer->video->id][++priv->current_vpacket].offset);
> +	    idx_streamid = priv->is_mlti ? priv->mp2rm_streamid[demuxer->video->id] : demuxer->video->id;
> +	    if (priv->current_vpacket + 1 < priv->index_table_size[idx_streamid]) {
> +		stream_seek(demuxer->stream, priv->index_table[idx_streamid][++priv->current_vpacket].offset);
>  	    }
>  	} else if ((unsigned)demuxer->audio->id < MAX_STREAMS) {
> -	    if (priv->current_apacket + 1 < priv->index_table_size[demuxer->audio->id]) {
> -		stream_seek(demuxer->stream, priv->index_table[demuxer->audio->id][++priv->current_apacket].offset);
> +	    idx_streamid = priv->is_mlti ? priv->mp2rm_streamid[demuxer->audio->id] : demuxer->video->id;

Coverity says that it thinks you meant demuxer->audio->id here, not demuxer->video->id.
Is it right?


More information about the MPlayer-cvslog mailing list