[FFmpeg-devel] [PATCH] add put_bits_long to avoid undefined behaviour in put_bits

Diego Biurrun diego
Tue Aug 25 00:12:37 CEST 2009


On Mon, Aug 24, 2009 at 09:43:53PM +0200, matthieu castet wrote:
> 
> --- libavcodec/put_bits.h	(r?vision 19681)
> +++ libavcodec/put_bits.h	(copie de travail)
> @@ -259,6 +259,22 @@
>  
> +static inline void put_bits_long(PutBitContext *s, int n, unsigned int value)
> +{
> +    if(n<=31) {

  if (n <= 31) {

Diego



More information about the ffmpeg-devel mailing list