James Hawkins : cabinet: Pass the session Error to FDICopy.

Alexandre Julliard julliard at wine.codeweavers.com
Fri Aug 24 05:24:47 CDT 2007


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

Author: James Hawkins <truiken at gmail.com>
Date:   Thu Aug 23 14:20:52 2007 -0700

cabinet: Pass the session Error to FDICopy.

---

 dlls/cabinet/cabinet_main.c  |    3 +--
 dlls/cabinet/tests/extract.c |    2 +-
 2 files changed, 2 insertions(+), 3 deletions(-)

diff --git a/dlls/cabinet/cabinet_main.c b/dlls/cabinet/cabinet_main.c
index 8b3c621..aa46cf0 100644
--- a/dlls/cabinet/cabinet_main.c
+++ b/dlls/cabinet/cabinet_main.c
@@ -306,7 +306,6 @@ HRESULT WINAPI Extract(SESSION *dest, LPCSTR szCabName)
 {
     HRESULT res = S_OK;
     HFDI hfdi;
-    ERF erf;
     char *str, *path, *name;
 
     TRACE("(%p, %s)\n", dest, szCabName);
@@ -319,7 +318,7 @@ HRESULT WINAPI Extract(SESSION *dest, LPCSTR szCabName)
                      fdi_close,
                      fdi_seek,
                      cpuUNKNOWN,
-                     &erf);
+                     &dest->Error);
 
     if (!hfdi)
         return E_FAIL;
diff --git a/dlls/cabinet/tests/extract.c b/dlls/cabinet/tests/extract.c
index ad93fb8..b9df804 100644
--- a/dlls/cabinet/tests/extract.c
+++ b/dlls/cabinet/tests/extract.c
@@ -597,10 +597,10 @@ static void test_Extract(void)
            "Expected HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND), got %08x\n", res);
         ok(session.Error.erfOper == FDIERROR_CABINET_NOT_FOUND,
            "Expected FDIERROR_CABINET_NOT_FOUND, got %d\n", session.Error.erfOper);
-        ok(session.Error.fError == TRUE, "Expected TRUE, got %d\n", session.Error.fError);
     }
     ok(session.FileSize == 0, "Expected 0, got %d\n", session.FileSize);
     ok(session.Error.erfType == 0, "Expected 0, got %d\n", session.Error.erfType);
+    ok(session.Error.fError == TRUE, "Expected TRUE, got %d\n", session.Error.fError);
     ok(session.FileCount == 0, "Expected 0, got %d\n", session.FileCount);
     ok(session.Operation == (EXTRACT_FILLFILELIST | EXTRACT_EXTRACTFILES),
        "Expected EXTRACT_FILLFILELIST | EXTRACT_EXTRACTFILES, got %d\n", session.Operation);




More information about the wine-cvs mailing list