Rob Shearman : avifil32: Fix type of variable used to store the result of ICCompress in AVIFILE_EncodeFrame .

Alexandre Julliard julliard at winehq.org
Tue Sep 30 11:16:48 CDT 2008


Module: wine
Branch: master
Commit: 171762827c36d973fc53a27d19c05e077fb24be0
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=171762827c36d973fc53a27d19c05e077fb24be0

Author: Rob Shearman <robertshearman at gmail.com>
Date:   Tue Sep 30 13:55:29 2008 +0100

avifil32: Fix type of variable used to store the result of ICCompress in AVIFILE_EncodeFrame.

(Found by PreFast.)

---

 dlls/avifil32/icmstream.c |   12 ++++++------
 1 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/dlls/avifil32/icmstream.c b/dlls/avifil32/icmstream.c
index 8ac2e33..a5b221a 100644
--- a/dlls/avifil32/icmstream.c
+++ b/dlls/avifil32/icmstream.c
@@ -821,14 +821,14 @@ static HRESULT AVIFILE_EncodeFrame(IAVIStreamImpl *This,
 
   do {
     DWORD   idxCkid = 0;
-    HRESULT hr;
+    DWORD   res;
 
-    hr = ICCompress(This->hic,icmFlags,This->lpbiCur,This->lpCur,lpbi,lpBits,
-		    &idxCkid, &idxFlags, This->lCurrent, dwRequest, dwCurQual,
-		    noPrev ? NULL:This->lpbiPrev, noPrev ? NULL:This->lpPrev);
-    if (hr == ICERR_NEWPALETTE) {
+    res = ICCompress(This->hic,icmFlags,This->lpbiCur,This->lpCur,lpbi,lpBits,
+		     &idxCkid, &idxFlags, This->lCurrent, dwRequest, dwCurQual,
+		     noPrev ? NULL:This->lpbiPrev, noPrev ? NULL:This->lpPrev);
+    if (res == ICERR_NEWPALETTE) {
       FIXME(": codec has changed palette -- unhandled!\n");
-    } else if (hr != ICERR_OK)
+    } else if (res != ICERR_OK)
       return AVIERR_COMPRESSOR;
 
     /* need to check for framesize */




More information about the wine-cvs mailing list