Compare commits

..

9 Commits

Author SHA1 Message Date
Sebastian Lackner
154a80f8be Release 2.10-3 (macOS preloader fixes). 2017-06-18 18:21:12 +02:00
Sebastian Lackner
dfdeb2e61a loader-OSX_Preloader: Add PAGEZERO section for wine-preloader executable.
For wine64-preloader we already do that, but apparently there are also kernel
versions which enforce a PAGEZERO section for 32-bit executables.

(cherry picked from commit 907dc4eae6)
2017-06-17 21:03:13 +02:00
Sebastian Lackner
abb1f3201c Release 2.10-2 (macOS preloader fixes). 2017-06-16 00:50:52 +02:00
Sebastian Lackner
0ef6e01258 loader-OSX_Preloader: Fall back to MAP_FIXED if address hint is ignored.
This should get rid of preloader warnings on old versions of macOS.
Thanks to Gijs Vermeulen for help with debugging and testing this patch.

Ideally, we would like to use vm_allocate, but since the preloader runs
very early during the startup of the process, we don't have all required
libc functions available. Also, we don't want to reimplement it ourself,
which would be very unreliable in practice.

For now, lets just use mincore() to check if there are any other pages
mapped within the area, and then fallback to MAP_FIXED.

(cherry picked from commit f254a73e66)
2017-06-15 18:52:12 +02:00
Sebastian Lackner
256e818da5 loader-OSX_Preloader: Temporarily map address ranges needed for Wine builtin DLLs.
(cherry picked from commit 463f2b02c9)
2017-06-15 05:31:20 +02:00
Sebastian Lackner
bc32032f02 loader-OSX_Preloader: Allocate pagezero for main wine binary.
This change should fix compatibility with old versions of macOS.
Thanks to Gijs Vermeulen for help with debugging and testing this patch.

Old versions of libsystem_c.dylib crash while running initializers when
the application does not contain a PAGEZERO section. This is probably
caused by an incorrect comparison against NULL instead of (void *)-1.

Unfortunately, when we just add a PAGEZERO section, we trigger the next
bug - no matter if we actually use the page at address (void *)0 or not,
it will not be used because the relocation code tries to find a memory
hole of size (highAddr - lowAddr) ~ 2GB.

We might be able to workaround this issue by manually reordering the
sections in the main executable, but for now lets just drop the fixed
image base. Please note that this introduces a risk of conflicts with
builtin DLLs, which will be resolved in the next patch.

(cherry picked from commit e9daff5bc8)
2017-06-15 05:31:05 +02:00
Sebastian Lackner
199b98a78b patchinstall.sh: Add workaround for mktemp on macOS <= 10.10.
(cherry picked from commit ecdf44fe29)
2017-06-15 05:30:50 +02:00
Sebastian Lackner
c0525850fc patchinstall.sh: Do not use 'readlink -f' to improve compatibility with macOS.
(cherry picked from commit 3a7c5ae711)
2017-06-15 05:30:33 +02:00
Sebastian Lackner
d4aa71ae9d loader-OSX_Preloader: Fix compile error with old SDK versions.
(cherry picked from commit 3fab2fbed2)
2017-06-15 05:30:13 +02:00
71 changed files with 3345 additions and 2253 deletions

View File

