Search for start code ..

On Tue, Dec 10, 2013 at 03:42:27PM +0100, Guillaume Martres wrote:
> From: Yusuke Nakamura <[email protected]>
> 
> User may cut off a weird position and send a packet from there.

A user may cut off at a weird..

> This avoids returning as invalid data immediately.

s/as//

Is the invalid data returned later?  This sure sounds like it..

> --- a/libavcodec/hevc.c
> +++ b/libavcodec/hevc.c
> @@ -2689,14 +2689,15 @@ static int decode_nal_units(HEVCContext *s, const 
> uint8_t *buf, int length)
> +            /* search start code */
> +            while (buf[0] != 0 || buf[1] != 0 || buf[2] != 1) {
> +                ++buf;
> +                --length;
> +                if (length < 4) {
> +                    av_log(s->avctx, AV_LOG_ERROR, "No start code is 
> found.\n");

s/is//

Diego
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel

Reply via email to