# HG changeset patch # User ivo # Date 1175973867 0 # Node ID e02f7d142ce985a0fd53fc573c37c2a247b8104a # Parent 66ef3690d108506477d3107bb7121fbc452cb97a Fix segmentation fault for gray16le to gray conversion. diff -r 66ef3690d108 -r e02f7d142ce9 imgconvert.c --- a/imgconvert.c Sat Apr 07 17:37:30 2007 +0000 +++ b/imgconvert.c Sat Apr 07 19:24:27 2007 +0000 @@ -1886,7 +1886,9 @@ static void gray16le_to_gray(AVPicture *dst, const AVPicture *src, int width, int height) { - gray16_to_gray(dst, src + 1, width, height); + AVPicture tmpsrc = *src; + tmpsrc.data[0]++; + gray16_to_gray(dst, &tmpsrc, width, height); } static void gray16_to_gray16(AVPicture *dst, const AVPicture *src,