@@ -0,0 +1,37 @@
From 9d0f651d9cb5c3ae68810e37dd6030373c7aeab6 Mon Sep 17 00:00:00 2001
From: Nils Kuhnhenn <kuhnhenn.nils@gmail.com>
Date: Wed, 24 Aug 2016 19:56:00 +0200
Subject: oleaut32: Use variable with the correct type in LIST_FOR_EACH_ENTRY_SAFE macro.
---
dlls/oleaut32/typelib.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/dlls/oleaut32/typelib.c b/dlls/oleaut32/typelib.c
index b9318fba423..5a6dad496ed 100644
--- a/dlls/oleaut32/typelib.c
+++ b/dlls/oleaut32/typelib.c
@@ -4830,10 +4830,9 @@ static ULONG WINAPI ITypeLib2_fnRelease( ITypeLib2 *iface)
if (!ref)
{
TLBImpLib *pImpLib, *pImpLibNext;
- TLBRefType *ref_type;
+ TLBRefType *ref_type, *ref_type_next;
TLBString *tlbstr, *tlbstr_next;
TLBGuid *tlbguid, *tlbguid_next;
- void *cursor2;
int i;
/* remove cache entry */
@@ -4883,7 +4882,7 @@ static ULONG WINAPI ITypeLib2_fnRelease( ITypeLib2 *iface)
heap_free(pImpLib);
}
- LIST_FOR_EACH_ENTRY_SAFE(ref_type, cursor2, &This->ref_list, TLBRefType, entry)
+ LIST_FOR_EACH_ENTRY_SAFE(ref_type, ref_type_next, &This->ref_list, TLBRefType, entry)
{
list_remove(&ref_type->entry);
heap_free(ref_type);
--
2.13.1

View File

@@ -0,0 +1,24 @@
From 380543910f8912374a13b9773738e018bd638341 Mon Sep 17 00:00:00 2001
From: Sebastian Lackner <sebastian@fds-team.de>
Date: Sun, 11 Jun 2017 02:42:47 +0200
Subject: gdiplus: Initialize containers list in GdipCloneImage.
---
dlls/gdiplus/image.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/dlls/gdiplus/image.c b/dlls/gdiplus/image.c
index ce2194317ff..b28606e916c 100644
--- a/dlls/gdiplus/image.c
+++ b/dlls/gdiplus/image.c
@@ -1339,6 +1339,7 @@ GpStatus WINGDIPAPI GdipCloneImage(GpImage *image, GpImage **cloneImage)
result->unit = metafile->unit;
result->metafile_type = metafile->metafile_type;
result->hemf = CopyEnhMetaFileW(metafile->hemf, NULL);
+ list_init(&result->containers);
if (!result->hemf)
{
--
2.13.1

View File

@@ -1,4 +1,4 @@
From 09d62cfc4fa999eacc89af2ad414810e22c910a9 Mon Sep 17 00:00:00 2001
From 63082c3863d8be466ed14f532653ddf35e40328a Mon Sep 17 00:00:00 2001
From: Sebastian Lackner <sebastian@fds-team.de>
Date: Fri, 5 May 2017 00:18:50 +0200
Subject: advapi32/tests: Add basic tests for BuildSecurityDescriptor.
@@ -8,11 +8,11 @@ Subject: advapi32/tests: Add basic tests for BuildSecurityDescriptor.
1 file changed, 39 insertions(+)
diff --git a/dlls/advapi32/tests/security.c b/dlls/advapi32/tests/security.c
index ca5edffae5..db5a0f934c 100644
index d6ea3a19fad..c591f7b6e5f 100644
--- a/dlls/advapi32/tests/security.c
+++ b/dlls/advapi32/tests/security.c
@@ -7217,6 +7217,44 @@ static void test_GetExplicitEntriesFromAclW(void)
HeapFree(GetProcessHeap(), 0, old_acl);
@@ -7489,6 +7489,44 @@ static void test_child_token_sd(void)
HeapFree(GetProcessHeap(), 0, sd);
}
+static void test_BuildSecurityDescriptorW(void)
@@ -56,14 +56,14 @@ index ca5edffae5..db5a0f934c 100644
START_TEST(security)
{
init();
@@ -7271,6 +7309,7 @@ START_TEST(security)
@@ -7542,6 +7580,7 @@ START_TEST(security)
test_pseudo_tokens();
test_maximum_allowed();
test_token_label();
test_GetExplicitEntriesFromAclW();
+ test_BuildSecurityDescriptorW();
/* Must be the last test, modifies process token */
/* must be the last test, modifies process token */
test_token_security_descriptor();
--
2.13.1
2.12.2

View File

@@ -1,2 +1,2 @@
Fixes: Initial implementation of advapi32.BuildSecurityDescriptorW
Depends: advapi32-GetExplicitEntriesFromAclW
Depends: server-LABEL_SECURITY_INFORMATION

View File

@@ -1,4 +1,4 @@
From 510d9f43f441bc3a9723aabfd2c1cdc8737d6dcc Mon Sep 17 00:00:00 2001
From b4469d7a12637ef2b57df3f6aebbe65c9b52ef57 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
Date: Sun, 28 Aug 2016 21:56:41 +0200
Subject: advapi32: Implement GetExplicitEntriesFromAclW.
@@ -9,10 +9,10 @@ Subject: advapi32: Implement GetExplicitEntriesFromAclW.
2 files changed, 221 insertions(+), 2 deletions(-)
diff --git a/dlls/advapi32/security.c b/dlls/advapi32/security.c
index e36792cff4..b305947347 100644
index 7e41c0a7361..ccd0bf64cab 100644
--- a/dlls/advapi32/security.c
+++ b/dlls/advapi32/security.c
@@ -4205,8 +4205,85 @@ DWORD WINAPI GetExplicitEntriesFromAclA( PACL pacl, PULONG pcCountOfExplicitEntr
@@ -4202,8 +4202,85 @@ DWORD WINAPI GetExplicitEntriesFromAclA( PACL pacl, PULONG pcCountOfExplicitEntr
DWORD WINAPI GetExplicitEntriesFromAclW( PACL pacl, PULONG pcCountOfExplicitEntries,
PEXPLICIT_ACCESSW* pListOfExplicitEntries)
{
@@ -101,10 +101,10 @@ index e36792cff4..b305947347 100644
/******************************************************************************
diff --git a/dlls/advapi32/tests/security.c b/dlls/advapi32/tests/security.c
index 3c68205922..ca5edffae5 100644
index c31dfbeace3..23cbff58117 100644
--- a/dlls/advapi32/tests/security.c
+++ b/dlls/advapi32/tests/security.c
@@ -134,6 +134,7 @@ static BOOL (WINAPI *pGetWindowsAccountDomainSid)(PSID,PSID,DWORD*);
@@ -133,6 +133,7 @@ static BOOL (WINAPI *pGetWindowsAccountDomainSid)(PSID,PSID,DWORD*);
static void (WINAPI *pRtlInitAnsiString)(PANSI_STRING,PCSZ);
static NTSTATUS (WINAPI *pRtlFreeUnicodeString)(PUNICODE_STRING);
static PSID_IDENTIFIER_AUTHORITY (WINAPI *pGetSidIdentifierAuthority)(PSID);
@@ -112,16 +112,16 @@ index 3c68205922..ca5edffae5 100644
static HMODULE hmod;
static int myARGC;
@@ -230,6 +231,7 @@ static void init(void)
@@ -227,6 +228,7 @@ static void init(void)
pGetAce = (void *)GetProcAddress(hmod, "GetAce");
pGetWindowsAccountDomainSid = (void *)GetProcAddress(hmod, "GetWindowsAccountDomainSid");
pGetSidIdentifierAuthority = (void *)GetProcAddress(hmod, "GetSidIdentifierAuthority");
pDuplicateTokenEx = (void *)GetProcAddress(hmod, "DuplicateTokenEx");
+ pGetExplicitEntriesFromAclW = (void *)GetProcAddress(hmod, "GetExplicitEntriesFromAclW");
myARGC = winetest_get_mainargs( &myARGV );
}
@@ -7076,6 +7078,145 @@ static void test_child_token_sd(void)
HeapFree(GetProcessHeap(), 0, sd);
@@ -6451,6 +6453,145 @@ static void test_maximum_allowed(void)
CloseHandle(handle);
}
+static void test_GetExplicitEntriesFromAclW(void)
@@ -266,14 +266,12 @@ index 3c68205922..ca5edffae5 100644
START_TEST(security)
{
init();
@@ -7129,6 +7270,7 @@ START_TEST(security)
@@ -6499,4 +6640,5 @@ START_TEST(security)
test_GetSidIdentifierAuthority();
test_pseudo_tokens();
test_maximum_allowed();
test_token_label();
+ test_GetExplicitEntriesFromAclW();
/* Must be the last test, modifies process token */
test_token_security_descriptor();
}
--
2.13.1
2.11.0

View File

@@ -0,0 +1,55 @@
From 0eb3047ec54504764bc6c860fecb465815bb8597 Mon Sep 17 00:00:00 2001
From: Sebastian Lackner <sebastian@fds-team.de>
Date: Mon, 12 Jun 2017 20:07:24 +0200
Subject: Revert "dinput: Assume a 1-to-1 axes map when no axes match."
This reverts commit e87ccb8b055dc846211967e46ee2f17fbabef7a1.
---
dlls/dinput/joystick_linux.c | 19 +------------------
1 file changed, 1 insertion(+), 18 deletions(-)
diff --git a/dlls/dinput/joystick_linux.c b/dlls/dinput/joystick_linux.c
index 1032659621e..1f8f94d7382 100644
--- a/dlls/dinput/joystick_linux.c
+++ b/dlls/dinput/joystick_linux.c
@@ -228,36 +228,19 @@ static INT find_joystick_devices(void)
else
if ((joydev.dev_axes_map = HeapAlloc(GetProcessHeap(), 0, joydev.axis_count * sizeof(int))))
{
- INT j, found_axes = 0;
+ INT j;
/* Remap to DI numbers */
for (j = 0; j < joydev.axis_count; j++)
- {
if (axes_map[j] < 8)
- {
/* Axis match 1-to-1 */
joydev.dev_axes_map[j] = j;
- found_axes++;
- }
else if (axes_map[j] == 16 ||
axes_map[j] == 17)
- {
/* POV axis */
joydev.dev_axes_map[j] = 8;
- found_axes++;
- }
else
joydev.dev_axes_map[j] = -1;
- }
-
- /* If no axes were configured but there are axes assume a 1-to-1 (wii controller) */
- if (joydev.axis_count && !found_axes)
- {
- ERR("Incoherent joystick data, advertised %d axes, detected 0. Assuming 1-to-1.\n",
- joydev.axis_count);
- for (j = 0; j < joydev.axis_count; j++)
- joydev.dev_axes_map[j] = j;
- }
}
/* Find vendor_id and product_id in sysfs */
--
2.13.1

View File

@@ -0,0 +1 @@
Fixes: [!43120] Revert patch to assume a 1-to-1 axes mapping when no axes match

View File

@@ -1,4 +1,4 @@
From 85367d69fb057ba4557d9195b324425bd0e84316 Mon Sep 17 00:00:00 2001
From b95848a7794ff437b58f1a307da8c8fdca6a362f Mon Sep 17 00:00:00 2001
From: Mark Harmstone <mark@harmstone.com>
Date: Sun, 15 Mar 2015 18:04:16 +0000
Subject: dsound: Add EAX v1 constants and structs.
@@ -11,7 +11,7 @@ Subject: dsound: Add EAX v1 constants and structs.
diff --git a/dlls/dsound/dsound_eax.h b/dlls/dsound/dsound_eax.h
new file mode 100644
index 00000000000..600029fa94f
index 0000000..600029f
--- /dev/null
+++ b/dlls/dsound/dsound_eax.h
@@ -0,0 +1,89 @@
@@ -105,7 +105,7 @@ index 00000000000..600029fa94f
+
+#endif
diff --git a/dlls/dsound/dsound_private.h b/dlls/dsound/dsound_private.h
index 45232cbd729..58163646fd7 100644
index ed645db..3c7dc7a 100644
--- a/dlls/dsound/dsound_private.h
+++ b/dlls/dsound/dsound_private.h
@@ -29,6 +29,7 @@
@@ -115,7 +115,7 @@ index 45232cbd729..58163646fd7 100644
+#include "dsound_eax.h"
#include "wine/list.h"
#include "wine/unicode.h"
--
2.13.1
2.3.3

View File

@@ -1,102 +0,0 @@
From 07f489ad42fce6f8baa1bc06733c106946857123 Mon Sep 17 00:00:00 2001
From: Sebastian Lackner <sebastian@fds-team.de>
Date: Sun, 25 Jun 2017 14:58:23 +0200
Subject: kernel32: Add detection for position independent executables.
---
dlls/kernel32/module.c | 61 ++++++++++++++++++++++++++++++++++++++++++++++++--
1 file changed, 59 insertions(+), 2 deletions(-)
diff --git a/dlls/kernel32/module.c b/dlls/kernel32/module.c
index badfe1d175b..d5314309926 100644
--- a/dlls/kernel32/module.c
+++ b/dlls/kernel32/module.c
@@ -238,13 +238,29 @@ void MODULE_get_binary_info( HANDLE hfile, struct binary_info *info )
unsigned char magic[4];
unsigned char class;
unsigned char data;
- unsigned char version;
- unsigned char ignored[9];
+ unsigned char ignored1[10];
unsigned short type;
unsigned short machine;
+ unsigned char ignored2[8];
+ unsigned int phoff;
+ unsigned char ignored3[12];
+ unsigned short phnum;
} elf;
struct
{
+ unsigned char magic[4];
+ unsigned char class;
+ unsigned char data;
+ unsigned char ignored1[10];
+ unsigned short type;
+ unsigned short machine;
+ unsigned char ignored2[12];
+ unsigned long long phoff;
+ unsigned char ignored3[16];
+ unsigned short phnum;
+ } elf64;
+ struct
+ {
unsigned int magic;
unsigned int cputype;
unsigned int cpusubtype;
@@ -272,12 +288,53 @@ void MODULE_get_binary_info( HANDLE hfile, struct binary_info *info )
{
header.elf.type = RtlUshortByteSwap( header.elf.type );
header.elf.machine = RtlUshortByteSwap( header.elf.machine );
+ if (header.elf.class == 2)
+ {
+ header.elf64.phoff = RtlUlonglongByteSwap( header.elf64.phoff );
+ header.elf64.phnum = RtlUshortByteSwap( header.elf64.phnum );
+ }
+ else
+ {
+ header.elf.phoff = RtlUlongByteSwap( header.elf.phoff );
+ header.elf.phnum = RtlUshortByteSwap( header.elf.phnum );
+ }
}
switch(header.elf.type)
{
case 2: info->type = BINARY_UNIX_EXE; break;
case 3: info->type = BINARY_UNIX_LIB; break;
}
+ if (header.elf.type == 3)
+ {
+ unsigned long long phoff;
+ unsigned short phnum;
+ unsigned int type;
+ if (header.elf.class == 2)
+ {
+ phoff = header.elf64.phoff;
+ phnum = header.elf64.phnum;
+ }
+ else
+ {
+ phoff = header.elf.phoff;
+ phnum = header.elf.phnum;
+ }
+ while (phnum--)
+ {
+ if (SetFilePointer( hfile, phoff, NULL, SEEK_SET ) == -1) return;
+ if (!ReadFile( hfile, &type, sizeof(type), &len, NULL ) || len < sizeof(type)) return;
+#ifdef WORDS_BIGENDIAN
+ if (header.elf.data == 1)
+#else
+ if (header.elf.data == 2)
+#endif
+ {
+ type = RtlUlongByteSwap( type );
+ }
+ if (type == 3) info->type = BINARY_UNIX_EXE;
+ phoff += (header.elf.class == 2) ? 56 : 32;
+ }
+ }
switch(header.elf.machine)
{
case 3: info->arch = IMAGE_FILE_MACHINE_I386; break;
--
2.13.1

View File

@@ -1 +0,0 @@
Fixes: [43217] Implement detection for position-independent executables

View File

@@ -1,4 +1,4 @@
From 91a2f667bd20e9f4da38f2a3ee2a189a18d8bb0e Mon Sep 17 00:00:00 2001
From 663bd84bef7a95f85a935fe52662186930235237 Mon Sep 17 00:00:00 2001
From: Sebastian Lackner <sebastian@fds-team.de>
Date: Sun, 9 Apr 2017 03:13:25 +0200
Subject: server: Skip async completion when possible.
@@ -11,7 +11,7 @@ Subject: server: Skip async completion when possible.
4 files changed, 16 insertions(+), 3 deletions(-)
diff --git a/dlls/ntdll/tests/pipe.c b/dlls/ntdll/tests/pipe.c
index 6846b514dc2..a6f8135624a 100644
index 013eb2b39f..631013c755 100644
--- a/dlls/ntdll/tests/pipe.c
+++ b/dlls/ntdll/tests/pipe.c
@@ -389,9 +389,7 @@ static void test_completion(void)
@@ -25,7 +25,7 @@ index 6846b514dc2..a6f8135624a 100644
CloseHandle(ov.hEvent);
diff --git a/server/async.c b/server/async.c
index d1cea9a607e..bb3bc325c38 100644
index f9d8af36b9..be7da06b65 100644
--- a/server/async.c
+++ b/server/async.c
@@ -45,6 +45,7 @@ struct async
@@ -59,7 +59,7 @@ index d1cea9a607e..bb3bc325c38 100644
if (iosb) async->iosb = (struct iosb *)grab_object( iosb );
else async->iosb = NULL;
@@ -340,7 +350,7 @@ void async_set_result( struct object *obj, unsigned int status, apc_param_t tota
@@ -326,7 +336,7 @@ void async_set_result( struct object *obj, unsigned int status, apc_param_t tota
async->status = status;
if (status == STATUS_MORE_PROCESSING_REQUIRED) return; /* don't report the completion */
@@ -69,7 +69,7 @@ index d1cea9a607e..bb3bc325c38 100644
if (async->data.apc)
{
diff --git a/server/fd.c b/server/fd.c
index 7a876917fdd..3d62bae5b84 100644
index 288f6976e1..fdbd07ef59 100644
--- a/server/fd.c
+++ b/server/fd.c
@@ -2381,6 +2381,7 @@ DECL_HANDLER(flush)
@@ -80,15 +80,15 @@ index 7a876917fdd..3d62bae5b84 100644
release_object( async );
}
release_object( fd );
@@ -2457,6 +2458,7 @@ DECL_HANDLER(read)
{
reply->wait = fd->fd_ops->read( fd, async, req->pos );
reply->options = fd->options;
+ async_skip_completion( async, fd->comp_flags );
release_object( async );
}
release_object( fd );
@@ -2478,6 +2480,7 @@ DECL_HANDLER(write)
@@ -2461,6 +2462,7 @@ DECL_HANDLER(read)
{
reply->wait = fd->fd_ops->read( fd, async, req->pos );
reply->options = fd->options;
+ async_skip_completion( async, fd->comp_flags );
release_object( async );
}
release_object( iosb );
@@ -2484,6 +2486,7 @@ DECL_HANDLER(write)
{
reply->wait = fd->fd_ops->write( fd, async, req->pos );
reply->options = fd->options;
@@ -96,7 +96,7 @@ index 7a876917fdd..3d62bae5b84 100644
release_object( async );
}
release_object( iosb );
@@ -2501,6 +2504,7 @@ DECL_HANDLER(ioctl)
@@ -2507,6 +2510,7 @@ DECL_HANDLER(ioctl)
{
reply->wait = fd->fd_ops->ioctl( fd, req->code, async );
reply->options = fd->options;
@@ -105,10 +105,10 @@ index 7a876917fdd..3d62bae5b84 100644
}
release_object( iosb );
diff --git a/server/file.h b/server/file.h
index 30db87e3ac7..aa70908a8a1 100644
index 5ea8f0f5cb..ff605c3719 100644
--- a/server/file.h
+++ b/server/file.h
@@ -182,6 +182,7 @@ extern void async_set_timeout( struct async *async, timeout_t timeout, unsigned
@@ -181,6 +181,7 @@ extern void async_set_timeout( struct async *async, timeout_t timeout, unsigned
extern void async_set_result( struct object *obj, unsigned int status, apc_param_t total );
extern int async_queued( struct async_queue *queue );
extern int async_waiting( struct async_queue *queue );
@@ -117,5 +117,5 @@ index 30db87e3ac7..aa70908a8a1 100644
extern void async_wake_up( struct async_queue *queue, unsigned int status );
extern struct completion *fd_get_completion( struct fd *fd, apc_param_t *p_key );
--
2.13.1
2.11.0

View File

@@ -1,125 +0,0 @@
From 2289d4a4f8a8085bd6fd4eebee829ee22df8abc5 Mon Sep 17 00:00:00 2001
From: Sebastian Lackner <sebastian@fds-team.de>
Date: Wed, 14 Jun 2017 14:47:33 +0200
Subject: ws2_32: Don't skip completion in AcceptEx.
Spotted by Jacek Caban.
FIXME: It would be better to get rid of the STATUS_MORE_PROCESSING_REQUIRED handling.
---
dlls/ws2_32/socket.c | 13 +++++++------
dlls/ws2_32/tests/sock.c | 5 +++++
server/fd.c | 2 +-
server/protocol.def | 1 +
4 files changed, 14 insertions(+), 7 deletions(-)
diff --git a/dlls/ws2_32/socket.c b/dlls/ws2_32/socket.c
index 886ff82dba9..0340547dce0 100644
--- a/dlls/ws2_32/socket.c
+++ b/dlls/ws2_32/socket.c
@@ -654,7 +654,7 @@ static int ws_protocol_info(SOCKET s, int unicode, WSAPROTOCOL_INFOW *buffer, in
int WSAIOCTL_GetInterfaceCount(void);
int WSAIOCTL_GetInterfaceName(int intNumber, char *intName);
-static void WS_AddCompletion( SOCKET sock, ULONG_PTR CompletionValue, NTSTATUS CompletionStatus, ULONG Information );
+static void WS_AddCompletion( SOCKET sock, ULONG_PTR CompletionValue, NTSTATUS CompletionStatus, ULONG Information, BOOL force );
#define MAP_OPTION(opt) { WS_##opt, opt }
@@ -2510,7 +2510,7 @@ static NTSTATUS WS2_async_accept_recv( void *user, IO_STATUS_BLOCK *iosb, NTSTAT
return status;
if (wsa->cvalue)
- WS_AddCompletion( HANDLE2SOCKET(wsa->listen_socket), wsa->cvalue, iosb->u.Status, iosb->Information );
+ WS_AddCompletion( HANDLE2SOCKET(wsa->listen_socket), wsa->cvalue, iosb->u.Status, iosb->Information, TRUE );
release_async_io( &wsa->io );
return status;
@@ -5139,7 +5139,7 @@ INT WINAPI WSAIoctl(SOCKET s, DWORD code, LPVOID in_buff, DWORD in_size, LPVOID
overlapped->Internal = status;
overlapped->InternalHigh = total;
if (overlapped->hEvent) NtSetEvent( overlapped->hEvent, NULL );
- if (cvalue) WS_AddCompletion( HANDLE2SOCKET(s), cvalue, status, total );
+ if (cvalue) WS_AddCompletion( HANDLE2SOCKET(s), cvalue, status, total, FALSE );
}
if (!status)
@@ -5534,7 +5534,7 @@ int WINAPI WSAPoll(WSAPOLLFD *wfds, ULONG count, int timeout)
/* helper to send completion messages for client-only i/o operation case */
static void WS_AddCompletion( SOCKET sock, ULONG_PTR CompletionValue, NTSTATUS CompletionStatus,
- ULONG Information )
+ ULONG Information, BOOL force )
{
SERVER_START_REQ( add_fd_completion )
{
@@ -5542,6 +5542,7 @@ static void WS_AddCompletion( SOCKET sock, ULONG_PTR CompletionValue, NTSTATUS C
req->cvalue = CompletionValue;
req->status = CompletionStatus;
req->information = Information;
+ req->force = force;
wine_server_call( req );
}
SERVER_END_REQ;
@@ -5686,7 +5687,7 @@ static int WS2_sendto( SOCKET s, LPWSABUF lpBuffers, DWORD dwBufferCount,
if (lpNumberOfBytesSent) *lpNumberOfBytesSent = n;
if (!wsa->completion_func)
{
- if (cvalue) WS_AddCompletion( s, cvalue, STATUS_SUCCESS, n );
+ if (cvalue) WS_AddCompletion( s, cvalue, STATUS_SUCCESS, n, FALSE );
if (lpOverlapped->hEvent) SetEvent( lpOverlapped->hEvent );
HeapFree( GetProcessHeap(), 0, wsa );
}
@@ -7888,7 +7889,7 @@ static int WS2_recv_base( SOCKET s, LPWSABUF lpBuffers, DWORD dwBufferCount,
iosb->Information = n;
if (!wsa->completion_func)
{
- if (cvalue) WS_AddCompletion( s, cvalue, STATUS_SUCCESS, n );
+ if (cvalue) WS_AddCompletion( s, cvalue, STATUS_SUCCESS, n, FALSE );
if (lpOverlapped->hEvent) SetEvent( lpOverlapped->hEvent );
HeapFree( GetProcessHeap(), 0, wsa );
}
diff --git a/dlls/ws2_32/tests/sock.c b/dlls/ws2_32/tests/sock.c
index acbec940954..c7f0c01112a 100644
--- a/dlls/ws2_32/tests/sock.c
+++ b/dlls/ws2_32/tests/sock.c
@@ -9939,6 +9939,11 @@ static void test_completion_port(void)
ok(io_port != NULL, "failed to create completion port %u\n", GetLastError());
io_info.Flags = FILE_SKIP_COMPLETION_PORT_ON_SUCCESS;
+ status = pNtSetInformationFile((HANDLE)src, &io, &io_info, sizeof(io_info), FileIoCompletionNotificationInformation);
+ ok(status == STATUS_SUCCESS || broken(status == STATUS_INVALID_INFO_CLASS) /* XP */,
+ "expected STATUS_SUCCESS, got %08x\n", status);
+
+ io_info.Flags = FILE_SKIP_COMPLETION_PORT_ON_SUCCESS;
status = pNtSetInformationFile((HANDLE)dest, &io, &io_info, sizeof(io_info), FileIoCompletionNotificationInformation);
ok(status == STATUS_SUCCESS || broken(status == STATUS_INVALID_INFO_CLASS) /* XP */,
"expected STATUS_SUCCESS, got %08x\n", status);
diff --git a/server/fd.c b/server/fd.c
index 1b82bd30860..94febea990b 100644
--- a/server/fd.c
+++ b/server/fd.c
@@ -2704,7 +2704,7 @@ DECL_HANDLER(add_fd_completion)
struct fd *fd = get_handle_fd_obj( current->process, req->handle, 0 );
if (fd)
{
- if (fd->completion && (!(fd->comp_flags & COMPLETION_SKIP_ON_SUCCESS) || req->status))
+ if (fd->completion && (!(fd->comp_flags & COMPLETION_SKIP_ON_SUCCESS) || req->status || req->force))
add_completion( fd->completion, fd->comp_key, req->cvalue, req->status, req->information );
release_object( fd );
}
diff --git a/server/protocol.def b/server/protocol.def
index 3912908e519..ba047d5581c 100644
--- a/server/protocol.def
+++ b/server/protocol.def
@@ -3725,6 +3725,7 @@ struct handle_info
apc_param_t cvalue; /* completion value */
apc_param_t information; /* IO_STATUS_BLOCK Information */
unsigned int status; /* completion status */
+ int force; /* don't check if skip-on-success is set */
@END
--
2.13.1

View File

@@ -1,4 +1,4 @@
From 3f11f4c46bc1242c96fd0779f6594eadfc5ab5ff Mon Sep 17 00:00:00 2001
From 9d3cd3764ad26ae8f190524943ce63a771f6b992 Mon Sep 17 00:00:00 2001
From: Sebastian Lackner <sebastian@fds-team.de>
Date: Mon, 12 Jun 2017 00:16:08 +0200
Subject: loader: Implement preloader for Mac OS.
@@ -10,8 +10,8 @@ Subject: loader: Implement preloader for Mac OS.
libs/wine/config.c | 2 +-
loader/Makefile.in | 4 +-
loader/main.c | 44 +----
loader/preloader.c | 468 +++++++++++++++++++++++++++++++++++++++++++++++++--
7 files changed, 491 insertions(+), 53 deletions(-)
loader/preloader.c | 451 +++++++++++++++++++++++++++++++++++++++++++++++++--
7 files changed, 475 insertions(+), 52 deletions(-)
diff --git a/Makefile.in b/Makefile.in
index 22b2ae7230..29b6cbdd53 100644
@@ -215,7 +215,7 @@ index 13740c7b3c..5212e3f079 100644
wine_init( argc, argv, error, sizeof(error) );
diff --git a/loader/preloader.c b/loader/preloader.c
index 5e6add7830..90ab6764fa 100644
index 5e6add7830..5b09b79cf3 100644
--- a/loader/preloader.c
+++ b/loader/preloader.c
@@ -4,6 +4,8 @@
@@ -248,44 +248,27 @@ index 5e6add7830..90ab6764fa 100644
#ifndef MAP_COPY
#define MAP_COPY MAP_PRIVATE
#endif
@@ -108,21 +109,63 @@
@@ -109,7 +110,8 @@
static struct wine_preload_info preload_info[] =
{
+/* On macOS, we allocate the low 64k area in two steps because PAGEZERO
+ * might not always be available. Also, the top-down allocations area
+ * on x86_64 is moved because the address on Linux exceeds the maximum
+ * allowed user space limit. Please note that on Linux, it is better to
+ * allocate the low 64k as a single chunk to avoid SELinux warnings on
+ * systems with CONFIG_DEFAULT_MMAP_MIN_ADDR < CONFIG_LSM_MMAP_MIN_ADDR. */
+#ifdef __APPLE__
+#ifdef __i386__
#ifdef __i386__
- { (void *)0x00000000, 0x00010000 }, /* low 64k */
+ { (void *)0x00000000, 0x00001000 }, /* first page */
+ { (void *)0x00001000, 0x0000f000 }, /* low 64k */
+ { (void *)0x00010000, 0x00100000 }, /* DOS area */
+ { (void *)0x00110000, 0x67ef0000 }, /* low memory area */
+ { (void *)0x7f000000, 0x03000000 }, /* top-down allocations + shared heap + virtual heap */
+#else /* __i386__ */
+ { (void *)0x000000010000, 0x00100000 }, /* DOS area */
+ { (void *)0x000000110000, 0x67ef0000 }, /* low memory area */
+ { (void *)0x00007ff00000, 0x000f0000 }, /* shared user data */
+ { (void *)0x7fff40000000, 0x01ff0000 }, /* top-down allocations + virtual heap */
+#endif /* __i386__ */
+#else /* __APPLE__ */
#ifdef __i386__
{ (void *)0x00000000, 0x00010000 }, /* low 64k */
{ (void *)0x00010000, 0x00100000 }, /* DOS area */
{ (void *)0x00110000, 0x67ef0000 }, /* low memory area */
{ (void *)0x7f000000, 0x03000000 }, /* top-down allocations + shared heap + virtual heap */
-#else
+#else /* __i386__ */
@@ -117,12 +119,38 @@ static struct wine_preload_info preload_info[] =
{ (void *)0x000000010000, 0x00100000 }, /* DOS area */
{ (void *)0x000000110000, 0x67ef0000 }, /* low memory area */
{ (void *)0x00007ff00000, 0x000f0000 }, /* shared user data */
+#ifdef __APPLE__
+ /* address below exceeds maximum allowed user space address in macOS */
+ { (void *)0x7fff40000000, 0x01ff0000 }, /* top-down allocations + virtual heap */
+#else
{ (void *)0x7ffffe000000, 0x01ff0000 }, /* top-down allocations + virtual heap */
-#endif
+#endif /* __i386__ */
+#endif /* __APPLE__ */
#endif
+#endif
{ 0, 0 }, /* PE exe range set with WINEPRELOADRESERVE */
{ 0, 0 } /* end of list */
};
@@ -314,7 +297,7 @@ index 5e6add7830..90ab6764fa 100644
/* debugging */
#undef DUMP_SEGMENTS
#undef DUMP_AUX_INFO
@@ -168,6 +211,8 @@ struct wld_auxv
@@ -168,6 +196,8 @@ struct wld_auxv
} a_un;
};
@@ -323,7 +306,7 @@ index 5e6add7830..90ab6764fa 100644
/*
* The __bb_init_func is an empty function only called when file is
* compiled with gcc flags "-fprofile-arcs -ftest-coverage". This
@@ -182,6 +227,201 @@ void *__stack_chk_guard = 0;
@@ -182,6 +212,201 @@ void *__stack_chk_guard = 0;
void __stack_chk_fail_local(void) { return; }
void __stack_chk_fail(void) { return; }
@@ -525,7 +508,7 @@ index 5e6add7830..90ab6764fa 100644
#ifdef __i386__
/* data for setting up the glibc-style thread-local storage in %gs */
@@ -458,16 +698,17 @@ SYSCALL_NOERR( wld_getegid, 108 /* SYS_getegid */ );
@@ -458,16 +683,17 @@ SYSCALL_NOERR( wld_getegid, 108 /* SYS_getegid */ );
#else
#error preloader not implemented for this CPU
#endif
@@ -545,7 +528,7 @@ index 5e6add7830..90ab6764fa 100644
{
if (len <= 0) return 0;
while ((--len > 0) && *str1 && (*str1 == *str2)) { str1++; str2++; }
@@ -560,6 +801,8 @@ static __attribute__((noreturn,format(printf,1,2))) void fatal_error(const char
@@ -560,6 +786,8 @@ static __attribute__((noreturn,format(printf,1,2))) void fatal_error(const char
wld_exit(1);
}
@@ -554,7 +537,7 @@ index 5e6add7830..90ab6764fa 100644
#ifdef DUMP_AUX_INFO
/*
* Dump interesting bits of the ELF auxv_t structure that is passed
@@ -1039,6 +1282,8 @@ found:
@@ -1039,6 +1267,8 @@ found:
return (void *)(symtab[idx].st_value + map->l_addr);
}
@@ -563,7 +546,7 @@ index 5e6add7830..90ab6764fa 100644
/*
* preload_reserve
*
@@ -1070,6 +1315,7 @@ static void preload_reserve( const char *str )
@@ -1070,6 +1300,7 @@ static void preload_reserve( const char *str )
/* sanity checks */
if (end <= start) start = end = NULL;
@@ -571,7 +554,7 @@ index 5e6add7830..90ab6764fa 100644
else if ((char *)end > preloader_start &&
(char *)start <= preloader_end)
{
@@ -1077,6 +1323,7 @@ static void preload_reserve( const char *str )
@@ -1077,6 +1308,7 @@ static void preload_reserve( const char *str )
start, end, preloader_start, preloader_end );
start = end = NULL;
}
@@ -579,7 +562,7 @@ index 5e6add7830..90ab6764fa 100644
/* check for overlap with low memory areas */
for (i = 0; preload_info[i].size; i++)
@@ -1101,7 +1348,7 @@ error:
@@ -1101,7 +1333,7 @@ error:
}
/* check if address is in one of the reserved ranges */
@@ -588,7 +571,7 @@ index 5e6add7830..90ab6764fa 100644
{
int i;
@@ -1125,6 +1372,203 @@ static void remove_preload_range( int i )
@@ -1125,6 +1357,203 @@ static void remove_preload_range( int i )
}
}
@@ -792,7 +775,7 @@ index 5e6add7830..90ab6764fa 100644
/*
* is_in_preload_range
*
@@ -1293,3 +1737,5 @@ void* wld_start( void **stack )
@@ -1293,3 +1722,5 @@ void* wld_start( void **stack )
return (void *)ld_so_map.l_entry;
}

View File

@@ -1,99 +0,0 @@
From 0763c73423ae069023b54e669b0c9bd648e1f27e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
Date: Mon, 26 Jun 2017 16:18:09 +0200
Subject: msi: Create dummy thread to initialize COM for custom actions.
---
dlls/msi/action.c | 48 ++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 48 insertions(+)
diff --git a/dlls/msi/action.c b/dlls/msi/action.c
index 16652000ee5..62f01044bf1 100644
--- a/dlls/msi/action.c
+++ b/dlls/msi/action.c
@@ -156,6 +156,13 @@ static const WCHAR szValidateProductID[] =
static const WCHAR szWriteEnvironmentStrings[] =
{'W','r','i','t','e','E','n','v','i','r','o','n','m','e','n','t','S','t','r','i','n','g','s',0};
+struct dummy_thread
+{
+ HANDLE started;
+ HANDLE stopped;
+ HANDLE thread;
+};
+
static void ui_actionstart(MSIPACKAGE *package, LPCWSTR action)
{
static const WCHAR Query_t[] =
@@ -7912,6 +7919,42 @@ static UINT ACTION_PerformActionSequence(MSIPACKAGE *package, UINT seq)
return rc;
}
+DWORD WINAPI dummy_thread_proc(void *arg)
+{
+ struct dummy_thread *info = arg;
+ HRESULT hr;
+
+ hr = CoInitializeEx(0, COINIT_MULTITHREADED);
+ if (FAILED(hr)) ERR("CoInitializeEx failed %08x\n", hr);
+
+ SetEvent(info->started);
+ WaitForSingleObject(info->stopped, INFINITE);
+
+ CoUninitialize();
+ return 0;
+}
+
+static void start_dummy_thread(struct dummy_thread *info)
+{
+ if (!(info->started = CreateEventA(NULL, TRUE, FALSE, NULL))) return;
+ if (!(info->stopped = CreateEventA(NULL, TRUE, FALSE, NULL))) return;
+ if (!(info->thread = CreateThread(NULL, 0, dummy_thread_proc, info, 0, NULL))) return;
+
+ WaitForSingleObject(info->started, INFINITE);
+}
+
+static void stop_dummy_thread(struct dummy_thread *info)
+{
+ if (info->thread)
+ {
+ SetEvent(info->stopped);
+ WaitForSingleObject(info->thread, INFINITE);
+ CloseHandle(info->thread);
+ }
+ if (info->started) CloseHandle(info->started);
+ if (info->stopped) CloseHandle(info->stopped);
+}
+
/****************************************************
* TOP level entry points
*****************************************************/
@@ -7923,6 +7966,7 @@ UINT MSI_InstallPackage( MSIPACKAGE *package, LPCWSTR szPackagePath,
static const WCHAR szAction[] = {'A','C','T','I','O','N',0};
static const WCHAR szInstall[] = {'I','N','S','T','A','L','L',0};
WCHAR *reinstall, *remove, *patch, *productcode;
+ struct dummy_thread thread_info = {NULL, NULL, NULL};
BOOL ui_exists;
UINT rc;
@@ -7988,6 +8032,8 @@ UINT MSI_InstallPackage( MSIPACKAGE *package, LPCWSTR szPackagePath,
msi_adjust_privilege_properties( package );
msi_set_context( package );
+ start_dummy_thread(&thread_info);
+
productcode = msi_dup_property( package->db, szProductCode );
if (strcmpiW( productcode, package->ProductCode ))
{
@@ -8036,6 +8082,8 @@ UINT MSI_InstallPackage( MSIPACKAGE *package, LPCWSTR szPackagePath,
/* finish up running custom actions */
ACTION_FinishCustomActions(package);
+ stop_dummy_thread(&thread_info);
+
if (package->need_rollback && !reinstall)
{
WARN("installation failed, running rollback script\n");
--
2.13.1

View File

@@ -1 +0,0 @@
Fixes: [!18070] Workaround COM/MTA issues due to lack of separate msi custom action process

View File

@@ -1,31 +1,27 @@
From 67ecb071f690c5188777b495dbd3d77916be1ee4 Mon Sep 17 00:00:00 2001
From 27834dc400a876c75de4dce156f25ce07ec3f78b Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
Date: Thu, 1 Jun 2017 06:04:53 +0200
Subject: ntdll: Fix holes in ELF mappings. (v2)
Subject: ntdll: Fix holes in ELF mappings.
Based on a patch by Andrew Wesie.
---
dlls/ntdll/virtual.c | 10 ++++++++++
dlls/ntdll/virtual.c | 6 ++++++
dlls/psapi/tests/psapi_main.c | 14 +++++++++++++-
2 files changed, 23 insertions(+), 1 deletion(-)
2 files changed, 19 insertions(+), 1 deletion(-)
diff --git a/dlls/ntdll/virtual.c b/dlls/ntdll/virtual.c
index 2889e8babc3..c73d2998703 100644
index 387379a5882..55c15690f70 100644
--- a/dlls/ntdll/virtual.c
+++ b/dlls/ntdll/virtual.c
@@ -1526,6 +1526,16 @@ NTSTATUS virtual_handle_fault( LPCVOID addr, DWORD err, BOOL on_signal_stack )
@@ -1526,6 +1526,12 @@ NTSTATUS virtual_handle_fault( LPCVOID addr, DWORD err, BOOL on_signal_stack )
if (VIRTUAL_GetUnixProt( *vprot ) & PROT_READ) ret = STATUS_SUCCESS;
else update_shared_data = FALSE;
}
+ else if (!err && (view->protect & VPROT_SYSTEM) && (VIRTUAL_GetUnixProt( *vprot ) & PROT_READ))
+ else if ((view->protect & VPROT_SYSTEM) && (VIRTUAL_GetUnixProt( *vprot ) & PROT_READ))
+ {
+ int unix_prot = VIRTUAL_GetUnixProt( *vprot );
+ unsigned char vec;
+
+ if (!VIRTUAL_SetProt( view, page, page_size, *vprot )) *vprot &= ~(VPROT_READ | VPROT_EXEC);
+ else if (!mincore( page, page_size, &vec ) && (vec & 1)) ret = STATUS_SUCCESS;
+ else if (wine_anon_mmap( page, page_size, unix_prot, MAP_FIXED ) != page) *vprot &= ~(VPROT_READ | VPROT_EXEC);
+ else ret = STATUS_SUCCESS;
+ /* ignore fault if page can be made readable */
+ if (VIRTUAL_SetProt( view, page, page_size, *vprot )) ret = STATUS_SUCCESS;
+ else *vprot &= ~VPROT_READ; /* don't bother to call VIRTUAL_SetProt again */
+ }
if (!on_signal_stack && (*vprot & VPROT_GUARD))
{

View File

@@ -1,3 +1,2 @@
Fixes: Fix holes in ELF mappings
Depends: ntdll-User_Shared_Data
Depends: ntdll-x86_64_ExceptionInformation

View File

@@ -1,4 +1,4 @@
From e313cf4b443d63f2934062336472454224373e81 Mon Sep 17 00:00:00 2001
From 51f9291677535a3246a7727c1563fe62e9a5756e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
Date: Fri, 5 May 2017 05:40:50 +0200
Subject: ntdll: Create thread to update user_shared_data time values when
@@ -13,7 +13,7 @@ Subject: ntdll: Create thread to update user_shared_data time values when
5 files changed, 117 insertions(+), 9 deletions(-)
diff --git a/dlls/kernel32/cpu.c b/dlls/kernel32/cpu.c
index 2e0e79f8e8..d53488c765 100644
index 2e0e79f8e8d..d53488c7652 100644
--- a/dlls/kernel32/cpu.c
+++ b/dlls/kernel32/cpu.c
@@ -46,7 +46,7 @@
@@ -35,7 +35,7 @@ index 2e0e79f8e8..d53488c765 100644
return FALSE;
}
diff --git a/dlls/ntdll/loader.c b/dlls/ntdll/loader.c
index f4e002a060..ac1ab2d209 100644
index f4e002a0609..ac1ab2d2099 100644
--- a/dlls/ntdll/loader.c
+++ b/dlls/ntdll/loader.c
@@ -3191,6 +3191,37 @@ static void start_process( void *arg )
@@ -85,7 +85,7 @@ index f4e002a060..ac1ab2d209 100644
LdrQueryImageFileExecutionOptions( &peb->ProcessParameters->ImagePathName, globalflagW,
diff --git a/dlls/ntdll/ntdll_misc.h b/dlls/ntdll/ntdll_misc.h
index 6e51612380..9d066d637c 100644
index 6e516123806..9d066d637c7 100644
--- a/dlls/ntdll/ntdll_misc.h
+++ b/dlls/ntdll/ntdll_misc.h
@@ -176,6 +176,9 @@ extern void VIRTUAL_SetForceExec( BOOL enable ) DECLSPEC_HIDDEN;
@@ -99,7 +99,7 @@ index 6e51612380..9d066d637c 100644
/* completion */
extern NTSTATUS NTDLL_AddCompletion( HANDLE hFile, ULONG_PTR CompletionValue,
diff --git a/dlls/ntdll/thread.c b/dlls/ntdll/thread.c
index 9399fbcb5c..cc65f3b48d 100644
index 9399fbcb5c6..cc65f3b48d6 100644
--- a/dlls/ntdll/thread.c
+++ b/dlls/ntdll/thread.c
@@ -43,6 +43,7 @@
@@ -208,7 +208,7 @@ index 9399fbcb5c..cc65f3b48d 100644
/* allocate and initialize the PEB */
diff --git a/dlls/ntdll/virtual.c b/dlls/ntdll/virtual.c
index ee9c8d0195..2889e8babc 100644
index ee9c8d0195d..387379a5882 100644
--- a/dlls/ntdll/virtual.c
+++ b/dlls/ntdll/virtual.c
@@ -1497,6 +1497,7 @@ NTSTATUS virtual_handle_fault( LPCVOID addr, DWORD err, BOOL on_signal_stack )
@@ -223,7 +223,7 @@ index ee9c8d0195..2889e8babc 100644
/* ignore fault if page is writable now */
if (VIRTUAL_GetUnixProt( *vprot ) & PROT_WRITE) ret = STATUS_SUCCESS;
}
+ else if (!err && page == user_shared_data_external)
+ else if (page == user_shared_data_external)
+ {
+ if (!(*vprot & VPROT_READ))
+ {

View File

@@ -1,3 +1,2 @@
Fixes: [29168] Update user shared data at realtime
Depends: ntdll-Hide_Wine_Exports
Depends: ntdll-x86_64_ExceptionInformation

View File

@@ -1,25 +0,0 @@
From 5b14b1326af51900975be9749fd2319643cde2d9 Mon Sep 17 00:00:00 2001
From: Sebastian Lackner <sebastian@fds-team.de>
Date: Mon, 19 Jun 2017 03:55:14 +0200
Subject: ntdll: Set proper ExceptionInformation[0] for x86_64 exceptions.
---
dlls/ntdll/signal_x86_64.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/dlls/ntdll/signal_x86_64.c b/dlls/ntdll/signal_x86_64.c
index 86034c00a5..365e3799d4 100644
--- a/dlls/ntdll/signal_x86_64.c
+++ b/dlls/ntdll/signal_x86_64.c
@@ -2663,7 +2663,7 @@ static void segv_handler( int signal, siginfo_t *siginfo, void *sigcontext )
case TRAP_x86_PAGEFLT: /* Page fault */
rec->ExceptionCode = EXCEPTION_ACCESS_VIOLATION;
rec->NumberParameters = 2;
- rec->ExceptionInformation[0] = (ERROR_sig(ucontext) & 2) != 0;
+ rec->ExceptionInformation[0] = (ERROR_sig(ucontext) >> 1) & 0x09;
rec->ExceptionInformation[1] = (ULONG_PTR)siginfo->si_addr;
break;
case TRAP_x86_ALIGNFLT: /* Alignment check exception */
--
2.13.1

Some files were not shown because too many files have changed in this diff Show More