Module: wine
Branch: master
Commit: 88a97daa718ae30bacf05f1e2682ec13e032ac96
URL: http://source.winehq.org/git/wine.git/?a=commit;h=88a97daa718ae30bacf05f1e2…
Author: Rob Shearman <robertshearman(a)gmail.com>
Date: Sun Aug 17 18:29:02 2008 +0100
msrle32: Fix uses of arithmetic operators on Boolean types in MSRLE32_CompressRLE4Line and MSRLE32_CompressRLE8Line.
The "extra_byte" variable is used as though it contains an integer
rather than a TRUE/FALSE value so make it into an integer.
---
dlls/msrle32/msrle32.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/dlls/msrle32/msrle32.c b/dlls/msrle32/msrle32.c
index 4f0226a..e5d2d5b 100644
--- a/dlls/msrle32/msrle32.c
+++ b/dlls/msrle32/msrle32.c
@@ -395,7 +395,7 @@ static INT MSRLE32_CompressRLE4Line(const CodecInfo *pi, const WORD *lpP,
INT i;
INT size = min(count, 254);
int bytes = ((size + 1) & (~1)) / 2;
- BOOL extra_byte = bytes & 0x01;
+ int extra_byte = bytes & 0x01;
*lpSizeImage += 2 + bytes + extra_byte;
assert(((*lpSizeImage) % 2) == 0);
@@ -488,7 +488,7 @@ static INT MSRLE32_CompressRLE8Line(const CodecInfo *pi, const WORD *lpP,
while (count > 2) {
INT i;
INT size = min(count, 255);
- BOOL extra_byte = size % 2;
+ int extra_byte = size % 2;
*lpSizeImage += 2 + size + extra_byte;
count -= size;