[PATCH v3 2/2] ntdll: Don't use find_basename_module for sxs dlls

Fabian Maurer dark.shadow4 at web.de
Wed Jun 12 15:59:26 CDT 2019


Signed-off-by: Fabian Maurer <dark.shadow4 at web.de>
---
 dlls/kernel32/tests/actctx.c | 4 ----
 dlls/ntdll/loader.c          | 9 ++++++---
 2 files changed, 6 insertions(+), 7 deletions(-)

diff --git a/dlls/kernel32/tests/actctx.c b/dlls/kernel32/tests/actctx.c
index 6929fd4365..ee7c71bb5c 100644
--- a/dlls/kernel32/tests/actctx.c
+++ b/dlls/kernel32/tests/actctx.c
@@ -3281,12 +3281,10 @@ static void test_two_dlls_at_same_time(void)
     if (!fill_sxs_info(&dll_2, "2", "dummy.dll", two_dll_manifest_exe, two_dll_manifest_dll))
         goto cleanup;

-    todo_wine
     ok(dll_1.module != dll_2.module, "Libraries are the same\n");
     dll_1.get_path(path1, sizeof(path1));
     ok(strcmp(path1, dll_1.path_dll) == 0, "Got '%s', expected '%s'\n", path1, dll_1.path_dll);
     dll_2.get_path(path2, sizeof(path2));
-    todo_wine
     ok(strcmp(path2, dll_2.path_dll) == 0, "Got '%s', expected '%s'\n", path2, dll_2.path_dll);

 cleanup:
@@ -3319,10 +3317,8 @@ static void test_one_sxs_and_one_local_1(void)
     if (!fill_sxs_info(&dll, "1", "dummy.dll", two_dll_manifest_exe, two_dll_manifest_dll))
         goto cleanup;

-    todo_wine
     ok(dll.module != module, "Libraries are the same\n");
     dll.get_path(path1, sizeof(path1));
-    todo_wine
     ok(strcmp(path1, dll.path_dll) == 0, "Got '%s', expected '%s'\n", path1, dll.path_dll);
     get_path(path2, sizeof(path2));
     ok(strcmp(path2, path_dll_local) == 0, "Got '%s', expected '%s'\n", path2, path_dll_local);
diff --git a/dlls/ntdll/loader.c b/dlls/ntdll/loader.c
index a90167fdf2..ca30ae05e6 100644
--- a/dlls/ntdll/loader.c
+++ b/dlls/ntdll/loader.c
@@ -2710,10 +2710,13 @@ static NTSTATUS find_dll_file( const WCHAR *load_path, const WCHAR *libname,
     if (!contains_path( libname ))
     {
         WCHAR *fullname = NULL;
+        NTSTATUS status_actctx = find_actctx_dll( libname, &fullname );
+        if (status_actctx != STATUS_SUCCESS)
+        {
+            if ((*pwm = find_basename_module( libname )) != NULL) goto done;
+        }
+        status = status_actctx;

-        if ((*pwm = find_basename_module( libname )) != NULL) goto done;
-
-        status = find_actctx_dll( libname, &fullname );
         if (status == STATUS_SUCCESS)
         {
             TRACE ("found %s for %s\n", debugstr_w(fullname), debugstr_w(libname) );
--
2.22.0




More information about the wine-devel mailing list