mirror of
https://gitlab.winehq.org/wine/wine-staging.git
synced 2025-01-28 22:04:43 -08:00
Rebase against 1e8f4c059befe4a026ddf5c56e81d720b35c6c2f.
This commit is contained in:
parent
37de066533
commit
5e8beb5ff2
@ -1,20 +1,20 @@
|
||||
From d211d0b1843d4bea1502be6b3bd236ab893b19c2 Mon Sep 17 00:00:00 2001
|
||||
From 356adef44cc8267ae73cbbb6bc250ac8bc993e75 Mon Sep 17 00:00:00 2001
|
||||
From: Zebediah Figura <z.figura12@gmail.com>
|
||||
Date: Tue, 29 Jan 2019 21:44:23 -0600
|
||||
Subject: [PATCH 07/13] ntoskrnl.exe: Implement ExReleaseResourceLite().
|
||||
|
||||
Signed-off-by: Zebediah Figura <z.figura12@gmail.com>
|
||||
---
|
||||
dlls/ntoskrnl.exe/ntoskrnl.c | 8 --------
|
||||
dlls/ntoskrnl.exe/ntoskrnl.exe.spec | 2 +-
|
||||
dlls/ntoskrnl.exe/sync.c | 13 +++++++++++++
|
||||
3 files changed, 14 insertions(+), 9 deletions(-)
|
||||
dlls/ntoskrnl.exe/ntoskrnl.c | 8 --------
|
||||
dlls/ntoskrnl.exe/ntoskrnl.exe.spec | 2 +-
|
||||
dlls/ntoskrnl.exe/sync.c | 9 +++++++++
|
||||
3 files changed, 10 insertions(+), 9 deletions(-)
|
||||
|
||||
diff --git a/dlls/ntoskrnl.exe/ntoskrnl.c b/dlls/ntoskrnl.exe/ntoskrnl.c
|
||||
index 5ab4db12..556b2ae8 100644
|
||||
index e2a838cc..d310b7e4 100644
|
||||
--- a/dlls/ntoskrnl.exe/ntoskrnl.c
|
||||
+++ b/dlls/ntoskrnl.exe/ntoskrnl.c
|
||||
@@ -3912,14 +3912,6 @@ NTSTATUS WINAPI DbgQueryDebugFilterState(ULONG component, ULONG level)
|
||||
@@ -4048,14 +4048,6 @@ NTSTATUS WINAPI DbgQueryDebugFilterState(ULONG component, ULONG level)
|
||||
return STATUS_NOT_IMPLEMENTED;
|
||||
}
|
||||
|
||||
@ -30,23 +30,23 @@ index 5ab4db12..556b2ae8 100644
|
||||
* PsGetProcessWow64Process (NTOSKRNL.@)
|
||||
*/
|
||||
diff --git a/dlls/ntoskrnl.exe/ntoskrnl.exe.spec b/dlls/ntoskrnl.exe/ntoskrnl.exe.spec
|
||||
index c32f4590..79db7ee8 100644
|
||||
index ea543025..f57352f2 100644
|
||||
--- a/dlls/ntoskrnl.exe/ntoskrnl.exe.spec
|
||||
+++ b/dlls/ntoskrnl.exe/ntoskrnl.exe.spec
|
||||
@@ -9,7 +9,7 @@
|
||||
@ stdcall -arch=i386 -norelay ExInterlockedPushEntrySList (ptr ptr ptr) NTOSKRNL_ExInterlockedPushEntrySList
|
||||
@ stdcall -fastcall -arch=i386 ExInterlockedPushEntrySList (ptr ptr ptr) NTOSKRNL_ExInterlockedPushEntrySList
|
||||
@ stub ExReInitializeRundownProtection
|
||||
@ stdcall -norelay ExReleaseFastMutexUnsafe(ptr)
|
||||
@ stdcall -fastcall ExReleaseFastMutexUnsafe(ptr)
|
||||
-@ stdcall ExReleaseResourceLite(ptr)
|
||||
+@ stdcall -norelay ExReleaseResourceLite(ptr)
|
||||
+@ stdcall -fastcall ExReleaseResourceLite(ptr)
|
||||
@ stub ExReleaseRundownProtection
|
||||
@ stub ExReleaseRundownProtectionEx
|
||||
@ stub ExRundownCompleted
|
||||
diff --git a/dlls/ntoskrnl.exe/sync.c b/dlls/ntoskrnl.exe/sync.c
|
||||
index 450e4417..0553db7f 100644
|
||||
index 540093d7..02f96c3c 100644
|
||||
--- a/dlls/ntoskrnl.exe/sync.c
|
||||
+++ b/dlls/ntoskrnl.exe/sync.c
|
||||
@@ -1006,3 +1006,16 @@ void WINAPI ExReleaseResourceForThreadLite( ERESOURCE *resource, ERESOURCE_THREA
|
||||
@@ -986,3 +986,12 @@ void WINAPI ExReleaseResourceForThreadLite( ERESOURCE *resource, ERESOURCE_THREA
|
||||
|
||||
KeReleaseSpinLock( &resource->SpinLock, irql );
|
||||
}
|
||||
@ -54,12 +54,8 @@ index 450e4417..0553db7f 100644
|
||||
+/***********************************************************************
|
||||
+ * ExReleaseResourceLite (NTOSKRNL.EXE.@)
|
||||
+ */
|
||||
+#ifdef DEFINE_FASTCALL1_ENTRYPOINT
|
||||
+DEFINE_FASTCALL1_ENTRYPOINT( ExReleaseResourceLite )
|
||||
+void WINAPI DECLSPEC_HIDDEN __regs_ExReleaseResourceLite( ERESOURCE *resource )
|
||||
+#else
|
||||
+DEFINE_FASTCALL1_WRAPPER( ExReleaseResourceLite )
|
||||
+void WINAPI ExReleaseResourceLite( ERESOURCE *resource )
|
||||
+#endif
|
||||
+{
|
||||
+ ExReleaseResourceForThreadLite( resource, (ERESOURCE_THREAD)KeGetCurrentThread() );
|
||||
+}
|
||||
|
@ -52,7 +52,7 @@ usage()
|
||||
# Get the upstream commit sha
|
||||
upstream_commit()
|
||||
{
|
||||
echo "d88f12950761e9ff8d125a579de6e743979f4945"
|
||||
echo "1e8f4c059befe4a026ddf5c56e81d720b35c6c2f"
|
||||
}
|
||||
|
||||
# Show version information
|
||||
|
@ -1,4 +1,4 @@
|
||||
From 3581c738e28a94fedb1c768b61242b5482f98f60 Mon Sep 17 00:00:00 2001
|
||||
From ace0554b58cca60956b36f1161c9c0c2a8df5510 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
|
||||
Date: Thu, 11 May 2017 05:32:55 +0200
|
||||
Subject: [PATCH] winebuild: Generate syscall thunks for ntdll exports.
|
||||
@ -8,16 +8,16 @@ Based on a patch by Erich E. Hoover.
|
||||
dlls/ntdll/signal_i386.c | 6 ++-
|
||||
dlls/ntdll/tests/exception.c | 2 +
|
||||
include/winternl.h | 2 +-
|
||||
tools/winebuild/build.h | 6 +++
|
||||
tools/winebuild/import.c | 10 +++--
|
||||
tools/winebuild/parser.c | 59 +++++++++++++++++++++++++++
|
||||
tools/winebuild/spec16.c | 22 +----------
|
||||
tools/winebuild/spec32.c | 94 ++++++++++++++++++++++++++++++++++++++++++++
|
||||
tools/winebuild/utils.c | 21 ++++++++++
|
||||
9 files changed, 195 insertions(+), 27 deletions(-)
|
||||
tools/winebuild/build.h | 8 ++-
|
||||
tools/winebuild/import.c | 10 ++--
|
||||
tools/winebuild/parser.c | 59 ++++++++++++++++++++++
|
||||
tools/winebuild/spec16.c | 22 +--------
|
||||
tools/winebuild/spec32.c | 94 ++++++++++++++++++++++++++++++++++++
|
||||
tools/winebuild/utils.c | 21 ++++++++
|
||||
9 files changed, 196 insertions(+), 28 deletions(-)
|
||||
|
||||
diff --git a/dlls/ntdll/signal_i386.c b/dlls/ntdll/signal_i386.c
|
||||
index c64cb05..ca91ec1 100644
|
||||
index daf9ae23..8dfcd0b5 100644
|
||||
--- a/dlls/ntdll/signal_i386.c
|
||||
+++ b/dlls/ntdll/signal_i386.c
|
||||
@@ -427,6 +427,9 @@ static size_t signal_stack_size;
|
||||
@ -39,7 +39,7 @@ index c64cb05..ca91ec1 100644
|
||||
context->SegCs = wine_get_cs();
|
||||
context->SegSs = wine_get_ss();
|
||||
context->EFlags = eflags;
|
||||
@@ -2330,6 +2333,7 @@ NTSTATUS signal_alloc_thread( TEB **teb )
|
||||
@@ -2317,6 +2320,7 @@ NTSTATUS signal_alloc_thread( TEB **teb )
|
||||
*teb = addr;
|
||||
(*teb)->Tib.Self = &(*teb)->Tib;
|
||||
(*teb)->Tib.ExceptionList = (void *)~0UL;
|
||||
@ -48,7 +48,7 @@ index c64cb05..ca91ec1 100644
|
||||
if (!(thread_data->fs = wine_ldt_alloc_fs()))
|
||||
{
|
||||
diff --git a/dlls/ntdll/tests/exception.c b/dlls/ntdll/tests/exception.c
|
||||
index 2f9d642..9bece2a 100644
|
||||
index b8bd1866..e795ab14 100644
|
||||
--- a/dlls/ntdll/tests/exception.c
|
||||
+++ b/dlls/ntdll/tests/exception.c
|
||||
@@ -1618,6 +1618,8 @@ static void test_thread_context(void)
|
||||
@ -61,10 +61,10 @@ index 2f9d642..9bece2a 100644
|
||||
ok( context.SegCs == LOWORD(expect.SegCs), "wrong SegCs %08x/%08x\n", context.SegCs, expect.SegCs );
|
||||
ok( context.SegDs == LOWORD(expect.SegDs), "wrong SegDs %08x/%08x\n", context.SegDs, expect.SegDs );
|
||||
diff --git a/include/winternl.h b/include/winternl.h
|
||||
index 152d596..953c055 100644
|
||||
index 12edd637..5d128b46 100644
|
||||
--- a/include/winternl.h
|
||||
+++ b/include/winternl.h
|
||||
@@ -358,7 +358,7 @@ typedef struct _TEB
|
||||
@@ -357,7 +357,7 @@ typedef struct _TEB
|
||||
PVOID CsrClientThread; /* 03c/0070 */
|
||||
PVOID Win32ThreadInfo; /* 040/0078 */
|
||||
ULONG Win32ClientInfo[31]; /* 044/0080 used for user32 private data in Wine */
|
||||
@ -74,10 +74,10 @@ index 152d596..953c055 100644
|
||||
ULONG FpSoftwareStatusRegister; /* 0c8/010c */
|
||||
PVOID SystemReserved1[54]; /* 0cc/0110 used for krnl386.exe16 private data in Wine */
|
||||
diff --git a/tools/winebuild/build.h b/tools/winebuild/build.h
|
||||
index fbc2cd9..086ff07 100644
|
||||
index eee98ebe..e883420c 100644
|
||||
--- a/tools/winebuild/build.h
|
||||
+++ b/tools/winebuild/build.h
|
||||
@@ -103,6 +103,7 @@ typedef struct
|
||||
@@ -102,6 +102,7 @@ typedef struct
|
||||
int flags;
|
||||
char *name; /* public name of this function */
|
||||
char *link_name; /* name of the C symbol to link to */
|
||||
@ -85,7 +85,7 @@ index fbc2cd9..086ff07 100644
|
||||
char *export_name; /* name exported under for noname exports */
|
||||
union
|
||||
{
|
||||
@@ -129,6 +130,7 @@ typedef struct
|
||||
@@ -128,6 +129,7 @@ typedef struct
|
||||
int alloc_entry_points; /* number of allocated entry points */
|
||||
int nb_names; /* number of entry points with names */
|
||||
unsigned int nb_resources; /* number of resources */
|
||||
@ -93,7 +93,7 @@ index fbc2cd9..086ff07 100644
|
||||
int characteristics; /* characteristics for the PE header */
|
||||
int dll_characteristics;/* DLL characteristics for the PE header */
|
||||
int subsystem; /* subsystem id */
|
||||
@@ -138,6 +140,7 @@ typedef struct
|
||||
@@ -137,6 +139,7 @@ typedef struct
|
||||
ORDDEF **names; /* array of entry point names (points into entry_points) */
|
||||
ORDDEF **ordinals; /* array of dll ordinals (points into entry_points) */
|
||||
struct resource *resources; /* array of dll resources (format differs between Win16/Win32) */
|
||||
@ -101,15 +101,18 @@ index fbc2cd9..086ff07 100644
|
||||
} DLLSPEC;
|
||||
|
||||
enum target_cpu
|
||||
@@ -177,6 +180,7 @@ struct strarray
|
||||
#define FLAG_FORWARD 0x100 /* function is a forwarded name */
|
||||
#define FLAG_EXT_LINK 0x200 /* function links to an external symbol */
|
||||
#define FLAG_EXPORT32 0x400 /* 32-bit export in 16-bit spec file */
|
||||
+#define FLAG_SYSCALL 0x800 /* function should be called through a syscall thunk */
|
||||
@@ -178,8 +181,9 @@ struct strarray
|
||||
#define FLAG_FORWARD 0x200 /* function is a forwarded name */
|
||||
#define FLAG_EXT_LINK 0x400 /* function links to an external symbol */
|
||||
#define FLAG_EXPORT32 0x800 /* 32-bit export in 16-bit spec file */
|
||||
+#define FLAG_SYSCALL 0x1000 /* function should be called through a syscall thunk */
|
||||
|
||||
#define FLAG_CPU(cpu) (0x01000 << (cpu))
|
||||
-#define FLAG_CPU(cpu) (0x01000 << (cpu))
|
||||
+#define FLAG_CPU(cpu) (0x02000 << (cpu))
|
||||
#define FLAG_CPU_MASK (FLAG_CPU(CPU_LAST + 1) - FLAG_CPU(0))
|
||||
@@ -313,6 +317,8 @@ extern void add_16bit_exports( DLLSPEC *spec32, DLLSPEC *spec16 );
|
||||
#define FLAG_CPU_WIN64 (FLAG_CPU(CPU_x86_64) | FLAG_CPU(CPU_ARM64))
|
||||
#define FLAG_CPU_WIN32 (FLAG_CPU_MASK & ~FLAG_CPU_WIN64)
|
||||
@@ -314,6 +318,8 @@ extern void add_16bit_exports( DLLSPEC *spec32, DLLSPEC *spec16 );
|
||||
extern int parse_spec_file( FILE *file, DLLSPEC *spec );
|
||||
extern int parse_def_file( FILE *file, DLLSPEC *spec );
|
||||
|
||||
@ -119,7 +122,7 @@ index fbc2cd9..086ff07 100644
|
||||
|
||||
extern int byte_swapped;
|
||||
diff --git a/tools/winebuild/import.c b/tools/winebuild/import.c
|
||||
index 5e5866c..ad970c1 100644
|
||||
index 893691ea..c39d9b53 100644
|
||||
--- a/tools/winebuild/import.c
|
||||
+++ b/tools/winebuild/import.c
|
||||
@@ -451,6 +451,7 @@ static void check_undefined_forwards( DLLSPEC *spec )
|
||||
@ -140,7 +143,7 @@ index 5e5866c..ad970c1 100644
|
||||
{
|
||||
switch(odp->type)
|
||||
{
|
||||
@@ -470,14 +472,14 @@ static void check_undefined_exports( DLLSPEC *spec )
|
||||
@@ -469,14 +471,14 @@ static void check_undefined_exports( DLLSPEC *spec )
|
||||
if (link_ext_symbols)
|
||||
{
|
||||
odp->flags |= FLAG_EXT_LINK;
|
||||
@ -159,10 +162,10 @@ index 5e5866c..ad970c1 100644
|
||||
}
|
||||
}
|
||||
diff --git a/tools/winebuild/parser.c b/tools/winebuild/parser.c
|
||||
index ad99654..c4b9abf 100644
|
||||
index dfb7f6f8..b758ca0d 100644
|
||||
--- a/tools/winebuild/parser.c
|
||||
+++ b/tools/winebuild/parser.c
|
||||
@@ -519,6 +519,24 @@ static const char *parse_spec_flags( DLLSPEC *spec, ORDDEF *odp )
|
||||
@@ -547,6 +547,24 @@ static const char *parse_spec_flags( DLLSPEC *spec, ORDDEF *odp )
|
||||
}
|
||||
|
||||
|
||||
@ -187,7 +190,7 @@ index ad99654..c4b9abf 100644
|
||||
/*******************************************************************
|
||||
* parse_spec_ordinal
|
||||
*
|
||||
@@ -587,6 +605,14 @@ static int parse_spec_ordinal( int ordinal, DLLSPEC *spec )
|
||||
@@ -622,6 +640,14 @@ static int parse_spec_ordinal( int ordinal, DLLSPEC *spec )
|
||||
assert( 0 );
|
||||
}
|
||||
|
||||
@ -202,7 +205,7 @@ index ad99654..c4b9abf 100644
|
||||
if ((odp->flags & FLAG_CPU_MASK) && !(odp->flags & FLAG_CPU(target_cpu)))
|
||||
{
|
||||
/* ignore this entry point */
|
||||
@@ -783,6 +809,37 @@ static void assign_ordinals( DLLSPEC *spec )
|
||||
@@ -818,6 +844,37 @@ static void assign_ordinals( DLLSPEC *spec )
|
||||
}
|
||||
|
||||
|
||||
@ -240,7 +243,7 @@ index ad99654..c4b9abf 100644
|
||||
/*******************************************************************
|
||||
* add_16bit_exports
|
||||
*
|
||||
@@ -884,6 +941,8 @@ int parse_spec_file( FILE *file, DLLSPEC *spec )
|
||||
@@ -919,6 +976,8 @@ int parse_spec_file( FILE *file, DLLSPEC *spec )
|
||||
current_line = 0; /* no longer parsing the input file */
|
||||
assign_names( spec );
|
||||
assign_ordinals( spec );
|
||||
@ -250,13 +253,14 @@ index ad99654..c4b9abf 100644
|
||||
}
|
||||
|
||||
diff --git a/tools/winebuild/spec16.c b/tools/winebuild/spec16.c
|
||||
index 85bcf09..54aad5d 100644
|
||||
index 85bcf099..54aad5d9 100644
|
||||
--- a/tools/winebuild/spec16.c
|
||||
+++ b/tools/winebuild/spec16.c
|
||||
@@ -494,27 +494,6 @@ static int relay_type_compare( const void *e1, const void *e2 )
|
||||
@@ -493,27 +493,6 @@ static int relay_type_compare( const void *e1, const void *e2 )
|
||||
}
|
||||
|
||||
|
||||
/*******************************************************************
|
||||
-/*******************************************************************
|
||||
- * sort_func_list
|
||||
- *
|
||||
- * Sort a list of functions, removing duplicates.
|
||||
@ -277,10 +281,9 @@ index 85bcf09..54aad5d 100644
|
||||
-}
|
||||
-
|
||||
-
|
||||
-/*******************************************************************
|
||||
/*******************************************************************
|
||||
* output_module16
|
||||
*
|
||||
* Output code for a 16-bit module.
|
||||
@@ -542,6 +521,7 @@ static void output_module16( DLLSPEC *spec )
|
||||
entry_point->flags = FLAG_REGISTER;
|
||||
entry_point->name = NULL;
|
||||
@ -290,13 +293,14 @@ index 85bcf09..54aad5d 100644
|
||||
entry_point->u.func.nb_args = 0;
|
||||
assert( !spec->ordinals[0] );
|
||||
diff --git a/tools/winebuild/spec32.c b/tools/winebuild/spec32.c
|
||||
index 3552eca..d851537 100644
|
||||
index 44d1c2c4..9727601f 100644
|
||||
--- a/tools/winebuild/spec32.c
|
||||
+++ b/tools/winebuild/spec32.c
|
||||
@@ -342,6 +342,99 @@ static void output_relay_debug( DLLSPEC *spec )
|
||||
}
|
||||
}
|
||||
|
||||
/*******************************************************************
|
||||
+/*******************************************************************
|
||||
+ * output_syscall_thunks
|
||||
+ *
|
||||
+ * Output entry points for system call functions
|
||||
@ -389,10 +393,9 @@ index 3552eca..d851537 100644
|
||||
+ output_function_size( "__wine_syscall_dispatcher" );
|
||||
+}
|
||||
+
|
||||
+/*******************************************************************
|
||||
/*******************************************************************
|
||||
* output_exports
|
||||
*
|
||||
* Output the export table for a Win32 module.
|
||||
@@ -691,6 +784,7 @@ void BuildSpec32File( DLLSPEC *spec )
|
||||
resolve_imports( spec );
|
||||
output_standard_file_header();
|
||||
@ -402,10 +405,10 @@ index 3552eca..d851537 100644
|
||||
output_exports( spec );
|
||||
output_imports( spec );
|
||||
diff --git a/tools/winebuild/utils.c b/tools/winebuild/utils.c
|
||||
index 95da175..b01d598 100644
|
||||
index 78e96454..bb9e8ac3 100644
|
||||
--- a/tools/winebuild/utils.c
|
||||
+++ b/tools/winebuild/utils.c
|
||||
@@ -794,6 +794,7 @@ void free_dll_spec( DLLSPEC *spec )
|
||||
@@ -795,6 +795,7 @@ void free_dll_spec( DLLSPEC *spec )
|
||||
free( odp->name );
|
||||
free( odp->export_name );
|
||||
free( odp->link_name );
|
||||
@ -413,7 +416,7 @@ index 95da175..b01d598 100644
|
||||
}
|
||||
free( spec->file_name );
|
||||
free( spec->dll_name );
|
||||
@@ -803,6 +804,7 @@ void free_dll_spec( DLLSPEC *spec )
|
||||
@@ -804,6 +805,7 @@ void free_dll_spec( DLLSPEC *spec )
|
||||
free( spec->names );
|
||||
free( spec->ordinals );
|
||||
free( spec->resources );
|
||||
@ -421,7 +424,7 @@ index 95da175..b01d598 100644
|
||||
free( spec );
|
||||
}
|
||||
|
||||
@@ -1130,3 +1132,22 @@ const char *get_asm_string_section(void)
|
||||
@@ -1131,3 +1133,22 @@ const char *get_asm_string_section(void)
|
||||
default: return ".section .rodata";
|
||||
}
|
||||
}
|
||||
@ -445,5 +448,5 @@ index 95da175..b01d598 100644
|
||||
+ return j + 1;
|
||||
+}
|
||||
--
|
||||
1.9.1
|
||||
2.20.1
|
||||
|
||||
|
@ -1,22 +1,22 @@
|
||||
From c3d774f0b6613aac336b3a2ed28452fbb6a5f9c1 Mon Sep 17 00:00:00 2001
|
||||
From 4b84757bba03d22cb225103cc7e52805a8d223f0 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
|
||||
Date: Mon, 15 May 2017 16:27:56 +0200
|
||||
Subject: winebuild: Add stub functions in fake dlls.
|
||||
|
||||
---
|
||||
dlls/kernel32/tests/loader.c | 8 +-
|
||||
dlls/ntdll/signal_i386.c | 40 +++++++++
|
||||
dlls/ntdll/signal_i386.c | 40 +++++++
|
||||
include/winternl.h | 2 +-
|
||||
tools/winebuild/build.h | 1 +
|
||||
tools/winebuild/spec32.c | 209 +++++++++++++++++++++++++++++++++++++++++--
|
||||
tools/winebuild/utils.c | 10 ++-
|
||||
tools/winebuild/spec32.c | 209 +++++++++++++++++++++++++++++++++--
|
||||
tools/winebuild/utils.c | 10 +-
|
||||
6 files changed, 255 insertions(+), 15 deletions(-)
|
||||
|
||||
diff --git a/dlls/kernel32/tests/loader.c b/dlls/kernel32/tests/loader.c
|
||||
index e9b05013875..6be54321d50 100644
|
||||
index 589e9f66..4a35a592 100644
|
||||
--- a/dlls/kernel32/tests/loader.c
|
||||
+++ b/dlls/kernel32/tests/loader.c
|
||||
@@ -892,9 +892,7 @@ static void test_FakeDLL(void)
|
||||
@@ -1550,9 +1550,7 @@ static void test_FakeDLL(void)
|
||||
ok(ptr != NULL, "MapViewOfFile failed with error %u\n", GetLastError());
|
||||
|
||||
dir = RtlImageDirectoryEntryToData(ptr, TRUE, IMAGE_DIRECTORY_ENTRY_EXPORT, &size);
|
||||
@ -26,7 +26,7 @@ index e9b05013875..6be54321d50 100644
|
||||
|
||||
names = RVAToAddr(dir->AddressOfNames, ptr);
|
||||
ordinals = RVAToAddr(dir->AddressOfNameOrdinals, ptr);
|
||||
@@ -923,17 +921,20 @@ todo_wine
|
||||
@@ -1581,17 +1579,20 @@ todo_wine
|
||||
/* check position in memory */
|
||||
dll_rva = (DWORD_PTR)dll_func - (DWORD_PTR)module;
|
||||
map_rva = funcs[ordinals[i]];
|
||||
@ -47,7 +47,7 @@ index e9b05013875..6be54321d50 100644
|
||||
ok(!memcmp(map_func, dll_func, 0x20), "%s: Function content does not match!\n", func_name);
|
||||
|
||||
if (!strcmp(func_name, "NtSetEvent"))
|
||||
@@ -947,10 +948,11 @@ todo_wine
|
||||
@@ -1605,10 +1606,11 @@ todo_wine
|
||||
ok(event != NULL, "CreateEvent failed with error %u\n", GetLastError());
|
||||
pNtSetEvent(event, 0);
|
||||
ok(WaitForSingleObject(event, 0) == WAIT_OBJECT_0, "Event was not signaled\n");
|
||||
@ -61,10 +61,10 @@ index e9b05013875..6be54321d50 100644
|
||||
CloseHandle(map);
|
||||
CloseHandle(file);
|
||||
diff --git a/dlls/ntdll/signal_i386.c b/dlls/ntdll/signal_i386.c
|
||||
index d015c4ea831..3818e696c49 100644
|
||||
index 8dfcd0b5..4a4eb047 100644
|
||||
--- a/dlls/ntdll/signal_i386.c
|
||||
+++ b/dlls/ntdll/signal_i386.c
|
||||
@@ -484,6 +484,45 @@ extern void DECLSPEC_NORETURN __wine_restore_regs( const CONTEXT *context );
|
||||
@@ -430,6 +430,45 @@ static wine_signal_handler handlers[256];
|
||||
extern void DECLSPEC_NORETURN __wine_syscall_dispatcher( void );
|
||||
extern NTSTATUS WINAPI __syscall_NtGetContextThread( HANDLE handle, CONTEXT *context );
|
||||
|
||||
@ -110,7 +110,7 @@ index d015c4ea831..3818e696c49 100644
|
||||
enum i386_trap_code
|
||||
{
|
||||
TRAP_x86_UNKNOWN = -1, /* Unknown fault (TRAP_sig not defined) */
|
||||
@@ -2472,6 +2511,7 @@ NTSTATUS signal_alloc_thread( TEB **teb )
|
||||
@@ -2321,6 +2360,7 @@ NTSTATUS signal_alloc_thread( TEB **teb )
|
||||
(*teb)->Tib.Self = &(*teb)->Tib;
|
||||
(*teb)->Tib.ExceptionList = (void *)~0UL;
|
||||
(*teb)->WOW32Reserved = __wine_syscall_dispatcher;
|
||||
@ -119,10 +119,10 @@ index d015c4ea831..3818e696c49 100644
|
||||
if (!(thread_data->fs = wine_ldt_alloc_fs()))
|
||||
{
|
||||
diff --git a/include/winternl.h b/include/winternl.h
|
||||
index b1871e689fa..140669b0105 100644
|
||||
index 5d128b46..64640f4b 100644
|
||||
--- a/include/winternl.h
|
||||
+++ b/include/winternl.h
|
||||
@@ -363,7 +363,7 @@ typedef struct _TEB
|
||||
@@ -397,7 +397,7 @@ typedef struct _TEB
|
||||
PVOID WinSockData; /* f6c/1738 */
|
||||
ULONG GdiBatchCount; /* f70/1740 */
|
||||
ULONG Spare2; /* f74/1744 */
|
||||
@ -132,10 +132,10 @@ index b1871e689fa..140669b0105 100644
|
||||
PVOID ReservedForOle; /* f80/1758 */
|
||||
ULONG WaitingOnLoaderLock; /* f84/1760 */
|
||||
diff --git a/tools/winebuild/build.h b/tools/winebuild/build.h
|
||||
index 3434cfe9c90..e76800bb5da 100644
|
||||
index 56e9af3d..6b12d496 100644
|
||||
--- a/tools/winebuild/build.h
|
||||
+++ b/tools/winebuild/build.h
|
||||
@@ -343,6 +343,7 @@ extern void put_word( unsigned short val );
|
||||
@@ -344,6 +344,7 @@ extern void put_word( unsigned short val );
|
||||
extern void put_dword( unsigned int val );
|
||||
extern void put_qword( unsigned int val );
|
||||
extern void put_pword( unsigned int val );
|
||||
@ -144,10 +144,10 @@ index 3434cfe9c90..e76800bb5da 100644
|
||||
extern void align_output_rva( unsigned int file_align, unsigned int rva_align );
|
||||
extern size_t label_pos( const char *name );
|
||||
diff --git a/tools/winebuild/spec32.c b/tools/winebuild/spec32.c
|
||||
index 623d3f2d553..c6e2fec99a6 100644
|
||||
index 55587cb6..2f172033 100644
|
||||
--- a/tools/winebuild/spec32.c
|
||||
+++ b/tools/winebuild/spec32.c
|
||||
@@ -738,6 +738,163 @@ void BuildSpec32File( DLLSPEC *spec )
|
||||
@@ -794,6 +794,163 @@ void BuildSpec32File( DLLSPEC *spec )
|
||||
}
|
||||
|
||||
|
||||
@ -185,7 +185,7 @@ index 623d3f2d553..c6e2fec99a6 100644
|
||||
+ put_byte( 0xe8 ); put_dword( label_rva("_forward") - rva ); /* call _forward */
|
||||
+ put_byte( 0x89 ); put_byte( 0xec ); /* mov esp, ebp */
|
||||
+ put_byte( 0x5d ); /* pop ebp */
|
||||
+ if (odp->type == TYPE_STDCALL || odp->type == TYPE_THISCALL)
|
||||
+ if (odp->type == TYPE_STDCALL)
|
||||
+ {
|
||||
+ put_byte( 0xc2 ); put_word( get_args_size(odp) ); /* ret X */
|
||||
+ }
|
||||
@ -311,7 +311,7 @@ index 623d3f2d553..c6e2fec99a6 100644
|
||||
/*******************************************************************
|
||||
* output_fake_module_pass
|
||||
*
|
||||
@@ -756,7 +913,7 @@ static void output_fake_module_pass( DLLSPEC *spec )
|
||||
@@ -812,7 +969,7 @@ static void output_fake_module_pass( DLLSPEC *spec )
|
||||
const unsigned int section_align = page_size;
|
||||
const unsigned int file_align = 0x200;
|
||||
const unsigned int lfanew = (0x40 + sizeof(fakedll_signature) + 15) & ~15;
|
||||
@ -320,7 +320,7 @@ index 623d3f2d553..c6e2fec99a6 100644
|
||||
|
||||
put_word( 0x5a4d ); /* e_magic */
|
||||
put_word( 0x40 ); /* e_cblp */
|
||||
@@ -813,7 +970,7 @@ static void output_fake_module_pass( DLLSPEC *spec )
|
||||
@@ -869,7 +1026,7 @@ static void output_fake_module_pass( DLLSPEC *spec )
|
||||
put_dword( 0 ); /* SizeOfUninitializedData */
|
||||
put_dword( label_rva("entrypoint") ); /* AddressOfEntryPoint */
|
||||
put_dword( label_rva("text_start") ); /* BaseOfCode */
|
||||
@ -329,7 +329,7 @@ index 623d3f2d553..c6e2fec99a6 100644
|
||||
put_pword( 0x10000000 ); /* ImageBase */
|
||||
put_dword( section_align ); /* SectionAlignment */
|
||||
put_dword( file_align ); /* FileAlignment */
|
||||
@@ -836,7 +993,8 @@ static void output_fake_module_pass( DLLSPEC *spec )
|
||||
@@ -892,7 +1049,8 @@ static void output_fake_module_pass( DLLSPEC *spec )
|
||||
put_dword( 0 ); /* LoaderFlags */
|
||||
put_dword( 16 ); /* NumberOfRvaAndSizes */
|
||||
|
||||
@ -339,7 +339,7 @@ index 623d3f2d553..c6e2fec99a6 100644
|
||||
put_dword( 0 ); put_dword( 0 ); /* DataDirectory[IMAGE_DIRECTORY_ENTRY_IMPORT] */
|
||||
if (spec->nb_resources) /* DataDirectory[IMAGE_DIRECTORY_ENTRY_RESOURCE] */
|
||||
{
|
||||
@@ -876,6 +1034,21 @@ static void output_fake_module_pass( DLLSPEC *spec )
|
||||
@@ -932,6 +1090,21 @@ static void output_fake_module_pass( DLLSPEC *spec )
|
||||
put_word( 0 ); /* NumberOfLinenumbers */
|
||||
put_dword( 0x60000020 /* CNT_CODE|MEM_EXECUTE|MEM_READ */ ); /* Characteristics */
|
||||
|
||||
@ -361,7 +361,7 @@ index 623d3f2d553..c6e2fec99a6 100644
|
||||
/* .reloc section */
|
||||
put_data( ".reloc\0", 8 ); /* Name */
|
||||
put_dword( label_rva_align("reloc_end") - label_rva("reloc_start") ); /* VirtualSize */
|
||||
@@ -908,13 +1081,31 @@ static void output_fake_module_pass( DLLSPEC *spec )
|
||||
@@ -964,13 +1137,31 @@ static void output_fake_module_pass( DLLSPEC *spec )
|
||||
|
||||
/* .text contents */
|
||||
align_output_rva( file_align, section_align );
|
||||
@ -400,10 +400,10 @@ index 623d3f2d553..c6e2fec99a6 100644
|
||||
/* .reloc contents */
|
||||
align_output_rva( file_align, section_align );
|
||||
diff --git a/tools/winebuild/utils.c b/tools/winebuild/utils.c
|
||||
index eada46604ec..eee5419285a 100644
|
||||
index b9c2b329..f4ed3261 100644
|
||||
--- a/tools/winebuild/utils.c
|
||||
+++ b/tools/winebuild/utils.c
|
||||
@@ -525,7 +525,7 @@ size_t output_buffer_size;
|
||||
@@ -528,7 +528,7 @@ size_t output_buffer_size;
|
||||
struct label
|
||||
{
|
||||
struct list entry;
|
||||
@ -412,7 +412,7 @@ index eada46604ec..eee5419285a 100644
|
||||
size_t pos;
|
||||
size_t rva;
|
||||
};
|
||||
@@ -543,7 +543,7 @@ struct label *get_label( const char *name )
|
||||
@@ -546,7 +546,7 @@ struct label *get_label( const char *name )
|
||||
}
|
||||
|
||||
label = xmalloc( sizeof(*label) );
|
||||
@ -421,7 +421,7 @@ index eada46604ec..eee5419285a 100644
|
||||
label->pos = 0;
|
||||
label->rva = 0;
|
||||
|
||||
@@ -595,6 +595,7 @@ void free_labels( void )
|
||||
@@ -598,6 +598,7 @@ void free_labels( void )
|
||||
LIST_FOR_EACH_ENTRY_SAFE( label, label2, &labels, struct label, entry )
|
||||
{
|
||||
list_remove( &label->entry );
|
||||
@ -429,7 +429,7 @@ index eada46604ec..eee5419285a 100644
|
||||
free( label );
|
||||
}
|
||||
}
|
||||
@@ -729,6 +730,11 @@ void put_pword( unsigned int val )
|
||||
@@ -732,6 +733,11 @@ void put_pword( unsigned int val )
|
||||
else put_dword( val );
|
||||
}
|
||||
|
||||
@ -442,5 +442,5 @@ index eada46604ec..eee5419285a 100644
|
||||
{
|
||||
size_t size = align - (output_buffer_pos % align);
|
||||
--
|
||||
2.13.1
|
||||
2.20.1
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user