Rebase against 8ef224fa43869a8c977921d6bec08863382d6e11

This commit is contained in:
Alistair Leslie-Hughes 2018-07-10 08:39:20 +10:00
parent 738fd3fd35
commit f61b8570b8
13 changed files with 56 additions and 724 deletions

View File

@ -1,28 +0,0 @@
From 46302575f68264f8b097a663bee06e8624fa69ad Mon Sep 17 00:00:00 2001
From: Sebastian Lackner <sebastian@fds-team.de>
Date: Sun, 1 May 2016 16:45:31 +0200
Subject: kernel32: Fill stack with meaningful values in call_process_entry
mis-align workaround.
---
dlls/kernel32/process.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/dlls/kernel32/process.c b/dlls/kernel32/process.c
index 4771108..28ec659 100644
--- a/dlls/kernel32/process.c
+++ b/dlls/kernel32/process.c
@@ -1064,7 +1064,9 @@ __ASM_GLOBAL_FUNC( call_process_entry,
__ASM_CFI(".cfi_rel_offset %ebp,0\n\t")
"movl %esp,%ebp\n\t"
__ASM_CFI(".cfi_def_cfa_register %ebp\n\t")
- "subl $12,%esp\n\t" /* deliberately mis-align the stack by 8, Doom 3 needs this */
+ "pushl 4(%ebp)\n\t" /* deliberately mis-align the stack by 8, Doom 3 needs this */
+ "pushl 4(%ebp)\n\t" /* Driller expects readable address at this offset */
+ "pushl 4(%ebp)\n\t"
"pushl 8(%ebp)\n\t"
"call *12(%ebp)\n\t"
"leave\n\t"
--
2.8.0

View File

@ -1 +0,0 @@
Fixes: [24374] Fill stack with meaningful values in call_process_entry mis-align workaround

View File

@ -1,2 +1 @@
Fixes: [42125] Various PE loader fixes for 8k demos
Depends: kernel32-Misalign_Workaround

View File

@ -1,57 +0,0 @@
From 3418775c892b4fff2dd9ca879b7d4d1059bd065b Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
Date: Fri, 15 Jan 2016 12:58:17 +0100
Subject: [PATCH] msvcr120: Add stub for _SetWinRTOutOfMemoryExceptionCallback.
---
dlls/msvcr120/msvcr120.spec | 2 +-
dlls/msvcr120_app/msvcr120_app.spec | 2 +-
dlls/msvcrt/misc.c | 8 ++++++++
3 files changed, 10 insertions(+), 2 deletions(-)
diff --git a/dlls/msvcr120/msvcr120.spec b/dlls/msvcr120/msvcr120.spec
index b6f0e1f..19088e4 100644
--- a/dlls/msvcr120/msvcr120.spec
+++ b/dlls/msvcr120/msvcr120.spec
@@ -844,7 +844,7 @@
@ stub -arch=i386 _NLG_Return
@ stub -arch=i386 _NLG_Return2
@ stub -arch=arm,win64 __NLG_Return2
-@ stub _SetWinRTOutOfMemoryExceptionCallback
+@ cdecl -arch=i386,x86_64,arm _SetWinRTOutOfMemoryExceptionCallback(ptr) MSVCR120__SetWinRTOutOfMemoryExceptionCallback
@ stub -arch=win64 _SetImageBase
@ stub -arch=win64 _SetThrowImageBase
@ cdecl _Strftime(ptr long str ptr ptr)
diff --git a/dlls/msvcr120_app/msvcr120_app.spec b/dlls/msvcr120_app/msvcr120_app.spec
index 7a9b6aa..166d6b8 100644
--- a/dlls/msvcr120_app/msvcr120_app.spec
+++ b/dlls/msvcr120_app/msvcr120_app.spec
@@ -838,7 +838,7 @@
@ stub -arch=i386 _NLG_Return
@ stub -arch=i386 _NLG_Return2
@ stub -arch=arm,win64 __NLG_Return2
-@ stub _SetWinRTOutOfMemoryExceptionCallback
+@ cdecl -arch=i386,x86_64,arm _SetWinRTOutOfMemoryExceptionCallback(ptr) msvcr120._SetWinRTOutOfMemoryExceptionCallback
@ stub -arch=win64 _SetImageBase
@ stub -arch=win64 _SetThrowImageBase
@ cdecl _Strftime(ptr long str ptr ptr) msvcr120._Strftime
diff --git a/dlls/msvcrt/misc.c b/dlls/msvcrt/misc.c
index c197d69..c5f8f42 100644
--- a/dlls/msvcrt/misc.c
+++ b/dlls/msvcrt/misc.c
@@ -578,4 +578,12 @@ void CDECL MSVCRT__crtSleep(DWORD timeout)
TRACE("(%u)\n", timeout);
Sleep(timeout);
}
+
+/*********************************************************************
+ * _SetWinRTOutOfMemoryExceptionCallback (MSVCR120.@)
+ */
+void CDECL MSVCR120__SetWinRTOutOfMemoryExceptionCallback(void *callback)
+{
+ FIXME("(%p): stub\n", callback);
+}
#endif
--
1.9.1

View File

@ -1 +0,0 @@
Fixes: [45394] Add stub for _SetWinRTOutOfMemoryExceptionCallback

View File

