Mercurial > libavcodec.hg
changeset 9491:28978a75c865 libavcodec
Cosmetics to improve xan_unpack readability
author | reimar |
---|---|
date | Fri, 17 Apr 2009 19:14:11 +0000 |
parents | 9999ab77829b |
children | bdb94921332a |
files | xan.c |
diffstat | 1 files changed, 4 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/xan.c Fri Apr 17 19:07:16 2009 +0000 +++ b/xan.c Fri Apr 17 19:14:11 2009 +0000 @@ -140,22 +140,22 @@ size = opcode & 3; + back = ((opcode & 0x60) << 3) + *src++ + 1; size2 = ((opcode & 0x1c) >> 2) + 3; - back = ((opcode & 0x60) << 3) + *src++ + 1; } else if ( (opcode & 0x40) == 0 ) { size = *src >> 6; + back = (bytestream_get_be16(&src) & 0x3fff) + 1; size2 = (opcode & 0x3f) + 4; - back = (bytestream_get_be16(&src) & 0x3fff) + 1; } else { size = opcode & 3; - back = ((opcode & 0x10) << 12) + 1 + bytestream_get_be16(&src); - size2 = *src++ + 5 + ((opcode & 0xc) << 6); + back = ((opcode & 0x10) << 12) + bytestream_get_be16(&src) + 1; + size2 = ((opcode & 0x0c) << 6) + *src++ + 5; if (size + size2 > dest_end - dest) return; }