diff options
| author | Max Horn | 2004-01-31 16:49:52 +0000 |
|---|---|---|
| committer | Max Horn | 2004-01-31 16:49:52 +0000 |
| commit | 41230fa999b40b6ecaa42e133f468e23effaaba1 (patch) | |
| tree | a6e8f15eb12e3b3c4ed67716c26f794cc0c006bf | |
| parent | f58e13fe4d614935aeddebf6267041241fe82cb7 (diff) | |
| download | scummvm-rg350-41230fa999b40b6ecaa42e133f468e23effaaba1.tar.gz scummvm-rg350-41230fa999b40b6ecaa42e133f468e23effaaba1.tar.bz2 scummvm-rg350-41230fa999b40b6ecaa42e133f468e23effaaba1.zip | |
cleanup (len == size)
svn-id: r12688
| -rw-r--r-- | scumm/bomp.cpp | 20 |
1 files changed, 9 insertions, 11 deletions
diff --git a/scumm/bomp.cpp b/scumm/bomp.cpp index f69a31ff24..1626493105 100644 --- a/scumm/bomp.cpp +++ b/scumm/bomp.cpp @@ -47,14 +47,13 @@ void decompressBomp(byte *dst, const byte *src, int w, int h) { } while (--h); } -void bompDecodeLine(byte *dst, const byte *src, int size) { - assert(size > 0); +void bompDecodeLine(byte *dst, const byte *src, int len) { + assert(len > 0); - int len, num; + int num; byte code, color; - len = size; - while (len) { + while (len > 0) { code = *src++; num = (code >> 1) + 1; if (num > len) @@ -71,16 +70,15 @@ void bompDecodeLine(byte *dst, const byte *src, int size) { } } -void bompDecodeLineReverse(byte *dst, const byte *src, int size) { - assert(size > 0); +void bompDecodeLineReverse(byte *dst, const byte *src, int len) { + assert(len > 0); - dst += size; + dst += len; - int len, num; + int num; byte code, color; - len = size; - while (len) { + while (len > 0) { code = *src++; num = (code >> 1) + 1; if (num > len) |
