Take advantage of the new registers saved in the STACK16FRAME to turn
some 'register' functions into normal functions. Removed the few remaining 'return' functions to simplify relay handling.
This commit is contained in:
parent
e32a317b76
commit
4220b29be9
|
@ -53,3 +53,4 @@ long WINAPI stub_USER_919(void) { FIXME("stub\n"); return 0; }
|
||||||
long WINAPI stub_USER_920(void) { FIXME("stub\n"); return 0; }
|
long WINAPI stub_USER_920(void) { FIXME("stub\n"); return 0; }
|
||||||
long WINAPI stub_USER_922(void) { FIXME("stub\n"); return 0; }
|
long WINAPI stub_USER_922(void) { FIXME("stub\n"); return 0; }
|
||||||
long WINAPI stub_USER_923(void) { FIXME("stub\n"); return 0; }
|
long WINAPI stub_USER_923(void) { FIXME("stub\n"); return 0; }
|
||||||
|
long WINAPI KERNEL_nop(void) { return 0; }
|
||||||
|
|
|
@ -9,7 +9,7 @@ file krnl386.exe
|
||||||
2 pascal16 ExitKernel() ExitKernel16
|
2 pascal16 ExitKernel() ExitKernel16
|
||||||
3 pascal GetVersion() GetVersion16
|
3 pascal GetVersion() GetVersion16
|
||||||
4 pascal16 LocalInit(word word word) LocalInit16
|
4 pascal16 LocalInit(word word word) LocalInit16
|
||||||
5 register LocalAlloc(word word) WIN16_LocalAlloc
|
5 pascal16 LocalAlloc(word word) LocalAlloc16
|
||||||
6 pascal16 LocalReAlloc(word word word) LocalReAlloc16
|
6 pascal16 LocalReAlloc(word word word) LocalReAlloc16
|
||||||
7 pascal16 LocalFree(word) LocalFree16
|
7 pascal16 LocalFree(word) LocalFree16
|
||||||
8 pascal LocalLock(word) LocalLock16
|
8 pascal LocalLock(word) LocalLock16
|
||||||
|
@ -43,8 +43,8 @@ file krnl386.exe
|
||||||
36 pascal GetCurrentTask() WIN16_GetCurrentTask
|
36 pascal GetCurrentTask() WIN16_GetCurrentTask
|
||||||
37 pascal GetCurrentPDB() GetCurrentPDB16
|
37 pascal GetCurrentPDB() GetCurrentPDB16
|
||||||
38 pascal SetTaskSignalProc(word segptr) THUNK_SetTaskSignalProc
|
38 pascal SetTaskSignalProc(word segptr) THUNK_SetTaskSignalProc
|
||||||
41 return EnableDos 0 0
|
41 pascal16 EnableDos() KERNEL_nop
|
||||||
42 return DisableDos 0 0
|
42 pascal16 DisableDos() KERNEL_nop
|
||||||
45 pascal16 LoadModule(str ptr) LoadModule16
|
45 pascal16 LoadModule(str ptr) LoadModule16
|
||||||
46 pascal16 FreeModule(word) FreeModule16
|
46 pascal16 FreeModule(word) FreeModule16
|
||||||
47 pascal GetModuleHandle(segstr) WIN16_GetModuleHandle
|
47 pascal GetModuleHandle(segstr) WIN16_GetModuleHandle
|
||||||
|
@ -99,9 +99,9 @@ file krnl386.exe
|
||||||
95 pascal16 LoadLibrary(str) LoadLibrary16
|
95 pascal16 LoadLibrary(str) LoadLibrary16
|
||||||
96 pascal16 FreeLibrary(word) FreeLibrary16
|
96 pascal16 FreeLibrary(word) FreeLibrary16
|
||||||
97 pascal16 GetTempFileName(word str word ptr) GetTempFileName16
|
97 pascal16 GetTempFileName(word str word ptr) GetTempFileName16
|
||||||
98 return GetLastDiskChange 0 0
|
98 pascal16 GetLastDiskChange() KERNEL_nop
|
||||||
99 stub GetLPErrMode
|
99 stub GetLPErrMode
|
||||||
100 return ValidateCodeSegments 0 0
|
100 pascal16 ValidateCodeSegments() KERNEL_nop
|
||||||
101 stub NoHookDosCall
|
101 stub NoHookDosCall
|
||||||
102 register DOS3Call() DOS3Call
|
102 register DOS3Call() DOS3Call
|
||||||
103 register NetBIOSCall() NetBIOSCall16
|
103 register NetBIOSCall() NetBIOSCall16
|
||||||
|
@ -119,14 +119,14 @@ file krnl386.exe
|
||||||
115 pascal16 OutputDebugString(str) OutputDebugString16
|
115 pascal16 OutputDebugString(str) OutputDebugString16
|
||||||
116 stub InitLib
|
116 stub InitLib
|
||||||
117 pascal16 OldYield() OldYield16
|
117 pascal16 OldYield() OldYield16
|
||||||
118 register GetTaskQueueDS() GetTaskQueueDS16
|
118 pascal16 GetTaskQueueDS() GetTaskQueueDS16
|
||||||
119 register GetTaskQueueES() GetTaskQueueES16
|
119 pascal16 GetTaskQueueES() GetTaskQueueES16
|
||||||
120 stub UndefDynLink
|
120 stub UndefDynLink
|
||||||
121 pascal16 LocalShrink(word word) LocalShrink16
|
121 pascal16 LocalShrink(word word) LocalShrink16
|
||||||
122 pascal16 IsTaskLocked() IsTaskLocked16
|
122 pascal16 IsTaskLocked() IsTaskLocked16
|
||||||
123 return KbdRst 0 0
|
123 pascal16 KbdRst() KERNEL_nop
|
||||||
124 return EnableKernel 0 0
|
124 pascal16 EnableKernel() KERNEL_nop
|
||||||
125 return DisableKernel 0 0
|
125 pascal16 DisableKernel() KERNEL_nop
|
||||||
126 stub MemoryFreed
|
126 stub MemoryFreed
|
||||||
127 pascal16 GetPrivateProfileInt(str str s_word str) GetPrivateProfileInt16
|
127 pascal16 GetPrivateProfileInt(str str s_word str) GetPrivateProfileInt16
|
||||||
128 pascal16 GetPrivateProfileString(str str str ptr word str)
|
128 pascal16 GetPrivateProfileString(str str str ptr word str)
|
||||||
|
@ -136,7 +136,7 @@ file krnl386.exe
|
||||||
130 pascal FileCDR(ptr) FileCDR16
|
130 pascal FileCDR(ptr) FileCDR16
|
||||||
131 pascal GetDOSEnvironment() GetDOSEnvironment16
|
131 pascal GetDOSEnvironment() GetDOSEnvironment16
|
||||||
132 pascal GetWinFlags() GetWinFlags16
|
132 pascal GetWinFlags() GetWinFlags16
|
||||||
133 register GetExePtr(word) WIN16_GetExePtr
|
133 pascal16 GetExePtr(word) GetExePtr
|
||||||
134 pascal16 GetWindowsDirectory(ptr word) GetWindowsDirectory16
|
134 pascal16 GetWindowsDirectory(ptr word) GetWindowsDirectory16
|
||||||
135 pascal16 GetSystemDirectory(ptr word) GetSystemDirectory16
|
135 pascal16 GetSystemDirectory(ptr word) GetSystemDirectory16
|
||||||
136 pascal16 GetDriveType(word) GetDriveType16
|
136 pascal16 GetDriveType(word) GetDriveType16
|
||||||
|
@ -158,16 +158,16 @@ file krnl386.exe
|
||||||
152 pascal16 GetNumTasks() GetNumTasks16
|
152 pascal16 GetNumTasks() GetNumTasks16
|
||||||
154 pascal16 GlobalNotify(segptr) GlobalNotify16
|
154 pascal16 GlobalNotify(segptr) GlobalNotify16
|
||||||
155 pascal16 GetTaskDS() GetTaskDS16
|
155 pascal16 GetTaskDS() GetTaskDS16
|
||||||
156 return LimitEMSPages 4 0
|
156 pascal LimitEMSPages(long) LimitEMSPages16
|
||||||
157 return GetCurPID 4 0
|
157 pascal GetCurPID(long) GetCurPID16
|
||||||
158 return IsWinOldApTask 2 0
|
158 pascal16 IsWinOldApTask(word) IsWinOldApTask16
|
||||||
159 pascal GlobalHandleNoRIP(word) GlobalHandleNoRIP16
|
159 pascal GlobalHandleNoRIP(word) GlobalHandleNoRIP16
|
||||||
160 stub EMSCopy
|
160 stub EMSCopy
|
||||||
161 pascal16 LocalCountFree() LocalCountFree16
|
161 pascal16 LocalCountFree() LocalCountFree16
|
||||||
162 pascal16 LocalHeapSize() LocalHeapSize16
|
162 pascal16 LocalHeapSize() LocalHeapSize16
|
||||||
163 pascal16 GlobalLRUOldest(word) GlobalLRUOldest16
|
163 pascal16 GlobalLRUOldest(word) GlobalLRUOldest16
|
||||||
164 pascal16 GlobalLRUNewest(word) GlobalLRUNewest16
|
164 pascal16 GlobalLRUNewest(word) GlobalLRUNewest16
|
||||||
165 return A20Proc 2 0
|
165 pascal16 A20Proc(word) A20Proc16
|
||||||
166 pascal16 WinExec(str word) WinExec16
|
166 pascal16 WinExec(str word) WinExec16
|
||||||
167 pascal16 GetExpWinVer(word) GetExpWinVer16
|
167 pascal16 GetExpWinVer(word) GetExpWinVer16
|
||||||
168 pascal16 DirectResAlloc(word word word) DirectResAlloc16
|
168 pascal16 DirectResAlloc(word word word) DirectResAlloc16
|
||||||
|
@ -202,7 +202,7 @@ file krnl386.exe
|
||||||
197 pascal16 GlobalFix(word) GlobalFix16
|
197 pascal16 GlobalFix(word) GlobalFix16
|
||||||
198 pascal16 GlobalUnfix(word) GlobalUnfix16
|
198 pascal16 GlobalUnfix(word) GlobalUnfix16
|
||||||
199 pascal16 SetHandleCount(word) SetHandleCount16
|
199 pascal16 SetHandleCount(word) SetHandleCount16
|
||||||
200 return ValidateFreeSpaces 0 0
|
200 pascal16 ValidateFreeSpaces() KERNEL_nop
|
||||||
201 stub ReplaceInst
|
201 stub ReplaceInst
|
||||||
202 stub RegisterPtrace
|
202 stub RegisterPtrace
|
||||||
203 register DebugBreak() DebugBreak16
|
203 register DebugBreak() DebugBreak16
|
||||||
|
@ -243,7 +243,7 @@ file krnl386.exe
|
||||||
234 stub RegSaveKey
|
234 stub RegSaveKey
|
||||||
235 stub InvalidateNlsCache
|
235 stub InvalidateNlsCache
|
||||||
236 stub GetProductName
|
236 stub GetProductName
|
||||||
237 return K237 0 0
|
237 pascal16 K237() KERNEL_nop
|
||||||
|
|
||||||
|
|
||||||
# 262-274 are WinNT extensions; those are not present in Win95
|
# 262-274 are WinNT extensions; those are not present in Win95
|
||||||
|
@ -264,10 +264,10 @@ file krnl386.exe
|
||||||
318 stub FatalExitHook
|
318 stub FatalExitHook
|
||||||
319 stub FlushCachedFileHandle
|
319 stub FlushCachedFileHandle
|
||||||
320 pascal16 IsTask(word) IsTask16
|
320 pascal16 IsTask(word) IsTask16
|
||||||
323 return IsRomModule 2 0
|
323 pascal16 IsRomModule(word) IsRomModule16
|
||||||
324 pascal16 LogError(word ptr) LogError16
|
324 pascal16 LogError(word ptr) LogError16
|
||||||
325 pascal16 LogParamError(word ptr ptr) LogParamError16
|
325 pascal16 LogParamError(word ptr ptr) LogParamError16
|
||||||
326 return IsRomFile 2 0
|
326 pascal16 IsRomFile(word) IsRomFile16
|
||||||
327 register K327() HandleParamError
|
327 register K327() HandleParamError
|
||||||
328 pascal16 _DebugOutput() _DebugOutput
|
328 pascal16 _DebugOutput() _DebugOutput
|
||||||
329 pascal16 K329(str word) DebugFillBuffer
|
329 pascal16 K329(str word) DebugFillBuffer
|
||||||
|
@ -289,7 +289,7 @@ file krnl386.exe
|
||||||
348 pascal16 hmemcpy(ptr ptr long) hmemcpy16
|
348 pascal16 hmemcpy(ptr ptr long) hmemcpy16
|
||||||
349 pascal _hread(word segptr long) WIN16_hread
|
349 pascal _hread(word segptr long) WIN16_hread
|
||||||
350 pascal _hwrite(word ptr long) _hwrite16
|
350 pascal _hwrite(word ptr long) _hwrite16
|
||||||
351 return BUNNY_351 0 0
|
351 pascal16 BUNNY_351() KERNEL_nop
|
||||||
352 pascal lstrcatn(segstr str word) lstrcatn16
|
352 pascal lstrcatn(segstr str word) lstrcatn16
|
||||||
353 pascal lstrcpyn(segptr str word) lstrcpyn16
|
353 pascal lstrcpyn(segptr str word) lstrcpyn16
|
||||||
354 pascal GetAppCompatFlags(word) GetAppCompatFlags16
|
354 pascal GetAppCompatFlags(word) GetAppCompatFlags16
|
||||||
|
@ -305,7 +305,7 @@ file krnl386.exe
|
||||||
358 pascal MapLS(long) MapLS
|
358 pascal MapLS(long) MapLS
|
||||||
359 pascal UnMapLS(segptr) UnMapLS
|
359 pascal UnMapLS(segptr) UnMapLS
|
||||||
360 pascal16 OpenFileEx(str ptr word) OpenFile16
|
360 pascal16 OpenFileEx(str ptr word) OpenFile16
|
||||||
361 return PIGLET_361 0 0
|
361 pascal16 PIGLET_361() KERNEL_nop
|
||||||
362 stub ThunkTerminateProcess
|
362 stub ThunkTerminateProcess
|
||||||
365 register GlobalChangeLockCount(word word) GlobalChangeLockCount16
|
365 register GlobalChangeLockCount(word word) GlobalChangeLockCount16
|
||||||
|
|
||||||
|
@ -351,7 +351,7 @@ file krnl386.exe
|
||||||
444 pascal16 Local32Info(ptr word) Local32Info16
|
444 pascal16 Local32Info(ptr word) Local32Info16
|
||||||
445 pascal16 Local32First(ptr word) Local32First16
|
445 pascal16 Local32First(ptr word) Local32First16
|
||||||
446 pascal16 Local32Next(ptr) Local32Next16
|
446 pascal16 Local32Next(ptr) Local32Next16
|
||||||
447 return KERNEL_447 0 0
|
447 pascal16 KERNEL_447() KERNEL_nop
|
||||||
448 stub KERNEL_448
|
448 stub KERNEL_448
|
||||||
449 pascal GetpWin16Lock() GetpWin16Lock16
|
449 pascal GetpWin16Lock() GetpWin16Lock16
|
||||||
450 pascal VWin32_EventWait(long) VWin32_EventWait
|
450 pascal VWin32_EventWait(long) VWin32_EventWait
|
||||||
|
@ -379,7 +379,7 @@ file krnl386.exe
|
||||||
472 register MapHInstLS() WIN16_MapHInstLS
|
472 register MapHInstLS() WIN16_MapHInstLS
|
||||||
473 register MapHInstSL() WIN16_MapHInstSL
|
473 register MapHInstSL() WIN16_MapHInstSL
|
||||||
474 pascal CloseW32Handle(long) CloseHandle
|
474 pascal CloseW32Handle(long) CloseHandle
|
||||||
475 register GetTEBSelectorFS() GetTEBSelectorFS16
|
475 pascal16 GetTEBSelectorFS() GetTEBSelectorFS16
|
||||||
476 pascal ConvertToGlobalHandle(long) ConvertToGlobalHandle
|
476 pascal ConvertToGlobalHandle(long) ConvertToGlobalHandle
|
||||||
477 stub WOAFullScreen
|
477 stub WOAFullScreen
|
||||||
478 stub WOATerminateProcess
|
478 stub WOATerminateProcess
|
||||||
|
@ -471,7 +471,7 @@ file krnl386.exe
|
||||||
|
|
||||||
600 stub AllocCodeAlias
|
600 stub AllocCodeAlias
|
||||||
601 stub FreeCodeAlias
|
601 stub FreeCodeAlias
|
||||||
602 register GetDummyModuleHandleDS() GetDummyModuleHandleDS16
|
602 pascal16 GetDummyModuleHandleDS() GetDummyModuleHandleDS16
|
||||||
603 stub KERNEL_603 # OutputDebugString (?)
|
603 stub KERNEL_603 # OutputDebugString (?)
|
||||||
604 register CBClientGlueSL() CBClientGlueSL
|
604 register CBClientGlueSL() CBClientGlueSL
|
||||||
605 pascal AllocSLThunkletCallback(long long) AllocSLThunkletCallback16
|
605 pascal AllocSLThunkletCallback(long long) AllocSLThunkletCallback16
|
||||||
|
@ -480,7 +480,7 @@ file krnl386.exe
|
||||||
608 pascal AllocSLThunkletSysthunk(long segptr long) AllocSLThunkletSysthunk16
|
608 pascal AllocSLThunkletSysthunk(long segptr long) AllocSLThunkletSysthunk16
|
||||||
609 pascal FindLSThunkletCallback(segptr long) FindLSThunkletCallback
|
609 pascal FindLSThunkletCallback(segptr long) FindLSThunkletCallback
|
||||||
610 pascal FindSLThunkletCallback(long long) FindSLThunkletCallback
|
610 pascal FindSLThunkletCallback(long long) FindSLThunkletCallback
|
||||||
611 return FreeThunklet 8 0
|
611 pascal16 FreeThunklet() FreeThunklet16
|
||||||
612 pascal16 IsSLThunklet(ptr) IsSLThunklet16
|
612 pascal16 IsSLThunklet(ptr) IsSLThunklet16
|
||||||
613 stub HugeMapLS
|
613 stub HugeMapLS
|
||||||
614 stub HugeUnMapLS
|
614 stub HugeUnMapLS
|
||||||
|
|
|
@ -7,7 +7,7 @@ type win16
|
||||||
4 pascal16 ToAscii(word word ptr ptr word) ToAscii16
|
4 pascal16 ToAscii(word word ptr ptr word) ToAscii16
|
||||||
5 pascal16 AnsiToOem(str ptr) AnsiToOem16
|
5 pascal16 AnsiToOem(str ptr) AnsiToOem16
|
||||||
6 pascal16 OemToAnsi(str ptr) OemToAnsi16
|
6 pascal16 OemToAnsi(str ptr) OemToAnsi16
|
||||||
7 return SetSpeed 2 65535
|
7 pascal16 SetSpeed(word) SetSpeed16
|
||||||
100 pascal ScreenSwitchEnable(word) ScreenSwitchEnable16
|
100 pascal ScreenSwitchEnable(word) ScreenSwitchEnable16
|
||||||
#126 pascal GetTableSeg
|
#126 pascal GetTableSeg
|
||||||
#127 pascal NewTable
|
#127 pascal NewTable
|
||||||
|
|
|
@ -7,7 +7,7 @@ type win16
|
||||||
4 pascal16 EnableSystemTimers() EnableSystemTimers16
|
4 pascal16 EnableSystemTimers() EnableSystemTimers16
|
||||||
5 pascal16 DisableSystemTimers() DisableSystemTimers16
|
5 pascal16 DisableSystemTimers() DisableSystemTimers16
|
||||||
6 pascal GetSystemMSecCount() GetTickCount
|
6 pascal GetSystemMSecCount() GetTickCount
|
||||||
7 return Get80x87SaveSize 0 94
|
7 pascal16 Get80x87SaveSize() Get80x87SaveSize16
|
||||||
8 stub Save80x87State
|
8 pascal16 Save80x87State(ptr) Save80x87State16
|
||||||
9 stub Restore80x87State
|
9 pascal16 Restore80x87State(ptr) Restore80x87State16
|
||||||
#20 stub A20_Proc
|
20 pascal16 A20_Proc(word) A20Proc16
|
||||||
|
|
|
@ -1436,6 +1436,14 @@ SEGPTR WINAPI FindSLThunkletCallback( FARPROC target, DWORD relay )
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/***********************************************************************
|
||||||
|
* FreeThunklet16 (KERNEL.611)
|
||||||
|
*/
|
||||||
|
BOOL16 WINAPI FreeThunklet16( DWORD unused1, DWORD unused2 )
|
||||||
|
{
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
|
|
||||||
/***********************************************************************
|
/***********************************************************************
|
||||||
* Callback Client API
|
* Callback Client API
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -26,8 +26,8 @@ type win16
|
||||||
72 pascal16 MemManInfo(ptr) MemManInfo16
|
72 pascal16 MemManInfo(ptr) MemManInfo16
|
||||||
73 pascal16 NotifyRegister(word segptr word) NotifyRegister16
|
73 pascal16 NotifyRegister(word segptr word) NotifyRegister16
|
||||||
74 pascal16 NotifyUnregister(word) NotifyUnregister16
|
74 pascal16 NotifyUnregister(word) NotifyUnregister16
|
||||||
75 return INTERRUPTREGISTER 6 1
|
75 pascal16 InterruptRegister(word segptr) InterruptRegister16
|
||||||
76 return INTERRUPTUNREGISTER 2 1
|
76 pascal16 InterruptUnRegister(word) InterruptUnRegister16
|
||||||
77 stub TERMINATEAPP
|
77 stub TERMINATEAPP
|
||||||
78 pascal MemoryRead(word long ptr long) MemoryRead16
|
78 pascal MemoryRead(word long ptr long) MemoryRead16
|
||||||
79 pascal MemoryWrite(word long ptr long) MemoryWrite16
|
79 pascal MemoryWrite(word long ptr long) MemoryWrite16
|
||||||
|
|
|
@ -48,7 +48,7 @@ file user.exe
|
||||||
44 pascal16 OpenIcon(word) OpenIcon16
|
44 pascal16 OpenIcon(word) OpenIcon16
|
||||||
45 pascal16 BringWindowToTop(word) BringWindowToTop16
|
45 pascal16 BringWindowToTop(word) BringWindowToTop16
|
||||||
46 pascal16 GetParent(word) GetParent16
|
46 pascal16 GetParent(word) GetParent16
|
||||||
47 register IsWindow(word) WIN16_IsWindow16
|
47 pascal16 IsWindow(word) IsWindow16
|
||||||
48 pascal16 IsChild(word word) IsChild16
|
48 pascal16 IsChild(word word) IsChild16
|
||||||
49 pascal16 IsWindowVisible(word) IsWindowVisible16
|
49 pascal16 IsWindowVisible(word) IsWindowVisible16
|
||||||
50 pascal16 FindWindow(segstr str) FindWindow16
|
50 pascal16 FindWindow(segstr str) FindWindow16
|
||||||
|
@ -233,7 +233,7 @@ file user.exe
|
||||||
228 pascal16 GetNextDlgTabItem(word word word) GetNextDlgTabItem16
|
228 pascal16 GetNextDlgTabItem(word word word) GetNextDlgTabItem16
|
||||||
229 pascal16 GetTopWindow(word) GetTopWindow16
|
229 pascal16 GetTopWindow(word) GetTopWindow16
|
||||||
230 pascal16 GetNextWindow(word word) GetNextWindow16
|
230 pascal16 GetNextWindow(word word) GetNextWindow16
|
||||||
231 return GetSystemDebugState 0 0 #FIXME
|
231 pascal16 GetSystemDebugState() GetSystemDebugState16
|
||||||
232 pascal16 SetWindowPos(word word word word word word word) SetWindowPos16
|
232 pascal16 SetWindowPos(word word word word word word word) SetWindowPos16
|
||||||
233 pascal16 SetParent(word word) SetParent16
|
233 pascal16 SetParent(word word) SetParent16
|
||||||
234 pascal16 UnhookWindowsHook(s_word segptr) THUNK_UnhookWindowsHook16
|
234 pascal16 UnhookWindowsHook(s_word segptr) THUNK_UnhookWindowsHook16
|
||||||
|
|
|
@ -5,7 +5,7 @@ type win16
|
||||||
2 pascal16 IsPeFormat(str word) IsPeFormat16
|
2 pascal16 IsPeFormat(str word) IsPeFormat16
|
||||||
3 stub EXECPE
|
3 stub EXECPE
|
||||||
4 stub GETPEEXEINFO
|
4 stub GETPEEXEINFO
|
||||||
5 return GETW32SYSVERSION 0 0x100
|
5 pascal GetW32SysVersion() GetW32SysVersion16
|
||||||
6 stub LOADPERESOURCE
|
6 stub LOADPERESOURCE
|
||||||
7 pascal16 GetPEResourceTable(word) GetPEResourceTable16
|
7 pascal16 GetPEResourceTable(word) GetPEResourceTable16
|
||||||
8 stub EXECPEEX
|
8 stub EXECPEEX
|
||||||
|
|
|
@ -15,35 +15,13 @@ typedef struct
|
||||||
{
|
{
|
||||||
WORD pushw_bp; /* pushw %bp */
|
WORD pushw_bp; /* pushw %bp */
|
||||||
BYTE pushl; /* pushl $target */
|
BYTE pushl; /* pushl $target */
|
||||||
DWORD target;
|
void (*target)();
|
||||||
BYTE lcall; /* lcall __FLATCS__:relay */
|
BYTE lcall; /* lcall __FLATCS__:relay */
|
||||||
DWORD relay;
|
void (*relay)();
|
||||||
WORD flatcs;
|
WORD flatcs;
|
||||||
} STD_ENTRYPOINT16;
|
|
||||||
|
|
||||||
typedef struct
|
|
||||||
{
|
|
||||||
WORD movw_ax; /* movw $<ax>, %ax */
|
|
||||||
WORD ax;
|
|
||||||
WORD movw_dx; /* movw $<dx>, %dx */
|
|
||||||
WORD dx;
|
|
||||||
WORD lret; /* lret $<args> */
|
|
||||||
WORD args;
|
|
||||||
WORD nopnop; /* nop; nop */
|
|
||||||
} RET_ENTRYPOINT16;
|
|
||||||
|
|
||||||
typedef union
|
|
||||||
{
|
|
||||||
STD_ENTRYPOINT16 std;
|
|
||||||
RET_ENTRYPOINT16 ret;
|
|
||||||
} ENTRYPOINT16;
|
} ENTRYPOINT16;
|
||||||
|
|
||||||
#define EP_STD( target, relay ) \
|
#define EP(target,relay) { 0x5566, 0x68, (target), 0x9a, (relay), __FLATCS__ }
|
||||||
{ std: { 0x5566, 0x68, (DWORD)(target), 0x9a, (DWORD)(relay), __FLATCS__ } }
|
|
||||||
|
|
||||||
#define EP_RET( retval, nargs ) \
|
|
||||||
{ ret: { 0xb866, LOWORD(retval), 0xba66, HIWORD(retval), \
|
|
||||||
(nargs)? 0xca66 : 0xcb66, (nargs)? (nargs) : 0x9090, 0x9090 } }
|
|
||||||
|
|
||||||
#include "poppack.h"
|
#include "poppack.h"
|
||||||
|
|
||||||
|
|
|
@ -1613,6 +1613,22 @@ BOOL16 WINAPI ModuleFindHandle16( MODULEENTRY *lpme, HMODULE16 hModule )
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/***************************************************************************
|
||||||
|
* IsRomModule16 (KERNEL.323)
|
||||||
|
*/
|
||||||
|
BOOL16 WINAPI IsRomModule16( HMODULE16 unused )
|
||||||
|
{
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
|
|
||||||
|
/***************************************************************************
|
||||||
|
* IsRomFile16 (KERNEL.326)
|
||||||
|
*/
|
||||||
|
BOOL16 WINAPI IsRomFile16( HFILE16 unused )
|
||||||
|
{
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
|
|
||||||
/***************************************************************************
|
/***************************************************************************
|
||||||
* MapHModuleLS (KERNEL32.520)
|
* MapHModuleLS (KERNEL32.520)
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -1235,20 +1235,20 @@ void WINAPI SwitchStackBack16( CONTEXT86 *context )
|
||||||
|
|
||||||
|
|
||||||
/***********************************************************************
|
/***********************************************************************
|
||||||
* GetTaskQueueDS (KERNEL.118)
|
* GetTaskQueueDS16 (KERNEL.118)
|
||||||
*/
|
*/
|
||||||
void WINAPI GetTaskQueueDS16( CONTEXT86 *context )
|
void WINAPI GetTaskQueueDS16(void)
|
||||||
{
|
{
|
||||||
DS_reg(context) = GlobalHandleToSel16( GetTaskQueue16(0) );
|
CURRENT_STACK16->ds = GlobalHandleToSel16( GetTaskQueue16(0) );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/***********************************************************************
|
/***********************************************************************
|
||||||
* GetTaskQueueES (KERNEL.119)
|
* GetTaskQueueES16 (KERNEL.119)
|
||||||
*/
|
*/
|
||||||
void WINAPI GetTaskQueueES16( CONTEXT86 *context )
|
void WINAPI GetTaskQueueES16(void)
|
||||||
{
|
{
|
||||||
ES_reg(context) = GlobalHandleToSel16( GetTaskQueue16(0) );
|
CURRENT_STACK16->es = GlobalHandleToSel16( GetTaskQueue16(0) );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -1282,6 +1282,15 @@ DWORD WINAPI GetCurrentPDB16(void)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/***********************************************************************
|
||||||
|
* GetCurPID16 (KERNEL.157)
|
||||||
|
*/
|
||||||
|
DWORD WINAPI GetCurPID16( DWORD unused )
|
||||||
|
{
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/***********************************************************************
|
/***********************************************************************
|
||||||
* GetInstanceData (KERNEL.54)
|
* GetInstanceData (KERNEL.54)
|
||||||
*/
|
*/
|
||||||
|
@ -1357,18 +1366,16 @@ HINSTANCE16 WINAPI GetTaskDS16(void)
|
||||||
/***********************************************************************
|
/***********************************************************************
|
||||||
* GetDummyModuleHandleDS (KERNEL.602)
|
* GetDummyModuleHandleDS (KERNEL.602)
|
||||||
*/
|
*/
|
||||||
VOID WINAPI GetDummyModuleHandleDS16( CONTEXT86 *context )
|
WORD WINAPI GetDummyModuleHandleDS16(void)
|
||||||
{
|
{
|
||||||
TDB *pTask;
|
TDB *pTask;
|
||||||
WORD selector;
|
WORD selector;
|
||||||
|
|
||||||
AX_reg( context ) = 0;
|
if (!(pTask = (TDB *)GlobalLock16( GetCurrentTask() ))) return 0;
|
||||||
if (!(pTask = (TDB *)GlobalLock16( GetCurrentTask() ))) return;
|
if (!(pTask->flags & TDBF_WIN32)) return 0;
|
||||||
if (!(pTask->flags & TDBF_WIN32)) return;
|
|
||||||
|
|
||||||
selector = GlobalHandleToSel16( pTask->hModule );
|
selector = GlobalHandleToSel16( pTask->hModule );
|
||||||
DS_reg( context ) = selector;
|
CURRENT_DS = selector;
|
||||||
AX_reg( context ) = selector;
|
return selector;
|
||||||
}
|
}
|
||||||
|
|
||||||
/***********************************************************************
|
/***********************************************************************
|
||||||
|
@ -1384,6 +1391,15 @@ BOOL16 WINAPI IsTask16( HTASK16 hTask )
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/***********************************************************************
|
||||||
|
* IsWinOldApTask16 (KERNEL.158)
|
||||||
|
*/
|
||||||
|
BOOL16 WINAPI IsWinOldApTask16( HTASK16 hTask )
|
||||||
|
{
|
||||||
|
/* should return bit 0 of byte 0x48 in PSP */
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
|
|
||||||
/***********************************************************************
|
/***********************************************************************
|
||||||
* SetTaskSignalProc (KERNEL.38)
|
* SetTaskSignalProc (KERNEL.38)
|
||||||
*
|
*
|
||||||
|
@ -1445,7 +1461,7 @@ VOID WINAPI GlobalNotify16( FARPROC16 proc )
|
||||||
/***********************************************************************
|
/***********************************************************************
|
||||||
* GetExePtr (KERNEL.133)
|
* GetExePtr (KERNEL.133)
|
||||||
*/
|
*/
|
||||||
static HMODULE16 GetExePtrHelper( HANDLE16 handle, HTASK16 *hTask )
|
static inline HMODULE16 GetExePtrHelper( HANDLE16 handle, HTASK16 *hTask )
|
||||||
{
|
{
|
||||||
char *ptr;
|
char *ptr;
|
||||||
HANDLE16 owner;
|
HANDLE16 owner;
|
||||||
|
@ -1492,21 +1508,15 @@ static HMODULE16 GetExePtrHelper( HANDLE16 handle, HTASK16 *hTask )
|
||||||
|
|
||||||
HMODULE16 WINAPI GetExePtr( HANDLE16 handle )
|
HMODULE16 WINAPI GetExePtr( HANDLE16 handle )
|
||||||
{
|
{
|
||||||
HTASK16 dummy;
|
STACK16FRAME *frame;
|
||||||
return GetExePtrHelper( handle, &dummy );
|
|
||||||
}
|
|
||||||
|
|
||||||
void WINAPI WIN16_GetExePtr( CONTEXT86 *context )
|
|
||||||
{
|
|
||||||
WORD *stack = PTR_SEG_OFF_TO_LIN(SS_reg(context), SP_reg(context));
|
|
||||||
HANDLE16 handle = (HANDLE16)stack[2];
|
|
||||||
HTASK16 hTask = 0;
|
HTASK16 hTask = 0;
|
||||||
HMODULE16 hModule;
|
HMODULE16 hModule = GetExePtrHelper( handle, &hTask );
|
||||||
|
if ((frame = CURRENT_STACK16) != NULL)
|
||||||
hModule = GetExePtrHelper( handle, &hTask );
|
{
|
||||||
|
frame->ecx = hModule;
|
||||||
AX_reg(context) = CX_reg(context) = hModule;
|
if (hTask) frame->es = hTask;
|
||||||
if (hTask) ES_reg(context) = hTask;
|
}
|
||||||
|
return hModule;
|
||||||
}
|
}
|
||||||
|
|
||||||
/***********************************************************************
|
/***********************************************************************
|
||||||
|
|
|
@ -1481,3 +1481,20 @@ WORD WINAPI WOWGlobalUnlockFree16(DWORD vpmem) {
|
||||||
return 0;
|
return 0;
|
||||||
return GlobalFree16(HIWORD(vpmem));
|
return GlobalFree16(HIWORD(vpmem));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/***********************************************************************
|
||||||
|
* A20Proc16 (KERNEL.165)
|
||||||
|
*/
|
||||||
|
void WINAPI A20Proc16( WORD unused )
|
||||||
|
{
|
||||||
|
/* this is also a NOP in Windows */
|
||||||
|
}
|
||||||
|
|
||||||
|
/***********************************************************************
|
||||||
|
* LimitEMSPages16 (KERNEL.156)
|
||||||
|
*/
|
||||||
|
DWORD WINAPI LimitEMSPages16( DWORD unused )
|
||||||
|
{
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
|
@ -328,7 +328,8 @@ BOOL16 WINAPI LocalInit16( HANDLE16 selector, WORD start, WORD end )
|
||||||
LOCALHEAPINFO *pHeapInfo;
|
LOCALHEAPINFO *pHeapInfo;
|
||||||
LOCALARENA *pArena, *pFirstArena, *pLastArena;
|
LOCALARENA *pArena, *pFirstArena, *pLastArena;
|
||||||
NE_MODULE *pModule;
|
NE_MODULE *pModule;
|
||||||
|
BOOL16 ret = FALSE;
|
||||||
|
|
||||||
/* The initial layout of the heap is: */
|
/* The initial layout of the heap is: */
|
||||||
/* - first arena (FIXED) */
|
/* - first arena (FIXED) */
|
||||||
/* - heap info structure (FIXED) */
|
/* - heap info structure (FIXED) */
|
||||||
|
@ -390,7 +391,7 @@ BOOL16 WINAPI LocalInit16( HANDLE16 selector, WORD start, WORD end )
|
||||||
|
|
||||||
/* Make sure there's enough space. */
|
/* Make sure there's enough space. */
|
||||||
|
|
||||||
if (freeArena + sizeof(LOCALARENA) >= lastArena) return FALSE;
|
if (freeArena + sizeof(LOCALARENA) >= lastArena) goto done;
|
||||||
|
|
||||||
/* Initialise the first arena */
|
/* Initialise the first arena */
|
||||||
|
|
||||||
|
@ -442,7 +443,11 @@ BOOL16 WINAPI LocalInit16( HANDLE16 selector, WORD start, WORD end )
|
||||||
|
|
||||||
((INSTANCEDATA *)ptr)->heap = heapInfoArena + ARENA_HEADER_SIZE;
|
((INSTANCEDATA *)ptr)->heap = heapInfoArena + ARENA_HEADER_SIZE;
|
||||||
LOCAL_PrintHeap( selector );
|
LOCAL_PrintHeap( selector );
|
||||||
return TRUE;
|
ret = TRUE;
|
||||||
|
|
||||||
|
done:
|
||||||
|
CURRENT_STACK16->ecx = ret; /* must be returned in cx too */
|
||||||
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
/***********************************************************************
|
/***********************************************************************
|
||||||
|
@ -1532,20 +1537,9 @@ HLOCAL16 LOCAL_Handle( HANDLE16 ds, WORD addr )
|
||||||
*/
|
*/
|
||||||
HLOCAL16 WINAPI LocalAlloc16( UINT16 flags, WORD size )
|
HLOCAL16 WINAPI LocalAlloc16( UINT16 flags, WORD size )
|
||||||
{
|
{
|
||||||
return LOCAL_Alloc( CURRENT_DS, flags, size );
|
HLOCAL16 ret = LOCAL_Alloc( CURRENT_DS, flags, size );
|
||||||
}
|
CURRENT_STACK16->ecx = ret; /* must be returned in cx too */
|
||||||
|
return ret;
|
||||||
|
|
||||||
/***********************************************************************
|
|
||||||
* WIN16_LocalAlloc
|
|
||||||
*/
|
|
||||||
void WINAPI WIN16_LocalAlloc( CONTEXT86 *context )
|
|
||||||
{
|
|
||||||
WORD *stack = PTR_SEG_OFF_TO_LIN(SS_reg(context), SP_reg(context));
|
|
||||||
UINT16 flags = (UINT16)stack[3];
|
|
||||||
WORD size = (WORD)stack[2];
|
|
||||||
TRACE_(local)("WIN16LocalAlloc: %04x %d \n", flags, size);
|
|
||||||
AX_reg(context) = CX_reg(context) = LOCAL_Alloc( DS_reg(context), flags, size );
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -152,3 +152,35 @@ void WINAPI DisableSystemTimers16(void)
|
||||||
if ( SYS_Service != INVALID_HANDLE_VALUE )
|
if ( SYS_Service != INVALID_HANDLE_VALUE )
|
||||||
SERVICE_Disable( SYS_Service );
|
SERVICE_Disable( SYS_Service );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/***********************************************************************
|
||||||
|
* Get80x87SaveSize16 (SYSTEM.7)
|
||||||
|
*/
|
||||||
|
WORD Get80x87SaveSize16(void)
|
||||||
|
{
|
||||||
|
return 94;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/***********************************************************************
|
||||||
|
* Save80x87State16 (SYSTEM.8)
|
||||||
|
*/
|
||||||
|
void Save80x87State16( char *ptr )
|
||||||
|
{
|
||||||
|
#ifdef __i386__
|
||||||
|
__asm__(".byte 0x66; fsave %0; fwait" : "=m" (ptr) );
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/***********************************************************************
|
||||||
|
* Restore80x87State16 (SYSTEM.9)
|
||||||
|
*/
|
||||||
|
void Restore80x87State16( const char *ptr )
|
||||||
|
{
|
||||||
|
#ifdef __i386__
|
||||||
|
__asm__(".byte 0x66; frstor %0" : : "m" (ptr) );
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
|
|
@ -97,6 +97,16 @@ BOOL16 WINAPI StackTraceNext16(STACKTRACEENTRY *ste)
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
BOOL16 WINAPI InterruptRegister16( HTASK16 task, FARPROC callback )
|
||||||
|
{
|
||||||
|
return TRUE;
|
||||||
|
}
|
||||||
|
|
||||||
|
BOOL16 WINAPI InterruptUnRegister16( HTASK16 task )
|
||||||
|
{
|
||||||
|
return TRUE;
|
||||||
|
}
|
||||||
|
|
||||||
/***********************************************************************
|
/***********************************************************************
|
||||||
* ToolHelpHook (KERNEL.341)
|
* ToolHelpHook (KERNEL.341)
|
||||||
* see "Undocumented Windows"
|
* see "Undocumented Windows"
|
||||||
|
|
|
@ -24,6 +24,14 @@ WORD WINAPI GetWin32sInfo16(
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/***********************************************************************
|
||||||
|
* GetW32SysVersion16 (W32SYS.5)
|
||||||
|
*/
|
||||||
|
void WINAPI GetW32SysVersion16(void)
|
||||||
|
{
|
||||||
|
return 0x100;
|
||||||
|
}
|
||||||
|
|
||||||
/***********************************************************************
|
/***********************************************************************
|
||||||
* GetPEResourceTable (W32SYS.7)
|
* GetPEResourceTable (W32SYS.7)
|
||||||
* retrieves the resourcetable from the passed filedescriptor
|
* retrieves the resourcetable from the passed filedescriptor
|
||||||
|
|
|
@ -13,8 +13,6 @@ ORDINAL stub EXPORTNAME
|
||||||
|
|
||||||
ORDINAL equate EXPORTNAME DATA
|
ORDINAL equate EXPORTNAME DATA
|
||||||
|
|
||||||
ORDINAL return EXPORTNAME ARGLENGTH RETVALUE
|
|
||||||
|
|
||||||
ORDINAL extern EXPORTNAME SYMBOLNAME
|
ORDINAL extern EXPORTNAME SYMBOLNAME
|
||||||
|
|
||||||
ORDINAL forward EXPORTNAME SYMBOLNAME
|
ORDINAL forward EXPORTNAME SYMBOLNAME
|
||||||
|
@ -122,16 +120,6 @@ Equate ordinals:
|
||||||
variable. "EXPORTNAME" will be the name available for dynamic linking.
|
variable. "EXPORTNAME" will be the name available for dynamic linking.
|
||||||
"DATA" can be a decimal number or a hex number preceeded by "0x".
|
"DATA" can be a decimal number or a hex number preceeded by "0x".
|
||||||
|
|
||||||
Return ordinals:
|
|
||||||
================
|
|
||||||
|
|
||||||
This type defines a function entry point whose handler should do
|
|
||||||
nothing but return a value.
|
|
||||||
"ORDINAL" is replaced by the ordinal number corresponding to the
|
|
||||||
variable. ARGLENGTH is the number of bytes that need to be removed
|
|
||||||
from the stack before returning to the caller. RETVALUE is the
|
|
||||||
return value which will be passed back to the caller.
|
|
||||||
|
|
||||||
Extern ordinals:
|
Extern ordinals:
|
||||||
================
|
================
|
||||||
|
|
||||||
|
|
|
@ -49,7 +49,6 @@ typedef enum
|
||||||
TYPE_PASCAL_16, /* pascal function with 16-bit return (Win16) */
|
TYPE_PASCAL_16, /* pascal function with 16-bit return (Win16) */
|
||||||
TYPE_PASCAL, /* pascal function with 32-bit return (Win16) */
|
TYPE_PASCAL, /* pascal function with 32-bit return (Win16) */
|
||||||
TYPE_ABS, /* absolute value (Win16) */
|
TYPE_ABS, /* absolute value (Win16) */
|
||||||
TYPE_RETURN, /* simple return value function (Win16) */
|
|
||||||
TYPE_REGISTER, /* register function */
|
TYPE_REGISTER, /* register function */
|
||||||
TYPE_STUB, /* unimplemented stub */
|
TYPE_STUB, /* unimplemented stub */
|
||||||
TYPE_STDCALL, /* stdcall function (Win32) */
|
TYPE_STDCALL, /* stdcall function (Win32) */
|
||||||
|
@ -69,7 +68,6 @@ static const char * const TypeNames[TYPE_NBTYPES] =
|
||||||
"pascal16", /* TYPE_PASCAL_16 */
|
"pascal16", /* TYPE_PASCAL_16 */
|
||||||
"pascal", /* TYPE_PASCAL */
|
"pascal", /* TYPE_PASCAL */
|
||||||
"equate", /* TYPE_ABS */
|
"equate", /* TYPE_ABS */
|
||||||
"return", /* TYPE_RETURN */
|
|
||||||
"register", /* TYPE_REGISTER */
|
"register", /* TYPE_REGISTER */
|
||||||
"stub", /* TYPE_STUB */
|
"stub", /* TYPE_STUB */
|
||||||
"stdcall", /* TYPE_STDCALL */
|
"stdcall", /* TYPE_STDCALL */
|
||||||
|
@ -501,45 +499,6 @@ static int ParseEquate( ORDDEF *odp )
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*******************************************************************
|
|
||||||
* ParseReturn
|
|
||||||
*
|
|
||||||
* Parse a 'return' definition.
|
|
||||||
*/
|
|
||||||
static int ParseReturn( ORDDEF *odp )
|
|
||||||
{
|
|
||||||
char *token;
|
|
||||||
char *endptr;
|
|
||||||
|
|
||||||
token = GetToken();
|
|
||||||
odp->u.ret.arg_size = strtol(token, &endptr, 0);
|
|
||||||
if (endptr == NULL || *endptr != '\0')
|
|
||||||
{
|
|
||||||
fprintf(stderr, "%s:%d: Expected number value, got '%s'\n",
|
|
||||||
SpecName, Line, token);
|
|
||||||
return -1;
|
|
||||||
}
|
|
||||||
|
|
||||||
token = GetToken();
|
|
||||||
odp->u.ret.ret_value = strtol(token, &endptr, 0);
|
|
||||||
if (endptr == NULL || *endptr != '\0')
|
|
||||||
{
|
|
||||||
fprintf(stderr, "%s:%d: Expected number value, got '%s'\n",
|
|
||||||
SpecName, Line, token);
|
|
||||||
return -1;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (SpecType == SPEC_WIN32)
|
|
||||||
{
|
|
||||||
fprintf( stderr, "%s:%d: 'return' not supported for Win32\n",
|
|
||||||
SpecName, Line );
|
|
||||||
return -1;
|
|
||||||
}
|
|
||||||
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/*******************************************************************
|
/*******************************************************************
|
||||||
* ParseStub
|
* ParseStub
|
||||||
*
|
*
|
||||||
|
@ -684,8 +643,6 @@ static int ParseOrdinal(int ordinal)
|
||||||
return ParseExportFunction( odp );
|
return ParseExportFunction( odp );
|
||||||
case TYPE_ABS:
|
case TYPE_ABS:
|
||||||
return ParseEquate( odp );
|
return ParseEquate( odp );
|
||||||
case TYPE_RETURN:
|
|
||||||
return ParseReturn( odp );
|
|
||||||
case TYPE_STUB:
|
case TYPE_STUB:
|
||||||
return ParseStub( odp );
|
return ParseStub( odp );
|
||||||
case TYPE_VARARGS:
|
case TYPE_VARARGS:
|
||||||
|
@ -983,7 +940,6 @@ static int BuildModule16( FILE *outfile, int max_code_offset,
|
||||||
case TYPE_PASCAL:
|
case TYPE_PASCAL:
|
||||||
case TYPE_PASCAL_16:
|
case TYPE_PASCAL_16:
|
||||||
case TYPE_REGISTER:
|
case TYPE_REGISTER:
|
||||||
case TYPE_RETURN:
|
|
||||||
case TYPE_STUB:
|
case TYPE_STUB:
|
||||||
selector = 1; /* Code selector */
|
selector = 1; /* Code selector */
|
||||||
break;
|
break;
|
||||||
|
@ -1410,22 +1366,13 @@ static int BuildSpec16File( char * specfile, FILE *outfile )
|
||||||
data_offset += StoreVariableCode( data + data_offset, 4, odp);
|
data_offset += StoreVariableCode( data + data_offset, 4, odp);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case TYPE_RETURN:
|
|
||||||
fprintf( outfile, " /* %s.%d */ ", DLLName, i );
|
|
||||||
fprintf( outfile, "EP_RET( %d, %d ),\n",
|
|
||||||
odp->u.ret.ret_value, odp->u.ret.arg_size );
|
|
||||||
|
|
||||||
odp->offset = code_offset;
|
|
||||||
code_offset += sizeof(ENTRYPOINT16);
|
|
||||||
break;
|
|
||||||
|
|
||||||
case TYPE_REGISTER:
|
case TYPE_REGISTER:
|
||||||
case TYPE_CDECL:
|
case TYPE_CDECL:
|
||||||
case TYPE_PASCAL:
|
case TYPE_PASCAL:
|
||||||
case TYPE_PASCAL_16:
|
case TYPE_PASCAL_16:
|
||||||
case TYPE_STUB:
|
case TYPE_STUB:
|
||||||
fprintf( outfile, " /* %s.%d */ ", DLLName, i );
|
fprintf( outfile, " /* %s.%d */ ", DLLName, i );
|
||||||
fprintf( outfile, "EP_STD( %s, %s_CallFrom16_%s_%s_%s ),\n",
|
fprintf( outfile, "EP( %s, %s_CallFrom16_%s_%s_%s ),\n",
|
||||||
odp->u.func.link_name,
|
odp->u.func.link_name,
|
||||||
DLLName,
|
DLLName,
|
||||||
(odp->type == TYPE_CDECL) ? "c" : "p",
|
(odp->type == TYPE_CDECL) ? "c" : "p",
|
||||||
|
|
|
@ -1018,9 +1018,9 @@ FreeSLCallback(
|
||||||
* GetTEBSelectorFS (KERNEL.475)
|
* GetTEBSelectorFS (KERNEL.475)
|
||||||
* Set the 16-bit %fs to the 32-bit %fs (current TEB selector)
|
* Set the 16-bit %fs to the 32-bit %fs (current TEB selector)
|
||||||
*/
|
*/
|
||||||
VOID WINAPI GetTEBSelectorFS16( CONTEXT86 *context )
|
void WINAPI GetTEBSelectorFS16(void)
|
||||||
{
|
{
|
||||||
GET_FS( FS_reg(context) );
|
GET_FS( CURRENT_STACK16->fs );
|
||||||
}
|
}
|
||||||
|
|
||||||
/**********************************************************************
|
/**********************************************************************
|
||||||
|
|
|
@ -100,6 +100,15 @@ void KEYBOARD_SendEvent( BYTE bVk, BYTE bScan, DWORD dwFlags,
|
||||||
WIN_RestoreWndsLock(iWndsLocks);
|
WIN_RestoreWndsLock(iWndsLocks);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**********************************************************************
|
||||||
|
* SetSpeed16 (KEYBOARD.7)
|
||||||
|
*/
|
||||||
|
WORD WINAPI SetSpeed16(WORD unused)
|
||||||
|
{
|
||||||
|
FIXME_(keyboard)("(%04x): stub\n",unused);
|
||||||
|
return 0xffff;
|
||||||
|
}
|
||||||
|
|
||||||
/**********************************************************************
|
/**********************************************************************
|
||||||
* ScreenSwitchEnable (KEYBOARD.100)
|
* ScreenSwitchEnable (KEYBOARD.100)
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -432,6 +432,14 @@ DWORD WINAPI UserSeeUserDo16(WORD wReqType, WORD wParam1, WORD wParam2, WORD wPa
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/***********************************************************************
|
||||||
|
* GetSystemDebugState16 (USER.231)
|
||||||
|
*/
|
||||||
|
WORD WINAPI GetSystemDebugState16(void)
|
||||||
|
{
|
||||||
|
return 0; /* FIXME */
|
||||||
|
}
|
||||||
|
|
||||||
/***********************************************************************
|
/***********************************************************************
|
||||||
* RegisterLogonProcess (USER32.434)
|
* RegisterLogonProcess (USER32.434)
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -26,12 +26,13 @@
|
||||||
#include "task.h"
|
#include "task.h"
|
||||||
#include "thread.h"
|
#include "thread.h"
|
||||||
#include "process.h"
|
#include "process.h"
|
||||||
#include "debugtools.h"
|
|
||||||
#include "winerror.h"
|
#include "winerror.h"
|
||||||
#include "mdi.h"
|
#include "mdi.h"
|
||||||
#include "local.h"
|
#include "local.h"
|
||||||
#include "desktop.h"
|
#include "desktop.h"
|
||||||
#include "syslevel.h"
|
#include "syslevel.h"
|
||||||
|
#include "stackframe.h"
|
||||||
|
#include "debugtools.h"
|
||||||
|
|
||||||
DECLARE_DEBUG_CHANNEL(msg)
|
DECLARE_DEBUG_CHANNEL(msg)
|
||||||
DECLARE_DEBUG_CHANNEL(win)
|
DECLARE_DEBUG_CHANNEL(win)
|
||||||
|
@ -2283,18 +2284,10 @@ INT WINAPI GetWindowTextLengthW( HWND hwnd )
|
||||||
*/
|
*/
|
||||||
BOOL16 WINAPI IsWindow16( HWND16 hwnd )
|
BOOL16 WINAPI IsWindow16( HWND16 hwnd )
|
||||||
{
|
{
|
||||||
|
CURRENT_STACK16->es = USER_HeapSel;
|
||||||
return IsWindow( hwnd );
|
return IsWindow( hwnd );
|
||||||
}
|
}
|
||||||
|
|
||||||
void WINAPI WIN16_IsWindow16( CONTEXT86 *context )
|
|
||||||
{
|
|
||||||
WORD *stack = PTR_SEG_OFF_TO_LIN(SS_reg(context), SP_reg(context));
|
|
||||||
HWND16 hwnd = (HWND16)stack[2];
|
|
||||||
|
|
||||||
AX_reg(context) = IsWindow( hwnd );
|
|
||||||
ES_reg(context) = USER_HeapSel;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/*******************************************************************
|
/*******************************************************************
|
||||||
* IsWindow32 (USER32.348)
|
* IsWindow32 (USER32.348)
|
||||||
|
|
Loading…
Reference in New Issue