Commit 1bb5eb4a authored by reimar's avatar reimar

Fix buffer size check for xan_unpack which was broken by r18586


git-svn-id: file:///var/local/repositories/ffmpeg/trunk@18589 9553f0bf-9b14-0410-a0b8-cfaf0461ba5b
parent 267a5b13
......@@ -156,7 +156,7 @@ static void xan_unpack(unsigned char *dest, const unsigned char *src, int dest_l
back = ((opcode & 0x10) << 12) + 1 + bytestream_get_be16(&src);
size2 = *src++ + 5 + ((opcode & 0xc) << 6);
if (dest >= dest_end || size > dest_end - dest)
if (size + size2 > dest_end - dest)
return;
}
memcpy(dest, src, size); dest += size; src += size;
......
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