-
Notifications
You must be signed in to change notification settings - Fork 740
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
emulators/wine-devel: Unbreak WoW64 again
Restore files/patch-dlls_ntdll_unix_loader.c which we "lost" with the update to Wine 9.0 by means of an adjusted version. PR: 278427 Obtained from: Alex S <iwtcex@gmail.com> in PR 278525
- Loading branch information
Gerald Pfeifer
authored and
Gerald Pfeifer
committed
May 16, 2024
1 parent
1b08b51
commit 3f7e010
Showing
2 changed files
with
25 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
--- dlls/ntdll/unix/loader.c.orig 2024-04-05 17:03:05 UTC | ||
+++ dlls/ntdll/unix/loader.c | ||
@@ -480,6 +480,21 @@ char *get_alternate_wineloader( WORD machine ) | ||
|
||
if (machine == current_machine) return NULL; | ||
|
||
+ char* wineserver_path = getenv("WINESERVER"); | ||
+ if (wineserver_path != NULL && wineserver_path[0] == '/') { | ||
+ char* s = remove_tail(wineserver_path, "server"); | ||
+ if (s != NULL) { | ||
+ if (machine == IMAGE_FILE_MACHINE_AMD64) { | ||
+ ret = malloc(strlen(s) + 3); | ||
+ strcpy(ret, s); | ||
+ strcat(ret, "64"); | ||
+ } else { | ||
+ ret = s; | ||
+ } | ||
+ return ret; | ||
+ } | ||
+ } | ||
+ | ||
/* try the 64-bit loader */ | ||
if (current_machine == IMAGE_FILE_MACHINE_I386 && machine == IMAGE_FILE_MACHINE_AMD64) | ||
{ |