[vlc-devel] [vlc-commits] xiph demux: _correctly_ remove warning
Laurent Aimar
fenrir at elivagar.org
Tue Feb 22 17:41:16 CET 2011
On Tue, Feb 22, 2011 at 03:13:59PM +0100, Mirsal Ennaime wrote:
> vlc | branch: master | Mirsal Ennaime <mirsal at mirsal.fr> | Tue Feb 22 15:11:28 2011 +0100| [020620ba69b19600fe7b06c8fa20cbfe5b50fe49] | committer: Mirsal Ennaime
>
> xiph demux: _correctly_ remove warning
>
> Thanks, j-b
>
> > http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=020620ba69b19600fe7b06c8fa20cbfe5b50fe49
> ---
>
> modules/demux/xiph.h | 4 +++-
> 1 files changed, 3 insertions(+), 1 deletions(-)
>
> diff --git a/modules/demux/xiph.h b/modules/demux/xiph.h
> index 0ce5dc4..9b7e21c 100644
> --- a/modules/demux/xiph.h
> +++ b/modules/demux/xiph.h
> @@ -48,8 +48,10 @@ static inline int xiph_SplitHeaders(unsigned packet_size[], void *packet[], unsi
> }
> size += packet_size[i];
> }
> - if (end - current < (int)size)
> +
> + if ((uint8_t)(end - current) < size)
> return VLC_EGENERIC;
(uint8_t) seems *highly* suspicious (read: there is probably a security
issue where there was none...)
--
fenrir
More information about the vlc-devel
mailing list