@ -1,501 +0,0 @@
From 34d880216777154f9fef645795783a6deaddf2f8 Mon Sep 17 00:00:00 2001
From: Mark Jansen <learn0more+wine@gmail.com>
Date: Sun, 8 Mar 2015 18:24:45 +0100
Subject: ntdll/tests: Tests for RtlIpv6StringToAddress (try 6)
Changes from try5:
-Reformat ipv6 table to be less wide
-Remove _s6_un from memcmp calls
Changes from try4:
-Use RtlMultiByteToUnicodeN for A->W conversion as suggested by stefand on
Changes from try3:
-Also test the W version against the A version
-Expand the test with more corner cases
-replace the 'broken' int with an enum as suggested by stefand
-add comments to the flags, explaining their purpose.
-initialize ipv6 from int array in a small function to avoid code
duplication
---
dlls/ntdll/tests/rtl.c | 430 +++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 430 insertions(+)
diff --git a/dlls/ntdll/tests/rtl.c b/dlls/ntdll/tests/rtl.c
index ac463c6..657c1ae 100644
--- a/dlls/ntdll/tests/rtl.c
+++ b/dlls/ntdll/tests/rtl.c
@@ -25,6 +25,7 @@
#include "ntdll_test.h"
#include "inaddr.h"
+#include "in6addr.h"
#include "initguid.h"
#define COBJMACROS
#include "shobjidl.h"
@@ -92,9 +93,12 @@ static IMAGE_BASE_RELOCATION *(WINAPI *pLdrProcessRelocationBlock)(void*,UINT,US
static CHAR * (WINAPI *pRtlIpv4AddressToStringA)(const IN_ADDR *, LPSTR);
static NTSTATUS (WINAPI *pRtlIpv4AddressToStringExA)(const IN_ADDR *, USHORT, LPSTR, PULONG);
static NTSTATUS (WINAPI *pRtlIpv4StringToAddressA)(PCSTR, BOOLEAN, PCSTR *, IN_ADDR *);
+static NTSTATUS (WINAPI *pRtlIpv6StringToAddressA)(PCSTR, PCSTR *, struct in6_addr *);
+static NTSTATUS (WINAPI *pRtlIpv6StringToAddressW)(PCWSTR, PCWSTR *, struct in6_addr *);
static NTSTATUS (WINAPI *pLdrAddRefDll)(ULONG, HMODULE);
static NTSTATUS (WINAPI *pLdrLockLoaderLock)(ULONG, ULONG*, ULONG_PTR*);
static NTSTATUS (WINAPI *pLdrUnlockLoaderLock)(ULONG, ULONG_PTR);
+static NTSTATUS (WINAPI *pRtlMultiByteToUnicodeN)(LPWSTR, DWORD, LPDWORD, LPCSTR, DWORD);
static NTSTATUS (WINAPI *pRtlGetCompressionWorkSpaceSize)(USHORT, PULONG, PULONG);
static NTSTATUS (WINAPI *pRtlDecompressBuffer)(USHORT, PUCHAR, ULONG, const UCHAR*, ULONG, PULONG);
static NTSTATUS (WINAPI *pRtlDecompressFragment)(USHORT, PUCHAR, ULONG, const UCHAR*, ULONG, ULONG, PULONG, PVOID);
@@ -146,9 +150,12 @@ static void InitFunctionPtrs(void)
pRtlIpv4AddressToStringA = (void *)GetProcAddress(hntdll, "RtlIpv4AddressToStringA");
pRtlIpv4AddressToStringExA = (void *)GetProcAddress(hntdll, "RtlIpv4AddressToStringExA");
pRtlIpv4StringToAddressA = (void *)GetProcAddress(hntdll, "RtlIpv4StringToAddressA");
+ pRtlIpv6StringToAddressA = (void *)GetProcAddress(hntdll, "RtlIpv6StringToAddressA");
+ pRtlIpv6StringToAddressW = (void *)GetProcAddress(hntdll, "RtlIpv6StringToAddressW");
pLdrAddRefDll = (void *)GetProcAddress(hntdll, "LdrAddRefDll");
pLdrLockLoaderLock = (void *)GetProcAddress(hntdll, "LdrLockLoaderLock");
pLdrUnlockLoaderLock = (void *)GetProcAddress(hntdll, "LdrUnlockLoaderLock");
+ pRtlMultiByteToUnicodeN = (void *)GetProcAddress(hntdll, "RtlMultiByteToUnicodeN");
pRtlGetCompressionWorkSpaceSize = (void *)GetProcAddress(hntdll, "RtlGetCompressionWorkSpaceSize");
pRtlDecompressBuffer = (void *)GetProcAddress(hntdll, "RtlDecompressBuffer");
pRtlDecompressFragment = (void *)GetProcAddress(hntdll, "RtlDecompressFragment");
@@ -1303,6 +1310,428 @@ static void test_RtlIpv4StringToAddress(void)
}
}
+
+/* ipv6 addresses based on the set from https://github.com/beaugunderson/javascript-ipv6/tree/master/test/data */
+static const struct
+{
+ PCSTR address;
+ NTSTATUS res;
+ int terminator_offset;
+ int ip[8];
+ /* win_broken: older versions of windows do not handle this correct
+ ex_fail: Ex function does need the string to be terminated, non-Ex does not.
+ ex_skip: test doesnt make sense for Ex (f.e. it's invalid for non-Ex but valid for Ex) */
+ enum { normal_6, win_broken_6 = 1, ex_fail_6 = 2, ex_skip_6 = 4 } flags;
+} ipv6_tests[] =
+{
+ { "0000:0000:0000:0000:0000:0000:0000:0000", STATUS_SUCCESS, 39,
+ { 0, 0, 0, 0, 0, 0, 0, 0 } },
+ { "0000:0000:0000:0000:0000:0000:0000:0001", STATUS_SUCCESS, 39,
+ { 0, 0, 0, 0, 0, 0, 0, 0x100 } },
+ { "0:0:0:0:0:0:0:0", STATUS_SUCCESS, 15,
+ { 0, 0, 0, 0, 0, 0, 0, 0 } },
+ { "0:0:0:0:0:0:0:1", STATUS_SUCCESS, 15,
+ { 0, 0, 0, 0, 0, 0, 0, 0x100 } },
+ { "0:0:0:0:0:0:0::", STATUS_SUCCESS, 13,
+ { 0, 0, 0, 0, 0, 0, 0, 0 }, win_broken_6 },
+ { "0:0:0:0:0:0:13.1.68.3", STATUS_SUCCESS, 21,
+ { 0, 0, 0, 0, 0, 0, 0x10d, 0x344 } },
+ { "0:0:0:0:0:0::", STATUS_SUCCESS, 13,
+ { 0, 0, 0, 0, 0, 0, 0, 0 } },
+ { "0:0:0:0:0::", STATUS_SUCCESS, 11,
+ { 0, 0, 0, 0, 0, 0, 0, 0 } },
+ { "0:0:0:0:0:FFFF:129.144.52.38", STATUS_SUCCESS, 28,
+ { 0, 0, 0, 0, 0, 0xffff, 0x9081, 0x2634 } },
+ { "0::", STATUS_SUCCESS, 3,
+ { 0, 0, 0, 0, 0, 0, 0, 0 } },
+ { "0:1:2:3:4:5:6:7", STATUS_SUCCESS, 15,
+ { 0, 0x100, 0x200, 0x300, 0x400, 0x500, 0x600, 0x700 } },
+ { "1080:0:0:0:8:800:200c:417a", STATUS_SUCCESS, 26,
+ { 0x8010, 0, 0, 0, 0x800, 0x8, 0x0c20, 0x7a41 } },
+ { "0:a:b:c:d:e:f::", STATUS_SUCCESS, 13,
+ { 0, 0xa00, 0xb00, 0xc00, 0xd00, 0xe00, 0xf00, 0 }, win_broken_6 },
+ { "1111:2222:3333:4444:5555:6666:123.123.123.123", STATUS_SUCCESS, 45,
+ { 0x1111, 0x2222, 0x3333, 0x4444, 0x5555, 0x6666, 0x7b7b, 0x7b7b } },
+ { "1111:2222:3333:4444:5555:6666:7777:8888", STATUS_SUCCESS, 39,
+ { 0x1111, 0x2222, 0x3333, 0x4444, 0x5555, 0x6666, 0x7777, 0x8888 } },
+ { "1111:2222:3333:4444:0x5555:6666:7777:8888", STATUS_INVALID_PARAMETER, 21,
+ { 0x1111, 0x2222, 0x3333, 0x4444, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "1111:2222:3333:4444:x555:6666:7777:8888", STATUS_INVALID_PARAMETER, 20,
+ { 0x1111, 0x2222, 0x3333, 0x4444, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "1111:2222:3333:4444:0r5555:6666:7777:8888", STATUS_INVALID_PARAMETER, 21,
+ { 0x1111, 0x2222, 0x3333, 0x4444, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "1111:2222:3333:4444:r5555:6666:7777:8888", STATUS_INVALID_PARAMETER, 20,
+ { 0x1111, 0x2222, 0x3333, 0x4444, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "1111:2222:3333:4444:5555:6666:7777::", STATUS_SUCCESS, 34,
+ { 0x1111, 0x2222, 0x3333, 0x4444, 0x5555, 0x6666, 0x7777, 0 }, win_broken_6 },
+ { "1111:2222:3333:4444:5555:6666::", STATUS_SUCCESS, 31,
+ { 0x1111, 0x2222, 0x3333, 0x4444, 0x5555, 0x6666, 0, 0 } },
+ { "1111:2222:3333:4444:5555:6666::8888", STATUS_SUCCESS, 35,
+ { 0x1111, 0x2222, 0x3333, 0x4444, 0x5555, 0x6666, 0, 0x8888 } },
+ { "1111:2222:3333:4444:5555::", STATUS_SUCCESS, 26,
+ { 0x1111, 0x2222, 0x3333, 0x4444, 0x5555, 0, 0, 0 } },
+ { "1111:2222:3333:4444:5555::123.123.123.123", STATUS_SUCCESS, 41,
+ { 0x1111, 0x2222, 0x3333, 0x4444, 0x5555, 0, 0x7b7b, 0x7b7b } },
+ { "1111:2222:3333:4444:5555::0x1.123.123.123", STATUS_SUCCESS, 27,
+ { 0x1111, 0x2222, 0x3333, 0x4444, 0x5555, 0, 0, 0x100 }, ex_fail_6 },
+ { "1111:2222:3333:4444:5555::0x88", STATUS_SUCCESS, 27,
+ { 0x1111, 0x2222, 0x3333, 0x4444, 0x5555, 0, 0, 0x8800 }, ex_fail_6 },
+ { "1111:2222:3333:4444:5555::0X88", STATUS_SUCCESS, 27,
+ { 0x1111, 0x2222, 0x3333, 0x4444, 0x5555, 0, 0, 0x8800 }, ex_fail_6 },
+ { "1111:2222:3333:4444:5555::0X", STATUS_SUCCESS, 27,
+ { 0x1111, 0x2222, 0x3333, 0x4444, 0x5555, 0, 0, 0 }, ex_fail_6 },
+ { "1111:2222:3333:4444:5555::0X88:7777", STATUS_SUCCESS, 27,
+ { 0x1111, 0x2222, 0x3333, 0x4444, 0x5555, 0, 0, 0x8800 }, ex_fail_6 },
+ { "1111:2222:3333:4444:5555::0x8888", STATUS_SUCCESS, 27,
+ { 0x1111, 0x2222, 0x3333, 0x4444, 0x5555, 0, 0, 0x8888 }, ex_fail_6 },
+ { "1111:2222:3333:4444:5555::08888", STATUS_INVALID_PARAMETER, 31,
+ { 0x1111, 0x2222, 0x3333, 0x4444, 0x5555, 0xabab, 0xabab, 0xabab } },
+ { "1111:2222:3333:4444:5555::fffff", STATUS_INVALID_PARAMETER, 31,
+ { 0x1111, 0x2222, 0x3333, 0x4444, 0x5555, 0xabab, 0xabab, 0xabab } },
+ { "1111:2222:3333:4444::fffff", STATUS_INVALID_PARAMETER, 26,
+ { 0x1111, 0x2222, 0x3333, 0x4444, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "1111:2222:3333::fffff", STATUS_INVALID_PARAMETER, 21,
+ { 0x1111, 0x2222, 0x3333, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "1111:2222:3333:4444:5555::7777:8888", STATUS_SUCCESS, 35,
+ { 0x1111, 0x2222, 0x3333, 0x4444, 0x5555, 0, 0x7777, 0x8888 } },
+ { "1111:2222:3333:4444:5555::8888", STATUS_SUCCESS, 30,
+ { 0x1111, 0x2222, 0x3333, 0x4444, 0x5555, 0, 0, 0x8888 } },
+ { "1111::", STATUS_SUCCESS, 6,
+ { 0x1111, 0, 0, 0, 0, 0, 0, 0 } },
+ { "1111::123.123.123.123", STATUS_SUCCESS, 21,
+ { 0x1111, 0, 0, 0, 0, 0, 0x7b7b, 0x7b7b } },
+ { "1111::3333:4444:5555:6666:123.123.123.123", STATUS_SUCCESS, 41,
+ { 0x1111, 0, 0x3333, 0x4444, 0x5555, 0x6666, 0x7b7b, 0x7b7b } },
+ { "1111::3333:4444:5555:6666:7777:8888", STATUS_SUCCESS, 35,
+ { 0x1111, 0, 0x3333, 0x4444, 0x5555, 0x6666, 0x7777, 0x8888 } },
+ { "1111::4444:5555:6666:123.123.123.123", STATUS_SUCCESS, 36,
+ { 0x1111, 0, 0, 0x4444, 0x5555, 0x6666, 0x7b7b, 0x7b7b } },
+ { "1111::4444:5555:6666:7777:8888", STATUS_SUCCESS, 30,
+ { 0x1111, 0, 0, 0x4444, 0x5555, 0x6666, 0x7777, 0x8888 } },
+ { "1111::5555:6666:123.123.123.123", STATUS_SUCCESS, 31,
+ { 0x1111, 0, 0, 0, 0x5555, 0x6666, 0x7b7b, 0x7b7b } },
+ { "1111::5555:6666:7777:8888", STATUS_SUCCESS, 25,
+ { 0x1111, 0, 0, 0, 0x5555, 0x6666, 0x7777, 0x8888 } },
+ { "1111::6666:123.123.123.123", STATUS_SUCCESS, 26,
+ { 0x1111, 0, 0, 0, 0, 0x6666, 0x7b7b, 0x7b7b } },
+ { "1111::6666:7777:8888", STATUS_SUCCESS, 20,
+ { 0x1111, 0, 0, 0, 0, 0x6666, 0x7777, 0x8888 } },
+ { "1111::7777:8888", STATUS_SUCCESS, 15,
+ { 0x1111, 0, 0, 0, 0, 0, 0x7777, 0x8888 } },
+ { "1111::8888", STATUS_SUCCESS, 10,
+ { 0x1111, 0, 0, 0, 0, 0, 0, 0x8888 } },
+ { "1:2:3:4:5:6:1.2.3.4", STATUS_SUCCESS, 19,
+ { 0x100, 0x200, 0x300, 0x400, 0x500, 0x600, 0x201, 0x403 } },
+ { "1:2:3:4:5:6:7:8", STATUS_SUCCESS, 15,
+ { 0x100, 0x200, 0x300, 0x400, 0x500, 0x600, 0x700, 0x800 } },
+ { "1:2:3:4:5:6::", STATUS_SUCCESS, 13,
+ { 0x100, 0x200, 0x300, 0x400, 0x500, 0x600, 0, 0 } },
+ { "1:2:3:4:5:6::8", STATUS_SUCCESS, 14,
+ { 0x100, 0x200, 0x300, 0x400, 0x500, 0x600, 0, 0x800 } },
+ { "2001:0000:1234:0000:0000:C1C0:ABCD:0876", STATUS_SUCCESS, 39,
+ { 0x120, 0, 0x3412, 0, 0, 0xc0c1, 0xcdab, 0x7608 } },
+ { "2001:0000:4136:e378:8000:63bf:3fff:fdd2", STATUS_SUCCESS, 39,
+ { 0x120, 0, 0x3641, 0x78e3, 0x80, 0xbf63, 0xff3f, 0xd2fd } },
+ { "2001:0db8:0:0:0:0:1428:57ab", STATUS_SUCCESS, 27,
+ { 0x120, 0xb80d, 0, 0, 0, 0, 0x2814, 0xab57 } },
+ { "2001:0db8:1234:ffff:ffff:ffff:ffff:ffff", STATUS_SUCCESS, 39,
+ { 0x120, 0xb80d, 0x3412, 0xffff, 0xffff, 0xffff, 0xffff, 0xffff } },
+ { "2001::CE49:7601:2CAD:DFFF:7C94:FFFE", STATUS_SUCCESS, 35,
+ { 0x120, 0, 0x49ce, 0x176, 0xad2c, 0xffdf, 0x947c, 0xfeff } },
+ { "2001:db8:85a3::8a2e:370:7334", STATUS_SUCCESS, 28,
+ { 0x120, 0xb80d, 0xa385, 0, 0, 0x2e8a, 0x7003, 0x3473 } },
+ { "3ffe:0b00:0000:0000:0001:0000:0000:000a", STATUS_SUCCESS, 39,
+ { 0xfe3f, 0xb, 0, 0, 0x100, 0, 0, 0xa00 } },
+ { "::", STATUS_SUCCESS, 2,
+ { 0, 0, 0, 0, 0, 0, 0, 0 } },
+ { "::%16", STATUS_SUCCESS, 2,
+ { 0, 0, 0, 0, 0, 0, 0, 0 } },
+ { "::/16", STATUS_SUCCESS, 2,
+ { 0, 0, 0, 0, 0, 0, 0, 0 }, ex_fail_6 },
+ { "::0", STATUS_SUCCESS, 3,
+ { 0, 0, 0, 0, 0, 0, 0, 0 } },
+ { "::0:0", STATUS_SUCCESS, 5,
+ { 0, 0, 0, 0, 0, 0, 0, 0 } },
+ { "::0:0:0", STATUS_SUCCESS, 7,
+ { 0, 0, 0, 0, 0, 0, 0, 0 } },
+ { "::0:0:0:0", STATUS_SUCCESS, 9,
+ { 0, 0, 0, 0, 0, 0, 0, 0 } },
+ { "::0:0:0:0:0", STATUS_SUCCESS, 11,
+ { 0, 0, 0, 0, 0, 0, 0, 0 } },
+ { "::0:0:0:0:0:0", STATUS_SUCCESS, 13,
+ { 0, 0, 0, 0, 0, 0, 0, 0 } },
+ /* this one and the next one are incorrectly parsed by windows,
+ it adds one zero too many in front, cutting off the last digit. */
+ { "::0:0:0:0:0:0:0", STATUS_SUCCESS, 13,
+ { 0, 0, 0, 0, 0, 0, 0, 0 }, ex_fail_6 },
+ { "::0:a:b:c:d:e:f", STATUS_SUCCESS, 13,
+ { 0, 0, 0, 0xa00, 0xb00, 0xc00, 0xd00, 0xe00 }, ex_fail_6 },
+ { "::123.123.123.123", STATUS_SUCCESS, 17,
+ { 0, 0, 0, 0, 0, 0, 0x7b7b, 0x7b7b } },
+ { "ffff:ffff:ffff:ffff:ffff:ffff:ffff:ffff", STATUS_SUCCESS, 39,
+ { 0xffff, 0xffff, 0xffff, 0xffff, 0xffff, 0xffff, 0xffff, 0xffff } },
+
+ { "':10.0.0.1", STATUS_INVALID_PARAMETER, 0,
+ { -1 } },
+ { "-1", STATUS_INVALID_PARAMETER, 0,
+ { -1 } },
+ { "02001:0000:1234:0000:0000:C1C0:ABCD:0876", STATUS_INVALID_PARAMETER, -1,
+ { -1 } },
+ { "2001:00000:1234:0000:0000:C1C0:ABCD:0876", STATUS_INVALID_PARAMETER, -1,
+ { 0x120, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "2001:0000:01234:0000:0000:C1C0:ABCD:0876", STATUS_INVALID_PARAMETER, -1,
+ { 0x120, 0, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "1.2.3.4", STATUS_INVALID_PARAMETER, 7,
+ { 0x201, 0xab03, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "1.2.3.4:1111::5555", STATUS_INVALID_PARAMETER, 7,
+ { 0x201, 0xab03, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "1.2.3.4::5555", STATUS_INVALID_PARAMETER, 7,
+ { 0x201, 0xab03, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "11112222:3333:4444:5555:6666:1.2.3.4", STATUS_INVALID_PARAMETER, -1,
+ { -1 } },
+ { "11112222:3333:4444:5555:6666:7777:8888", STATUS_INVALID_PARAMETER, -1,
+ { -1 } },
+ { "1111", STATUS_INVALID_PARAMETER, 4,
+ { -1 } },
+ { "1111:22223333:4444:5555:6666:1.2.3.4", STATUS_INVALID_PARAMETER, -1,
+ { 0x1111, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "1111:22223333:4444:5555:6666:7777:8888", STATUS_INVALID_PARAMETER, -1,
+ { 0x1111, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "1111:2222:", STATUS_INVALID_PARAMETER, 10,
+ { 0x1111, 0x2222, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "1111:2222:1.2.3.4", STATUS_INVALID_PARAMETER, 17,
+ { 0x1111, 0x2222, 0x201, 0xab03, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "1111:2222:3333", STATUS_INVALID_PARAMETER, 14,
+ { 0x1111, 0x2222, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "1111:2222:3333:4444:5555:6666:7777:1.2.3.4", STATUS_SUCCESS, 36,
+ { 0x1111, 0x2222, 0x3333, 0x4444, 0x5555, 0x6666, 0x7777, 0x100 }, ex_fail_6 },
+ { "1111:2222:3333:4444:5555:6666:7777:8888:", STATUS_SUCCESS, 39,
+ { 0x1111, 0x2222, 0x3333, 0x4444, 0x5555, 0x6666, 0x7777, 0x8888 }, ex_fail_6 },
+ { "1111:2222:3333:4444:5555:6666:7777:8888:1.2.3.4",STATUS_SUCCESS, 39,
+ { 0x1111, 0x2222, 0x3333, 0x4444, 0x5555, 0x6666, 0x7777, 0x8888 }, ex_fail_6 },
+ { "1111:2222:3333:4444:5555:6666:7777:8888:9999", STATUS_SUCCESS, 39,
+ { 0x1111, 0x2222, 0x3333, 0x4444, 0x5555, 0x6666, 0x7777, 0x8888 }, ex_fail_6 },
+ { "1111:2222:::", STATUS_SUCCESS, 11,
+ { 0x1111, 0x2222, 0, 0, 0, 0, 0, 0 }, ex_fail_6 },
+ { "1111::5555:", STATUS_INVALID_PARAMETER, 11,
+ { 0x1111, 0x5555, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "1111::3333:4444:5555:6666:7777::", STATUS_SUCCESS, 30,
+ { 0x1111, 0, 0, 0x3333, 0x4444, 0x5555, 0x6666, 0x7777 }, ex_fail_6 },
+ { "1111:2222:::4444:5555:6666:1.2.3.4", STATUS_SUCCESS, 11,
+ { 0x1111, 0x2222, 0, 0, 0, 0, 0, 0 }, ex_fail_6 },
+ { "1111::3333::5555:6666:1.2.3.4", STATUS_SUCCESS, 10,
+ { 0x1111, 0, 0, 0, 0, 0, 0, 0x3333 }, ex_fail_6 },
+ { "12345::6:7:8", STATUS_INVALID_PARAMETER, -1,
+ { -1 } },
+ { "1::1.2.256.4", STATUS_INVALID_PARAMETER, -1,
+ { 0x100, 0x201, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "1::1.2.3.256", STATUS_INVALID_PARAMETER, 12,
+ { 0x100, 0x201, 0xab03, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "1::1.2.3.300", STATUS_INVALID_PARAMETER, 12,
+ { 0x100, 0x201, 0xab03, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "1::1.2::1", STATUS_INVALID_PARAMETER, 6,
+ { 0x100, 0xab01, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "1::1.2.3.4::1", STATUS_SUCCESS, 10,
+ { 0x100, 0, 0, 0, 0, 0, 0x201, 0x403 }, ex_fail_6 },
+ { "1::1.", STATUS_INVALID_PARAMETER, 5,
+ { 0x100, 0xab01, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "1::1.2", STATUS_INVALID_PARAMETER, 6,
+ { 0x100, 0xab01, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "1::1.2.", STATUS_INVALID_PARAMETER, 7,
+ { 0x100, 0x201, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "1::1.2.3", STATUS_INVALID_PARAMETER, 8,
+ { 0x100, 0x201, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "1::1.2.3.", STATUS_INVALID_PARAMETER, 9,
+ { 0x100, 0x201, 0xab03, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "1::1.2.3.4", STATUS_SUCCESS, 10,
+ { 0x100, 0, 0, 0, 0, 0, 0x201, 0x403 } },
+ { "1::1.2.3.900", STATUS_INVALID_PARAMETER, 12,
+ { 0x100, 0x201, 0xab03, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "1::1.2.300.4", STATUS_INVALID_PARAMETER, -1,
+ { 0x100, 0x201, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "1::1.256.3.4", STATUS_INVALID_PARAMETER, -1,
+ { 0x100, 0xab01, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "1::256.2.3.4", STATUS_INVALID_PARAMETER, -1,
+ { 0x100, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "1::2::3", STATUS_SUCCESS, 4,
+ { 0x100, 0, 0, 0, 0, 0, 0, 0x200 }, ex_fail_6 },
+ { "2001:0000:1234: 0000:0000:C1C0:ABCD:0876", STATUS_INVALID_PARAMETER, 15,
+ { 0x120, 0, 0x3412, 0xabab, 0xabab, 0xabab, 0xabab, 0xabab } },
+ { "2001:0000:1234:0000:0000:C1C0:ABCD:0876 0", STATUS_SUCCESS, 39,
+ { 0x120, 0, 0x3412, 0, 0, 0xc0c1, 0xcdab, 0x7608 }, ex_fail_6 },
+ { "2001:1:1:1:1:1:255Z255X255Y255", STATUS_INVALID_PARAMETER, 18,
+ { 0x120, 0x100, 0x100, 0x100, 0x100, 0x100, 0xabab, 0xabab } },
+ { "2001::FFD3::57ab", STATUS_SUCCESS, 10,
+ { 0x120, 0, 0, 0, 0, 0, 0, 0xd3ff }, ex_fail_6 },
+ { ":", STATUS_INVALID_PARAMETER, 0,
+ { -1 } },
+ { ":1111:2222:3333:4444:5555:6666:1.2.3.4", STATUS_INVALID_PARAMETER, 0,
+ { -1 } },
+ { ":1111:2222:3333:4444:5555:6666:7777:8888", STATUS_INVALID_PARAMETER, 0,
+ { -1 } },
+ { ":1111::", STATUS_INVALID_PARAMETER, 0,
+ { -1 } },
+ { "::-1", STATUS_SUCCESS, 2,
+ { 0, 0, 0, 0, 0, 0, 0, 0 }, ex_fail_6 },
+ { "::.", STATUS_SUCCESS, 2,
+ { 0, 0, 0, 0, 0, 0, 0, 0 }, ex_fail_6 },
+ { "::..", STATUS_SUCCESS, 2,
+ { 0, 0, 0, 0, 0, 0, 0, 0 }, ex_fail_6 },
+ { "::...", STATUS_SUCCESS, 2,
+ { 0, 0, 0, 0, 0, 0, 0, 0 }, ex_fail_6 },
+ { "XXXX:XXXX:XXXX:XXXX:XXXX:XXXX:1.2.3.4", STATUS_INVALID_PARAMETER, 0,
+ { -1 } },
+ { "[::]", STATUS_INVALID_PARAMETER, 0,
+ { -1 }, ex_skip_6 },
+};
+const unsigned int ipv6_testcount = sizeof(ipv6_tests) / sizeof(ipv6_tests[0]);
+
+
+static void init_ip6(IN6_ADDR* addr, const int src[8])
+{
+ unsigned int j;
+ if (!src || src[0] == -1)
+ {
+ for (j = 0; j < 8; ++j)
+ addr->s6_words[j] = 0xabab;
+ }
+ else
+ {
+ for (j = 0; j < 8; ++j)
+ addr->s6_words[j] = src[j];
+ }
+}
+
+static void compare_RtlIpv6StringToAddressW(PCSTR name_a, int terminator_offset_a,
+ const struct in6_addr *addr_a, NTSTATUS res_a)
+{
+ WCHAR name[512];
+ NTSTATUS res;
+ IN6_ADDR ip;
+ PCWSTR terminator;
+
+ if (!pRtlIpv6StringToAddressW)
+ return;
+
+ pRtlMultiByteToUnicodeN(name, sizeof(name), NULL, name_a, strlen(name_a) + 1);
+
+ init_ip6(&ip, NULL);
+ terminator = (void *)0xdeadbeef;
+ res = pRtlIpv6StringToAddressW(name, &terminator, &ip);
+ ok(res == res_a, "[W:%s] res = 0x%08x, expected 0x%08x\n", name_a, res, res_a);
+
+ if (terminator_offset_a < 0)
+ {
+ ok(terminator == (void *)0xdeadbeef,
+ "[W:%s] terminator = %p, expected it not to change\n",
+ name_a, terminator);
+ }
+ else
+ {
+ ok(terminator == name + terminator_offset_a,
+ "[W:%s] terminator = %p, expected %p\n",
+ name_a, terminator, name + terminator_offset_a);
+ }
+
+ ok(!memcmp(&ip, addr_a, sizeof(ip)),
+ "[W:%s] ip = %x:%x:%x:%x:%x:%x:%x:%x, expected %x:%x:%x:%x:%x:%x:%x:%x\n",
+ name_a,
+ ip.s6_words[0], ip.s6_words[1], ip.s6_words[2], ip.s6_words[3],
+ ip.s6_words[4], ip.s6_words[5], ip.s6_words[6], ip.s6_words[7],
+ addr_a->s6_words[0], addr_a->s6_words[1], addr_a->s6_words[2], addr_a->s6_words[3],
+ addr_a->s6_words[4], addr_a->s6_words[5], addr_a->s6_words[6], addr_a->s6_words[7]);
+}
+
+static void test_RtlIpv6StringToAddress(void)
+{
+ NTSTATUS res;
+ IN6_ADDR ip, expected_ip;
+ PCSTR terminator;
+ unsigned int i;
+
+ if (!pRtlIpv6StringToAddressW)
+ {
+ skip("RtlIpv6StringToAddressW not available\n");
+ /* we can continue, just not test W */
+ }
+
+ if (!pRtlIpv6StringToAddressA)
+ {
+ skip("RtlIpv6StringToAddressA not available\n");
+ return; /* all tests are centered around A, we cannot continue */
+ }
+
+ res = pRtlIpv6StringToAddressA("::", &terminator, &ip);
+ ok(res == STATUS_SUCCESS, "[validate] res = 0x%08x, expected STATUS_SUCCESS\n", res);
+ if (0)
+ {
+ /* any of these crash */
+ res = pRtlIpv6StringToAddressA(NULL, &terminator, &ip);
+ ok(res == STATUS_INVALID_PARAMETER, "[null string] res = 0x%08x, expected STATUS_INVALID_PARAMETER\n", res);
+ res = pRtlIpv6StringToAddressA("::", NULL, &ip);
+ ok(res == STATUS_INVALID_PARAMETER, "[null terminator] res = 0x%08x, expected STATUS_INVALID_PARAMETER\n", res);
+ res = pRtlIpv6StringToAddressA("::", &terminator, NULL);
+ ok(res == STATUS_INVALID_PARAMETER, "[null result] res = 0x%08x, expected STATUS_INVALID_PARAMETER\n", res);
+ }
+
+ /* sanity check */
+ ok(sizeof(ip) == sizeof(USHORT)* 8, "sizeof(ip)\n");
+
+ for (i = 0; i < ipv6_testcount; i++)
+ {
+ init_ip6(&ip, NULL);
+ terminator = (void *)0xdeadbeef;
+ res = pRtlIpv6StringToAddressA(ipv6_tests[i].address, &terminator, &ip);
+ compare_RtlIpv6StringToAddressW(ipv6_tests[i].address, (terminator != (void *)0xdeadbeef) ?
+ (terminator - ipv6_tests[i].address) : -1, &ip, res);
+
+ if (ipv6_tests[i].flags & win_broken_6)
+ {
+ ok(res == ipv6_tests[i].res || broken(res == STATUS_INVALID_PARAMETER),
+ "[%s] res = 0x%08x, expected 0x%08x\n",
+ ipv6_tests[i].address, res, ipv6_tests[i].res);
+
+ if (res == STATUS_INVALID_PARAMETER)
+ continue;
+ }
+ else
+ {
+ ok(res == ipv6_tests[i].res,
+ "[%s] res = 0x%08x, expected 0x%08x\n",
+ ipv6_tests[i].address, res, ipv6_tests[i].res);
+ }
+
+ if (ipv6_tests[i].terminator_offset < 0)
+ {
+ ok(terminator == (void *)0xdeadbeef,
+ "[%s] terminator = %p, expected it not to change\n",
+ ipv6_tests[i].address, terminator);
+ }
+ else if (ipv6_tests[i].flags & win_broken_6)
+ {
+ PCSTR expected = ipv6_tests[i].address + ipv6_tests[i].terminator_offset;
+ ok(terminator == expected || broken(terminator == expected + 2),
+ "[%s] terminator = %p, expected %p\n",
+ ipv6_tests[i].address, terminator, expected);
+ }
+ else
+ {
+ ok(terminator == ipv6_tests[i].address + ipv6_tests[i].terminator_offset,
+ "[%s] terminator = %p, expected %p\n",
+ ipv6_tests[i].address, terminator, ipv6_tests[i].address + ipv6_tests[i].terminator_offset);
+ }
+
+ init_ip6(&expected_ip, ipv6_tests[i].ip);
+ ok(!memcmp(&ip, &expected_ip, sizeof(ip)),
+ "[%s] ip = %x:%x:%x:%x:%x:%x:%x:%x, expected %x:%x:%x:%x:%x:%x:%x:%x\n",
+ ipv6_tests[i].address,
+ ip.s6_words[0], ip.s6_words[1], ip.s6_words[2], ip.s6_words[3],
+ ip.s6_words[4], ip.s6_words[5], ip.s6_words[6], ip.s6_words[7],
+ expected_ip.s6_words[0], expected_ip.s6_words[1], expected_ip.s6_words[2], expected_ip.s6_words[3],
+ expected_ip.s6_words[4], expected_ip.s6_words[5], expected_ip.s6_words[6], expected_ip.s6_words[7]);
+ }
+}
+
static void test_LdrAddRefDll(void)
{
HMODULE mod, mod2;
@@ -2155,6 +2584,7 @@ START_TEST(rtl)
test_RtlIpv4AddressToString();
test_RtlIpv4AddressToStringEx();
test_RtlIpv4StringToAddress();
+ test_RtlIpv6StringToAddress();
test_LdrAddRefDll();
test_LdrLockLoaderLock();
test_RtlCompressBuffer();
--
2.6.4

View File

@ -1,4 +1,4 @@
From b7b1ff9a632ed7c9ea38bce977a7b754526adb1c Mon Sep 17 00:00:00 2001
From 20ab5002c02f1c11a9e4f8c03555f7c40939c3bf Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
Date: Sun, 17 Jan 2016 00:50:50 +0100
Subject: [PATCH] ntdll/tests: Add basic tests for RtlQueryPackageIdentity.
@ -20,12 +20,12 @@ index a1b8588..c5c5191 100644
C_SRCS = \
atom.c \
diff --git a/dlls/ntdll/tests/rtl.c b/dlls/ntdll/tests/rtl.c
index 881bc1a..5862140 100644
index ec12ea2..143e603 100644
--- a/dlls/ntdll/tests/rtl.c
+++ b/dlls/ntdll/tests/rtl.c
@@ -25,6 +25,9 @@
@@ -26,6 +26,9 @@
#include "ntdll_test.h"
#include "in6addr.h"
#include "inaddr.h"
+#include "initguid.h"
+#define COBJMACROS
@ -33,7 +33,7 @@ index 881bc1a..5862140 100644
#ifndef __WINE_WINTERNL_H
@@ -99,6 +102,7 @@ static BOOL (WINAPI *pRtlIsCriticalSectionLocked)(CRITICAL_SECTION *);
@@ -103,6 +106,7 @@ static BOOL (WINAPI *pRtlIsCriticalSectionLocked)(CRITICAL_SECTION *);
static BOOL (WINAPI *pRtlIsCriticalSectionLockedByThread)(CRITICAL_SECTION *);
static NTSTATUS (WINAPI *pRtlInitializeCriticalSectionEx)(CRITICAL_SECTION *, ULONG, ULONG);
static NTSTATUS (WINAPI *pLdrEnumerateLoadedModules)(void *, void *, void *);
@ -41,7 +41,7 @@ index 881bc1a..5862140 100644
static NTSTATUS (WINAPI *pRtlMakeSelfRelativeSD)(PSECURITY_DESCRIPTOR,PSECURITY_DESCRIPTOR,LPDWORD);
static NTSTATUS (WINAPI *pRtlAbsoluteToSelfRelativeSD)(PSECURITY_DESCRIPTOR,PSECURITY_DESCRIPTOR,PULONG);
static NTSTATUS (WINAPI *pLdrRegisterDllNotification)(ULONG, PLDR_DLL_NOTIFICATION_FUNCTION, void *, void **);
@@ -162,6 +166,7 @@ static void InitFunctionPtrs(void)
@@ -169,6 +173,7 @@ static void InitFunctionPtrs(void)
pRtlIsCriticalSectionLockedByThread = (void *)GetProcAddress(hntdll, "RtlIsCriticalSectionLockedByThread");
pRtlInitializeCriticalSectionEx = (void *)GetProcAddress(hntdll, "RtlInitializeCriticalSectionEx");
pLdrEnumerateLoadedModules = (void *)GetProcAddress(hntdll, "LdrEnumerateLoadedModules");
@ -49,7 +49,7 @@ index 881bc1a..5862140 100644
pRtlMakeSelfRelativeSD = (void *)GetProcAddress(hntdll, "RtlMakeSelfRelativeSD");
pRtlAbsoluteToSelfRelativeSD = (void *)GetProcAddress(hntdll, "RtlAbsoluteToSelfRelativeSD");
pLdrRegisterDllNotification = (void *)GetProcAddress(hntdll, "LdrRegisterDllNotification");
@@ -2517,6 +2522,76 @@ static void test_LdrRegisterDllNotification(void)
@@ -2946,6 +2951,76 @@ static void test_LdrRegisterDllNotification(void)
pLdrUnregisterDllNotification(cookie);
}
@ -126,7 +126,7 @@ index 881bc1a..5862140 100644
START_TEST(rtl)
{
InitFunctionPtrs();
@@ -2550,6 +2625,7 @@ START_TEST(rtl)
@@ -2980,6 +3055,7 @@ START_TEST(rtl)
test_RtlInitializeCriticalSectionEx();
test_RtlLeaveCriticalSection();
test_LdrEnumerateLoadedModules();

View File

@ -1,26 +0,0 @@
From 9d314bb031e123beffa43f5b5f47ce6deda25cf4 Mon Sep 17 00:00:00 2001
From: Alexander Morozov <amorozov@etersoft.ru>
Date: Fri, 30 Jan 2015 00:33:55 +0100
Subject: ntoskrnl.exe: Improve KeInitializeTimerEx stub.
---
dlls/ntoskrnl.exe/ntoskrnl.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/dlls/ntoskrnl.exe/ntoskrnl.c b/dlls/ntoskrnl.exe/ntoskrnl.c
index 36331a1..c3a7e2a 100644
--- a/dlls/ntoskrnl.exe/ntoskrnl.c
+++ b/dlls/ntoskrnl.exe/ntoskrnl.c
@@ -1387,6 +1387,9 @@ void WINAPI KeInitializeSpinLock( PKSPIN_LOCK SpinLock )
void WINAPI KeInitializeTimerEx( PKTIMER Timer, TIMER_TYPE Type )
{
FIXME( "stub: %p %d\n", Timer, Type );
+
+ RtlZeroMemory(Timer, sizeof(KTIMER));
+ Timer->Header.Type = Type ? 9 : 8;
}
--
2.2.2

View File

@ -1,7 +1,7 @@
From 6b77a809cc81c22fced7c970c1c43a5f5426184b Mon Sep 17 00:00:00 2001
From 44e38cce5a02a0a5db60316270f33974f8d89400 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
Date: Tue, 6 Jun 2017 21:08:51 +0200
Subject: ntoskrnl.exe: Implement NtBuildNumber.
Subject: [PATCH] ntoskrnl.exe: Implement NtBuildNumber.
---
dlls/ntoskrnl.exe/ntoskrnl.c | 11 +++++++++--
@ -10,7 +10,7 @@ Subject: ntoskrnl.exe: Implement NtBuildNumber.
3 files changed, 40 insertions(+), 3 deletions(-)
diff --git a/dlls/ntoskrnl.exe/ntoskrnl.c b/dlls/ntoskrnl.exe/ntoskrnl.c
index ae699dc..21507dc 100644
index 958bcdf..343033d 100644
--- a/dlls/ntoskrnl.exe/ntoskrnl.c
+++ b/dlls/ntoskrnl.exe/ntoskrnl.c
@@ -52,6 +52,7 @@ WINE_DECLARE_DEBUG_CHANNEL(plugplay);
@ -53,7 +53,7 @@ index ae699dc..21507dc 100644
case DLL_PROCESS_DETACH:
if (reserved) break;
diff --git a/dlls/ntoskrnl.exe/ntoskrnl.exe.spec b/dlls/ntoskrnl.exe/ntoskrnl.exe.spec
index a572399..0fc9256 100644
index 5df4ae3..00d09dd 100644
--- a/dlls/ntoskrnl.exe/ntoskrnl.exe.spec
+++ b/dlls/ntoskrnl.exe/ntoskrnl.exe.spec
@@ -743,7 +743,7 @@
@ -66,7 +66,7 @@ index a572399..0fc9256 100644
@ stdcall NtConnectPort(ptr ptr ptr ptr ptr ptr ptr ptr)
@ stdcall NtCreateEvent(ptr long ptr long long)
diff --git a/dlls/ntoskrnl.exe/tests/driver.c b/dlls/ntoskrnl.exe/tests/driver.c
index 06b365f..71d2491 100644
index cde78e5..f4bdb0b 100644
--- a/dlls/ntoskrnl.exe/tests/driver.c
+++ b/dlls/ntoskrnl.exe/tests/driver.c
@@ -143,6 +143,22 @@ static void winetest_end_todo(void)
@ -92,8 +92,8 @@ index 06b365f..71d2491 100644
static void test_currentprocess(void)
{
PEPROCESS current;
@@ -172,6 +188,19 @@ todo_wine
IoFreeMdl(mdl);
@@ -187,6 +203,19 @@ static void test_init_funcs(void)
ok(timer2.Header.SignalState == 0, "got: %u\n", timer2.Header.SignalState);
}
+static void test_version(void)
@ -112,14 +112,14 @@ index 06b365f..71d2491 100644
static NTSTATUS main_test(IRP *irp, IO_STACK_LOCATION *stack, ULONG_PTR *info)
{
ULONG length = stack->Parameters.DeviceIoControl.OutputBufferLength;
@@ -197,6 +226,7 @@ static NTSTATUS main_test(IRP *irp, IO_STACK_LOCATION *stack, ULONG_PTR *info)
@@ -213,6 +242,7 @@ static NTSTATUS main_test(IRP *irp, IO_STACK_LOCATION *stack, ULONG_PTR *info)
test_currentprocess();
test_mdl_map();
test_init_funcs();
+ test_version();
/* print process report */
if (test_input->winetest_debug)
--
2.7.4
1.9.1

View File

@ -1,7 +1,7 @@
From e4a32c13ea03d6bfc08f78d93b517d612005a395 Mon Sep 17 00:00:00 2001
From 95d5fbf3bf582fb219d2de40c829a5c18fb27726 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
Date: Tue, 6 Jun 2017 23:42:56 +0200
Subject: ntoskrnl.exe: Implement ExInitializeNPagedLookasideList.
Subject: [PATCH] ntoskrnl.exe: Implement ExInitializeNPagedLookasideList.
---
dlls/ntoskrnl.exe/ntoskrnl.c | 19 +++++++++-
@ -11,7 +11,7 @@ Subject: ntoskrnl.exe: Implement ExInitializeNPagedLookasideList.
4 files changed, 127 insertions(+), 7 deletions(-)
diff --git a/dlls/ntoskrnl.exe/ntoskrnl.c b/dlls/ntoskrnl.exe/ntoskrnl.c
index 21507dc..a865cd8 100644
index 343033d..9fd7231 100644
--- a/dlls/ntoskrnl.exe/ntoskrnl.c
+++ b/dlls/ntoskrnl.exe/ntoskrnl.c
@@ -1814,7 +1814,24 @@ void WINAPI ExInitializeNPagedLookasideList(PNPAGED_LOOKASIDE_LIST Lookaside,
@ -41,7 +41,7 @@ index 21507dc..a865cd8 100644
/***********************************************************************
diff --git a/dlls/ntoskrnl.exe/tests/driver.c b/dlls/ntoskrnl.exe/tests/driver.c
index 5fe997a..1ef27fb 100644
index f4bdb0b..f56e2dd 100644
--- a/dlls/ntoskrnl.exe/tests/driver.c
+++ b/dlls/ntoskrnl.exe/tests/driver.c
@@ -22,6 +22,9 @@
@ -54,7 +54,7 @@ index 5fe997a..1ef27fb 100644
#include "ntstatus.h"
#define WIN32_NO_STATUS
#include "windef.h"
@@ -201,6 +204,33 @@ static void test_version(void)
@@ -216,6 +219,33 @@ static void test_version(void)
return;
}
@ -88,15 +88,15 @@ index 5fe997a..1ef27fb 100644
static NTSTATUS main_test(IRP *irp, IO_STACK_LOCATION *stack, ULONG_PTR *info)
{
ULONG length = stack->Parameters.DeviceIoControl.OutputBufferLength;
@@ -227,6 +257,7 @@ static NTSTATUS main_test(IRP *irp, IO_STACK_LOCATION *stack, ULONG_PTR *info)
test_currentprocess();
@@ -243,6 +273,7 @@ static NTSTATUS main_test(IRP *irp, IO_STACK_LOCATION *stack, ULONG_PTR *info)
test_mdl_map();
test_init_funcs();
test_version();
+ test_lookaside_list();
/* print process report */
if (test_input->winetest_debug)
@@ -261,7 +292,7 @@ static NTSTATUS test_basic_ioctl(IRP *irp, IO_STACK_LOCATION *stack, ULONG_PTR *
@@ -277,7 +308,7 @@ static NTSTATUS test_basic_ioctl(IRP *irp, IO_STACK_LOCATION *stack, ULONG_PTR *
static NTSTATUS WINAPI driver_Create(DEVICE_OBJECT *device, IRP *irp)
{
@ -105,7 +105,7 @@ index 5fe997a..1ef27fb 100644
IoCompleteRequest(irp, IO_NO_INCREMENT);
return STATUS_SUCCESS;
}
@@ -283,14 +314,14 @@ static NTSTATUS WINAPI driver_IoControl(DEVICE_OBJECT *device, IRP *irp)
@@ -299,14 +330,14 @@ static NTSTATUS WINAPI driver_IoControl(DEVICE_OBJECT *device, IRP *irp)
break;
}
@ -123,7 +123,7 @@ index 5fe997a..1ef27fb 100644
return STATUS_SUCCESS;
}
diff --git a/include/ddk/wdm.h b/include/ddk/wdm.h
index d6b808f..b43ec62 100644
index 5abe18b..175c07d 100644
--- a/include/ddk/wdm.h
+++ b/include/ddk/wdm.h
@@ -144,20 +144,18 @@ typedef enum _KWAIT_REASON
@ -244,7 +244,7 @@ index d6b808f..b43ec62 100644
PSLIST_ENTRY WINAPI ExInterlockedPushEntrySList(PSLIST_HEADER,PSLIST_ENTRY,PKSPIN_LOCK);
void WINAPI ExReleaseFastMutexUnsafe(PFAST_MUTEX);
diff --git a/include/winnt.h b/include/winnt.h
index b309929..d7694ab 100644
index 45c3222..719cf84 100644
--- a/include/winnt.h
+++ b/include/winnt.h
@@ -755,6 +755,8 @@ typedef struct _MEMORY_BASIC_INFORMATION
@ -257,5 +257,5 @@ index b309929..d7694ab 100644
#ifdef __GNUC__
# define CONTAINING_RECORD(address, type, field) ({ \
--
2.7.4
1.9.1

View File

@ -1,17 +1,17 @@
From a7d49a0453ce0947b66f881e7c0e2966bf5549bc Mon Sep 17 00:00:00 2001
From c0c14c70039d65f61a73d37950f72d8c66bbc2f0 Mon Sep 17 00:00:00 2001
From: Dmitry Timoshkov <dmitry@baikal.ru>
Date: Tue, 26 Apr 2016 13:15:41 +0800
Subject: oleaut32: Add support for loading and saving EMF to IPicture
Subject: [PATCH] oleaut32: Add support for loading and saving EMF to IPicture
interface.
For bug #40523.
---
dlls/oleaut32/olepicture.c | 52 +++++++++++++++++++++++++++++++++++++---
dlls/oleaut32/olepicture.c | 51 ++++++++++++++++++++++++++++++++++++----
dlls/oleaut32/tests/olepicture.c | 5 +---
2 files changed, 50 insertions(+), 7 deletions(-)
2 files changed, 47 insertions(+), 9 deletions(-)
diff --git a/dlls/oleaut32/olepicture.c b/dlls/oleaut32/olepicture.c
index 96c109a..b82031d 100644
index a2a54bd..3fd7638 100644
--- a/dlls/oleaut32/olepicture.c
+++ b/dlls/oleaut32/olepicture.c
@@ -266,6 +266,18 @@ static void OLEPictureImpl_SetIcon(OLEPictureImpl * This)
@ -33,19 +33,17 @@ index 96c109a..b82031d 100644
/************************************************************************
* OLEPictureImpl_Construct
*
@@ -346,7 +358,11 @@ static OLEPictureImpl* OLEPictureImpl_Construct(LPPICTDESC pictDesc, BOOL fOwn)
case PICTYPE_ICON:
OLEPictureImpl_SetIcon(newObject);
@@ -349,8 +361,7 @@ static HRESULT OLEPictureImpl_Construct(LPPICTDESC pictDesc, BOOL fOwn, OLEPictu
break;
+
case PICTYPE_ENHMETAFILE:
- FIXME("EMF is not supported\n");
- newObject->himetricWidth = newObject->himetricHeight = 0;
+ OLEPictureImpl_SetEMF(newObject);
+ break;
+
break;
default:
FIXME("Unsupported type %d\n", pictDesc->picType);
newObject->himetricWidth = newObject->himetricHeight = 0;
@@ -1761,6 +1777,17 @@ static BOOL serializeIcon(HICON hIcon, void ** ppBuffer, unsigned int * pLength)
@@ -1758,6 +1769,17 @@ static BOOL serializeIcon(HICON hIcon, void ** ppBuffer, unsigned int * pLength)
return success;
}
@ -63,7 +61,7 @@ index 96c109a..b82031d 100644
static HRESULT WINAPI OLEPictureImpl_Save(
IPersistStream* iface,IStream*pStm,BOOL fClearDirty)
{
@@ -1836,12 +1863,31 @@ static HRESULT WINAPI OLEPictureImpl_Save(
@@ -1833,12 +1855,31 @@ static HRESULT WINAPI OLEPictureImpl_Save(
IStream_Write(pStm, This->data, This->datalen, &dummy);
hResult = S_OK;
break;
@ -99,10 +97,10 @@ index 96c109a..b82031d 100644
FIXME("(%p,%p,%d), [unknown type] not implemented!\n",This,pStm,fClearDirty);
break;
diff --git a/dlls/oleaut32/tests/olepicture.c b/dlls/oleaut32/tests/olepicture.c
index de45603..7503265 100644
index 2498910..dcbd088 100644
--- a/dlls/oleaut32/tests/olepicture.c
+++ b/dlls/oleaut32/tests/olepicture.c
@@ -1372,21 +1372,18 @@ todo_wine
@@ -1471,21 +1471,18 @@ todo_wine
ok(hr == S_OK, "QueryInterface error %#x\n", hr);
hr = IPersistStream_Save(src_stream, dst_stream, TRUE);
@ -126,5 +124,5 @@ index de45603..7503265 100644
GlobalFree(hmem);
--
2.8.0
1.9.1

View File

@ -52,7 +52,7 @@ usage()
# Get the upstream commit sha
upstream_commit()
{
echo "80205232d3ece73d4cc6c7589cea893583aae0b1"
echo "8ef224fa43869a8c977921d6bec08863382d6e11"
}
# Show version information
@ -172,7 +172,6 @@ patch_enable_all ()
enable_kernel32_GetShortPathName="$1"
enable_kernel32_Job_Tests="$1"
enable_kernel32_K32GetPerformanceInfo="$1"
enable_kernel32_Misalign_Workaround="$1"
enable_kernel32_MoveFile="$1"
enable_kernel32_NeedCurrentDirectoryForExePath="$1"
enable_kernel32_PE_Loader_Fixes="$1"
@ -195,7 +194,6 @@ patch_enable_all ()
enable_msi_MsiGetDatabaseState="$1"
enable_msi_msi_vcl_get_cost="$1"
enable_msidb_Implementation="$1"
enable_msvcr120__SetWinRTOutOfMemoryExceptionCallback="$1"
enable_msvcrt_Math_Precision="$1"
enable_msvfw32_ICGetDisplayFormat="$1"
enable_ntdll_APC_Performance="$1"
@ -692,9 +690,6 @@ patch_enable ()
kernel32-K32GetPerformanceInfo)
enable_kernel32_K32GetPerformanceInfo="$2"
;;
kernel32-Misalign_Workaround)
enable_kernel32_Misalign_Workaround="$2"
;;
kernel32-MoveFile)
enable_kernel32_MoveFile="$2"
;;
@ -761,9 +756,6 @@ patch_enable ()
msidb-Implementation)
enable_msidb_Implementation="$2"
;;
msvcr120-_SetWinRTOutOfMemoryExceptionCallback)
enable_msvcr120__SetWinRTOutOfMemoryExceptionCallback="$2"
;;
msvcrt-Math_Precision)
enable_msvcrt_Math_Precision="$2"
;;
@ -2200,13 +2192,6 @@ if test "$enable_kernel32_Processor_Group" -eq 1; then
enable_api_ms_win_Stub_DLLs=1
fi
if test "$enable_kernel32_PE_Loader_Fixes" -eq 1; then
if test "$enable_kernel32_Misalign_Workaround" -gt 1; then
abort "Patchset kernel32-Misalign_Workaround disabled, but kernel32-PE_Loader_Fixes depends on that."
fi
enable_kernel32_Misalign_Workaround=1
fi
if test "$enable_kernel32_CopyFileEx" -eq 1; then
if test "$enable_ntdll_FileDispositionInformation" -gt 1; then
abort "Patchset ntdll-FileDispositionInformation disabled, but kernel32-CopyFileEx depends on that."
@ -4181,21 +4166,6 @@ if test "$enable_kernel32_K32GetPerformanceInfo" -eq 1; then
) >> "$patchlist"
fi
# Patchset kernel32-Misalign_Workaround
# |
# | This patchset fixes the following Wine bugs:
# | * [#24374] Fill stack with meaningful values in call_process_entry mis-align workaround
# |
# | Modified files:
# | * dlls/kernel32/process.c
# |
if test "$enable_kernel32_Misalign_Workaround" -eq 1; then
patch_apply kernel32-Misalign_Workaround/0001-kernel32-Fill-stack-with-meaningful-values-in-call_p.patch
(
printf '%s\n' '+ { "Sebastian Lackner", "kernel32: Fill stack with meaningful values in call_process_entry mis-align workaround.", 1 },';
) >> "$patchlist"
fi
# Patchset kernel32-MoveFile
# |
# | This patchset fixes the following Wine bugs:
@ -4245,9 +4215,6 @@ fi
# Patchset kernel32-PE_Loader_Fixes
# |
# | This patchset has the following (direct or indirect) dependencies:
# | * kernel32-Misalign_Workaround
# |
# | This patchset fixes the following Wine bugs:
# | * [#42125] Various PE loader fixes for 8k demos
# |
@ -4594,21 +4561,6 @@ if test "$enable_msidb_Implementation" -eq 1; then
) >> "$patchlist"
fi
# Patchset msvcr120-_SetWinRTOutOfMemoryExceptionCallback
# |
# | This patchset fixes the following Wine bugs:
# | * [#45394] Add stub for _SetWinRTOutOfMemoryExceptionCallback
# |
# | Modified files:
# | * dlls/msvcr120/msvcr120.spec, dlls/msvcr120_app/msvcr120_app.spec, dlls/msvcrt/misc.c
# |
if test "$enable_msvcr120__SetWinRTOutOfMemoryExceptionCallback" -eq 1; then
patch_apply msvcr120-_SetWinRTOutOfMemoryExceptionCallback/0001-msvcr120-Add-stub-for-_SetWinRTOutOfMemoryExceptionC.patch
(
printf '%s\n' '+ { "Michael Müller", "msvcr120: Add stub for _SetWinRTOutOfMemoryExceptionCallback.", 1 },';
) >> "$patchlist"
fi
# Patchset msvcrt-Math_Precision
# |
# | This patchset fixes the following Wine bugs:
@ -5310,12 +5262,10 @@ fi
# | * dlls/ntdll/tests/rtl.c
# |
if test "$enable_ntdll_RtlIpStringToAddress_Tests" -eq 1; then
patch_apply ntdll-RtlIpStringToAddress_Tests/0001-ntdll-tests-Tests-for-RtlIpv6StringToAddress-try-6.patch
patch_apply ntdll-RtlIpStringToAddress_Tests/0002-ntdll-tests-Tests-for-RtlIpv6StringToAddressEx-try-6.patch
patch_apply ntdll-RtlIpStringToAddress_Tests/0003-ntdll-tests-Tests-for-RtlIpv4StringToAddressEx-try-5.patch
patch_apply ntdll-RtlIpStringToAddress_Tests/0004-ntdll-tests-Add-tests-for-RtlIpv6AddressToString-and.patch
(
printf '%s\n' '+ { "Mark Jansen", "ntdll/tests: Tests for RtlIpv6StringToAddress.", 6 },';
printf '%s\n' '+ { "Mark Jansen", "ntdll/tests: Tests for RtlIpv6StringToAddressEx.", 6 },';
printf '%s\n' '+ { "Mark Jansen", "ntdll/tests: Tests for RtlIpv4StringToAddressEx (try 5, resend).", 1 },';
printf '%s\n' '+ { "Mark Jansen", "ntdll/tests: Add tests for RtlIpv6AddressToString and RtlIpv6AddressToStringEx.", 1 },';
@ -5508,7 +5458,6 @@ fi
if test "$enable_ntoskrnl_Stubs" -eq 1; then
patch_apply ntoskrnl-Stubs/0005-ntoskrnl.exe-Improve-KeReleaseMutex-stub.patch
patch_apply ntoskrnl-Stubs/0006-ntoskrnl.exe-Improve-KeInitializeSemaphore-stub.patch
patch_apply ntoskrnl-Stubs/0007-ntoskrnl.exe-Improve-KeInitializeTimerEx-stub.patch
patch_apply ntoskrnl-Stubs/0009-ntoskrnl.exe-Implement-MmMapLockedPages-and-MmUnmapL.patch
patch_apply ntoskrnl-Stubs/0010-ntoskrnl.exe-Implement-KeInitializeMutex.patch
patch_apply ntoskrnl-Stubs/0011-ntoskrnl.exe-Add-IoGetDeviceAttachmentBaseRef-stub.patch
@ -5517,7 +5466,6 @@ if test "$enable_ntoskrnl_Stubs" -eq 1; then
(
printf '%s\n' '+ { "Alexander Morozov", "ntoskrnl.exe: Improve KeReleaseMutex stub.", 1 },';
printf '%s\n' '+ { "Alexander Morozov", "ntoskrnl.exe: Improve KeInitializeSemaphore stub.", 1 },';
printf '%s\n' '+ { "Alexander Morozov", "ntoskrnl.exe: Improve KeInitializeTimerEx stub.", 1 },';
printf '%s\n' '+ { "Christian Costa", "ntoskrnl.exe: Implement MmMapLockedPages and MmUnmapLockedPages.", 1 },';
printf '%s\n' '+ { "Alexander Morozov", "ntoskrnl.exe: Implement KeInitializeMutex.", 1 },';
printf '%s\n' '+ { "Jarkko Korpi", "ntoskrnl.exe: Add IoGetDeviceAttachmentBaseRef stub.", 1 },';

View File

@ -1,7 +1,8 @@
From 0b0d7c4983de54b3ca98a52a4afdd55c92a53031 Mon Sep 17 00:00:00 2001
From 5eaebe8bd280d4a331911bfdc088b4f0e9b655b5 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
Date: Thu, 8 Jun 2017 23:50:03 +0200
Subject: programs/winedevice: Load some common drivers and fix ldr order.
Subject: [PATCH] programs/winedevice: Load some common drivers and fix ldr
order.
---
dlls/ntoskrnl.exe/tests/driver.c | 52 ++++++++++++++++++++++++++++++++++++++++
@ -10,7 +11,7 @@ Subject: programs/winedevice: Load some common drivers and fix ldr order.
3 files changed, 79 insertions(+)
diff --git a/dlls/ntoskrnl.exe/tests/driver.c b/dlls/ntoskrnl.exe/tests/driver.c
index 1ef27fb..6bf2e76 100644
index f56e2dd..c09099f 100644
--- a/dlls/ntoskrnl.exe/tests/driver.c
+++ b/dlls/ntoskrnl.exe/tests/driver.c
@@ -31,6 +31,7 @@
@ -30,7 +31,7 @@ index 1ef27fb..6bf2e76 100644
static HANDLE okfile;
static LONG successes;
static LONG failures;
@@ -231,6 +234,52 @@ static void test_lookaside_list(void)
@@ -246,6 +249,52 @@ static void test_lookaside_list(void)
ExDeleteNPagedLookasideList(&list);
}
@ -83,15 +84,15 @@ index 1ef27fb..6bf2e76 100644
static NTSTATUS main_test(IRP *irp, IO_STACK_LOCATION *stack, ULONG_PTR *info)
{
ULONG length = stack->Parameters.DeviceIoControl.OutputBufferLength;
@@ -258,6 +307,7 @@ static NTSTATUS main_test(IRP *irp, IO_STACK_LOCATION *stack, ULONG_PTR *info)
test_mdl_map();
@@ -274,6 +323,7 @@ static NTSTATUS main_test(IRP *irp, IO_STACK_LOCATION *stack, ULONG_PTR *info)
test_init_funcs();
test_version();
test_lookaside_list();
+ test_default_modules();
/* print process report */
if (test_input->winetest_debug)
@@ -346,6 +396,8 @@ NTSTATUS WINAPI DriverEntry(DRIVER_OBJECT *driver, PUNICODE_STRING registry)
@@ -362,6 +412,8 @@ NTSTATUS WINAPI DriverEntry(DRIVER_OBJECT *driver, PUNICODE_STRING registry)
DbgPrint("loading driver\n");
@ -151,5 +152,5 @@ index fa8b268..aad5981 100644
if (!(stop_event = CreateEventW( NULL, TRUE, FALSE, NULL )))
return;
--
2.7.4
1.9.1