Commit c1c81073 authored by Pavlov Konstantin's avatar Pavlov Konstantin

Fix for [oCERT-2008-004] multiple speex implementations insufficient boundary...

Fix for [oCERT-2008-004] multiple speex implementations insufficient boundary checks. Patch by Eren Türkay
(cherry picked from commit 8060b345)
parent f6511af8
...@@ -332,7 +332,7 @@ static int ProcessInitialHeader( decoder_t *p_dec, ogg_packet *p_oggpacket ) ...@@ -332,7 +332,7 @@ static int ProcessInitialHeader( decoder_t *p_dec, ogg_packet *p_oggpacket )
msg_Err( p_dec, "cannot read Speex header" ); msg_Err( p_dec, "cannot read Speex header" );
return VLC_EGENERIC; return VLC_EGENERIC;
} }
if( p_header->mode >= SPEEX_NB_MODES ) if( p_header->mode >= SPEEX_NB_MODES || p_header->mode < 0 )
{ {
msg_Err( p_dec, "mode number %d does not (yet/any longer) exist in " msg_Err( p_dec, "mode number %d does not (yet/any longer) exist in "
"this version of libspeex.", p_header->mode ); "this version of libspeex.", p_header->mode );
......
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