• R/O
  • SSH

提交

標籤
無標籤

Frequently used words (click to add to your profile)

javac++androidlinuxc#objective-cqt誰得cocoawindowspythonrubyphpgameguibathyscaphec翻訳omegat計画中(planning stage)frameworktwittertestdombtronvb.netdirectxarduinopreviewerゲームエンジン

Mercurial Patch Queue for Windows System Libraries


Commit MetaInfo

修訂e94c4e3920591fd2ab0c231c4cdad5043d7c6e7f (tree)
時間2019-04-20 21:22:48
作者Cesar Strauss <cestrauss@gmai...>
CommiterCesar Strauss

Log Message

Add patch to forward declare CONTEXT for Win64.

Change Summary

差異

diff -r 0e5d279d52ab -r e94c4e392059 series
--- a/series Tue Apr 02 23:00:03 2019 +0100
+++ b/series Sat Apr 20 12:22:48 2019 +0000
@@ -1,3 +1,4 @@
1+win64-context.patch #+win64
12 win64-time-typedef.patch #+win64
23 cpu-features-x86-64.patch #+win64
34 alloca-testing.patch #+void #-void
diff -r 0e5d279d52ab -r e94c4e392059 win64-context.patch
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/win64-context.patch Sat Apr 20 12:22:48 2019 +0000
@@ -0,0 +1,42 @@
1+# HG changeset patch
2+# User Cesar Strauss <cestrauss@gmail.com>
3+# Date 1555182688 0
4+# Parent a7cb15fb5ac2a68b8b58cacc752a0941553dc2c7
5+Forward declare CONTEXT for Win64, in place of an actual declaration.
6+
7+Allow uses of pointers to CONTEXT to compile, while postponing the work
8+of determining the actual declaration for Win64.
9+
10+diff -r a7cb15fb5ac2 wslapi/include/winbase.h
11+--- a/wslapi/include/winbase.h Mon Apr 08 10:03:40 2019 +0100
12++++ b/wslapi/include/winbase.h Sat Apr 20 12:19:34 2019 +0000
13+@@ -2386,7 +2386,8 @@
14+ WINBASEAPI DWORD WINAPI SetTapePosition
15+ (HANDLE, DWORD, DWORD, DWORD, DWORD, BOOL);
16+ WINBASEAPI DWORD WINAPI SetThreadAffinityMask (HANDLE, DWORD);
17+-WINBASEAPI BOOL WINAPI SetThreadContext (HANDLE, const CONTEXT *);
18++/* TODO: remove the struct keyword after CONTEXT is defined for x86_64 */
19++WINBASEAPI BOOL WINAPI SetThreadContext (HANDLE, const struct CONTEXT *);
20+
21+ WINBASEAPI DWORD WINAPI SetThreadIdealProcessor (HANDLE, DWORD);
22+ WINBASEAPI BOOL WINAPI SetThreadPriority (HANDLE, int);
23+diff -r a7cb15fb5ac2 wslapi/include/winnt.h
24+--- a/wslapi/include/winnt.h Mon Apr 08 10:03:40 2019 +0100
25++++ b/wslapi/include/winnt.h Sat Apr 20 12:19:34 2019 +0000
26+@@ -2430,10 +2430,15 @@
27+ ULONG Psr;
28+ } CONTEXT;
29+
30++#elif defined(_M_AMD64)
31++/* TODO: Find out the definition of CONTEXT for x86_64 */
32++struct CONTEXT;
33++
34+ #else
35+ #error "undefined processor type"
36+ #endif
37+-typedef CONTEXT *PCONTEXT, *LPCONTEXT;
38++/* TODO: remove the struct keyword after CONTEXT is defined for x86_64 */
39++typedef struct CONTEXT *PCONTEXT, *LPCONTEXT;
40+
41+ typedef struct _EXCEPTION_RECORD
42+ { DWORD ExceptionCode;