James Hawkins : msi: Only check the presence of the cabinet if the file is compressed.
Module: wine Branch: master Commit: b1507aee989b168e8c08d0202ac60e467db25871 URL: http://source.winehq.org/git/wine.git/?a=commit;h=b1507aee989b168e8c08d0202a... Author: James Hawkins <truiken(a)gmail.com> Date: Thu Nov 15 03:01:06 2007 -0600 msi: Only check the presence of the cabinet if the file is compressed. --- dlls/msi/files.c | 3 ++- dlls/msi/tests/install.c | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/dlls/msi/files.c b/dlls/msi/files.c index 5375641..812f2b0 100644 --- a/dlls/msi/files.c +++ b/dlls/msi/files.c @@ -637,7 +637,8 @@ static UINT ready_media(MSIPACKAGE *package, MSIFILE *file, struct media_info *m } } - if (mi->cabinet && GetFileAttributesW(mi->cabinet) == INVALID_FILE_ATTRIBUTES) + if (file->IsCompressed && mi->cabinet && + GetFileAttributesW(mi->cabinet) == INVALID_FILE_ATTRIBUTES) { ERR("Cabinet not found: %s\n", debugstr_w(mi->cabinet)); return ERROR_INSTALL_FAILURE; diff --git a/dlls/msi/tests/install.c b/dlls/msi/tests/install.c index fd2ff66..a11ef21 100644 --- a/dlls/msi/tests/install.c +++ b/dlls/msi/tests/install.c @@ -3536,8 +3536,8 @@ static void test_missingcab(void) todo_wine { ok(r == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %u\n", r); - ok(delete_pf("msitest\\augustus", TRUE), "File not installed\n"); } + ok(delete_pf("msitest\\augustus", TRUE), "File not installed\n"); ok(delete_pf("msitest\\caesar", TRUE), "File not installed\n"); ok(delete_pf("msitest\\maximus", TRUE), "File not installed\n"); ok(!delete_pf("msitest\\gaius", TRUE), "File installed\n"); @@ -3552,8 +3552,8 @@ static void test_missingcab(void) { ok(r == ERROR_INSTALL_FAILURE, "Expected ERROR_INSTALL_FAILURE, got %u\n", r); ok(!delete_pf("msitest\\maximus", TRUE), "File installed\n"); + ok(!delete_pf("msitest\\augustus", TRUE), "File installed\n"); } - ok(!delete_pf("msitest\\augustus", TRUE), "File installed\n"); ok(delete_pf("msitest\\caesar", TRUE), "File removed\n"); ok(delete_pf("msitest\\gaius", TRUE), "File removed\n"); ok(delete_pf("msitest", FALSE), "File not installed\n");
participants (1)
-
Alexandre Julliard