3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync/*
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync * Copyright (C) the Wine project
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync *
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync * This library is free software; you can redistribute it and/or
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync * modify it under the terms of the GNU Lesser General Public
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync * License as published by the Free Software Foundation; either
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync * version 2.1 of the License, or (at your option) any later version.
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync *
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync * This library is distributed in the hope that it will be useful,
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync * but WITHOUT ANY WARRANTY; without even the implied warranty of
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync * Lesser General Public License for more details.
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync *
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync * You should have received a copy of the GNU Lesser General Public
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync * License along with this library; if not, write to the Free Software
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
930b5f872e89407f445d4000d4e4aaecaa6a0998vboxsync/*
930b5f872e89407f445d4000d4e4aaecaa6a0998vboxsync * Oracle LGPL Disclaimer: For the avoidance of doubt, except that if any license choice
930b5f872e89407f445d4000d4e4aaecaa6a0998vboxsync * other than GPL or LGPL is available it will apply instead, Oracle elects to use only
930b5f872e89407f445d4000d4e4aaecaa6a0998vboxsync * the Lesser General Public License version 2.1 (LGPLv2) at this time for any software where
930b5f872e89407f445d4000d4e4aaecaa6a0998vboxsync * a choice of LGPL license versions is made available with the language indicating
930b5f872e89407f445d4000d4e4aaecaa6a0998vboxsync * that LGPLv2 or any later version may be used, or where a choice of which version
930b5f872e89407f445d4000d4e4aaecaa6a0998vboxsync * of the LGPL is applied is otherwise unspecified.
930b5f872e89407f445d4000d4e4aaecaa6a0998vboxsync */
930b5f872e89407f445d4000d4e4aaecaa6a0998vboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#ifndef __WINE_WINE_WINBASE16_H
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define __WINE_WINE_WINBASE16_H
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#include <stdarg.h>
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#include <windef.h>
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#include <winbase.h>
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#include <winnls.h>
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#include <wine/windef16.h>
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#include <wine/library.h>
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#include <pshpack1.h>
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync/* Process database (i.e. a normal DOS PSP) */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsynctypedef struct
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync{
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD int20; /* 00 int 20h instruction */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD nextParagraph; /* 02 Segment of next paragraph */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync BYTE reserved1;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync BYTE dispatcher[5]; /* 05 Long call to DOS */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync FARPROC16 savedint22; /* 0a Saved int 22h handler */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync FARPROC16 savedint23; /* 0e Saved int 23h handler */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync FARPROC16 savedint24; /* 12 Saved int 24h handler */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD parentPSP; /* 16 Selector of parent PSP */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync BYTE fileHandles[20]; /* 18 Open file handles */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync HANDLE16 environment; /* 2c Selector of environment */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD saveStack; /* 2e SS:SP on last int21 call */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD nbFiles; /* 32 Number of file handles */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync SEGPTR fileHandlesPtr; /* 34 Pointer to file handle table */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync HANDLE16 hFileHandles; /* 38 Handle to fileHandlesPtr */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD reserved3[17];
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync BYTE fcb1[16]; /* 5c First FCB */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync BYTE fcb2[20]; /* 6c Second FCB */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync BYTE cmdLine[128]; /* 80 Command-line (first byte is len)*/
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync BYTE padding[16]; /* Some apps access beyond the end of the cmd line */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync} PDB16;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync/* Task database. See 'Windows Internals' p. 226.
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync * Note that 16-bit OLE 2 libs like to read it directly
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync * so we have to keep entry offsets as they are.
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsynctypedef struct _TDB
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync{
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync HTASK16 hNext; /* 00 Selector of next TDB */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD ss_sp; /* 02 Stack pointer of task */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD nEvents; /* 06 Events for this task */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync INT16 priority; /* 08 Task priority, -32..15 */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD unused1; /* 0a */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync HTASK16 hSelf; /* 0c Selector of this TDB */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync HANDLE16 hPrevInstance; /* 0e Previous instance of module */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD unused2; /* 10 */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD ctrlword8087; /* 14 80x87 control word */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD flags; /* 16 Task flags */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync UINT16 error_mode; /* 18 Error mode (see SetErrorMode)*/
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD version; /* 1a Expected Windows version */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync HANDLE16 hInstance; /* 1c Instance handle for task */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync HMODULE16 hModule; /* 1e Module handle */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync HQUEUE16 hQueue; /* 20 Selector of task queue */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync HTASK16 hParent; /* 22 Selector of TDB of parent */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD signal_flags; /* 24 Flags for signal handler */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync FARPROC16 sighandler; /* 26 Signal handler */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync FARPROC16 userhandler; /* 2a USER signal handler */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync FARPROC16 discardhandler; /* 2e Handler for GlobalNotify() */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync FARPROC16 int0; /* 32 int 0 (divide by 0) handler */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync FARPROC16 int2; /* 36 int 2 (NMI) handler */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync FARPROC16 int4; /* 3a int 4 (INTO) handler */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync FARPROC16 int6; /* 3e int 6 (invalid opc) handler */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync FARPROC16 int7; /* 42 int 7 (coprocessor) handler */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync FARPROC16 int3e; /* 46 int 3e (80x87 emu) handler */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync FARPROC16 int75; /* 4a int 75 (80x87 error) handler */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD compat_flags; /* 4e Compatibility flags */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync BYTE unused4[2]; /* 52 */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync struct _TEB *teb; /* 54 Pointer to thread database */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync BYTE unused5[8]; /* 58 */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync HANDLE16 hPDB; /* 60 Selector of PDB (i.e. PSP) */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync SEGPTR dta; /* 62 Current DTA */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync BYTE curdrive; /* 66 Current drive */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync CHAR curdir[65]; /* 67 Current directory */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD nCmdShow; /* a8 cmdShow parameter to WinMain */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync HTASK16 hYieldTo; /* aa Next task to schedule */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD dlls_to_init; /* ac Ptr to DLLs to initialize */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync HANDLE16 hCSAlias; /* b0 Code segment for this TDB */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD thunks[8*4]; /* b2 Make proc instance thunks */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync CHAR module_name[8]; /* f2 Module name for task */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD magic; /* fa TDB signature */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync HANDLE hEvent; /* fc scheduler event handle */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync PDB16 pdb; /* 100 PDB for this task */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync} TDB;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync/* TDB flags */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define TDBF_WINOLDAP 0x0001
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define TDBF_OS2APP 0x0008
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define TDBF_WIN32 0x0010
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync/* Windows 3.1 USER signals */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define USIG16_TERMINATION 0x0020
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define USIG16_DLL_LOAD 0x0040
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define USIG16_DLL_UNLOAD 0x0080
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define USIG16_GPF 0x0666
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsynctypedef struct _SEGINFO {
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync UINT16 offSegment;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync UINT16 cbSegment;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync UINT16 flags;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync UINT16 cbAlloc;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync HGLOBAL16 h;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync UINT16 alignShift;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync UINT16 reserved[2];
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync} SEGINFO;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync/* GetWinFlags */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define WF_PMODE 0x0001
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define WF_CPU286 0x0002
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define WF_CPU386 0x0004
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define WF_CPU486 0x0008
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define WF_STANDARD 0x0010
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define WF_WIN286 0x0010
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define WF_ENHANCED 0x0020
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define WF_WIN386 0x0020
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define WF_CPU086 0x0040
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define WF_CPU186 0x0080
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define WF_LARGEFRAME 0x0100
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define WF_SMALLFRAME 0x0200
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define WF_80x87 0x0400
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define WF_PAGING 0x0800
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define WF_HASCPUID 0x2000
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define WF_WIN32WOW 0x4000 /* undoc */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define WF_WLO 0x8000
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync/* Parameters for LoadModule() */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsynctypedef struct
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync{
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync HGLOBAL16 hEnvironment; /* Environment segment */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync SEGPTR cmdLine; /* Command-line */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync SEGPTR showCmd; /* Code for ShowWindow() */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync SEGPTR reserved;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync} LOADPARAMS16;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync/* Debugging support (DEBUG SYSTEM ONLY) */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsynctypedef struct
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync{
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD flags;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD dwOptions;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD dwFilter;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync CHAR achAllocModule[8];
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD dwAllocBreak;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD dwAllocCount;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync} WINDEBUGINFO16, *LPWINDEBUGINFO16;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync/* definitions specific to Wine 16-bit relaying support */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync/* 32-bit stack layout after __wine_call_to_16() */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsynctypedef struct _STACK32FRAME
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync{
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD restore_addr; /* 00 return address for restoring code selector */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD codeselector; /* 04 code selector to restore */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync EXCEPTION_REGISTRATION_RECORD frame; /* 08 Exception frame */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync SEGPTR frame16; /* 10 16-bit frame from last CallFrom16() */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD edi; /* 14 saved registers */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD esi; /* 18 */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD ebx; /* 1c */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD ebp; /* 20 saved 32-bit frame pointer */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD retaddr; /* 24 return address */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD target; /* 28 target address / CONTEXT86 pointer */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD nb_args; /* 2c number of 16-bit argument bytes */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync} STACK32FRAME;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync/* 16-bit stack layout after __wine_call_from_16() */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsynctypedef struct _STACK16FRAME
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync{
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync STACK32FRAME *frame32; /* 00 32-bit frame from last CallTo16() */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD edx; /* 04 saved registers */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD ecx; /* 08 */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD ebp; /* 0c */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD ds; /* 10 */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD es; /* 12 */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD fs; /* 14 */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD gs; /* 16 */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD callfrom_ip; /* 18 callfrom tail IP */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD module_cs; /* 1c module code segment */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD relay; /* 20 relay function address */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD entry_ip; /* 22 entry point IP */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD entry_point; /* 26 API entry point to call, reused as mutex count */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD bp; /* 2a 16-bit stack frame chain */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD ip; /* 2c return address */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD cs; /* 2e */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync} STACK16FRAME;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync/* argument type flags for relay debugging */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncenum arg_types
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync{
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync ARG_NONE = 0, /* indicates end of arg list */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync ARG_WORD, /* unsigned word */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync ARG_SWORD, /* signed word */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync ARG_LONG, /* long or segmented pointer */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync ARG_PTR, /* linear pointer */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync ARG_STR, /* linear pointer to null-terminated string */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync ARG_SEGSTR, /* segmented pointer to null-terminated string */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync ARG_VARARG /* start of varargs */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync};
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define INVALID_HANDLE_VALUE16 ((HANDLE16) -1)
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define INFINITE16 0xFFFF
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsynctypedef struct {
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD dwOSVersionInfoSize;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD dwMajorVersion;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD dwMinorVersion;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD dwBuildNumber;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync DWORD dwPlatformId;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync CHAR szCSDVersion[128];
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync} OSVERSIONINFO16;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync/*
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync * NE Header FORMAT FLAGS
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_FFLAGS_SINGLEDATA 0x0001
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_FFLAGS_MULTIPLEDATA 0x0002
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_FFLAGS_WIN32 0x0010
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_FFLAGS_BUILTIN 0x0020 /* Wine built-in module */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_FFLAGS_FRAMEBUF 0x0100 /* OS/2 fullscreen app */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_FFLAGS_CONSOLE 0x0200 /* OS/2 console app */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_FFLAGS_GUI 0x0300 /* right, (NE_FFLAGS_FRAMEBUF | NE_FFLAGS_CONSOLE) */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_FFLAGS_SELFLOAD 0x0800
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_FFLAGS_LINKERROR 0x2000
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_FFLAGS_CALLWEP 0x4000
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_FFLAGS_LIBMODULE 0x8000
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync/*
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync * NE Header OPERATING SYSTEM
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_OSFLAGS_UNKNOWN 0x00
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_OSFLAGS_OS2 0x01
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_OSFLAGS_WINDOWS 0x02
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync/*
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync * NE Header ADDITIONAL FLAGS
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_AFLAGS_WIN2_PROTMODE 0x02
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_AFLAGS_WIN2_PROFONTS 0x04
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_AFLAGS_FASTLOAD 0x08
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync/*
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync * Segment Flags
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_SEGFLAGS_DATA 0x0001
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_SEGFLAGS_ALLOCATED 0x0002
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_SEGFLAGS_LOADED 0x0004
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_SEGFLAGS_ITERATED 0x0008
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_SEGFLAGS_MOVEABLE 0x0010
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_SEGFLAGS_SHAREABLE 0x0020
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_SEGFLAGS_PRELOAD 0x0040
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_SEGFLAGS_EXECUTEONLY 0x0080
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_SEGFLAGS_READONLY 0x0080
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_SEGFLAGS_RELOC_DATA 0x0100
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_SEGFLAGS_SELFLOAD 0x0800
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_SEGFLAGS_DISCARDABLE 0x1000
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_SEGFLAGS_32BIT 0x2000
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync/*
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync * Resource table structures.
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsynctypedef struct
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync{
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD offset;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD length;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD flags;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD id;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync HANDLE16 handle;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD usage;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync} NE_NAMEINFO;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsynctypedef struct
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync{
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD type_id; /* Type identifier */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync WORD count; /* Number of resources of this type */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync FARPROC16 resloader; /* SetResourceHandler() */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync /*
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync * Name info array.
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync} NE_TYPEINFO;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_RSCTYPE_CURSOR 0x8001
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_RSCTYPE_BITMAP 0x8002
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_RSCTYPE_ICON 0x8003
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_RSCTYPE_MENU 0x8004
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_RSCTYPE_DIALOG 0x8005
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_RSCTYPE_STRING 0x8006
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_RSCTYPE_FONTDIR 0x8007
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_RSCTYPE_FONT 0x8008
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_RSCTYPE_ACCELERATOR 0x8009
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_RSCTYPE_RCDATA 0x800a
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_RSCTYPE_GROUP_CURSOR 0x800c
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_RSCTYPE_GROUP_ICON 0x800e
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define NE_RSCTYPE_SCALABLE_FONTPATH 0x80cc /* Resource found in .fot files */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#include <poppack.h>
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define __AHSHIFT 3 /* don't change! */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define __AHINCR (1 << __AHSHIFT)
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync/* undocumented functions */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsynctypedef struct tagSYSLEVEL
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync{
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync CRITICAL_SECTION crst;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync INT level;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync} SYSLEVEL;
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync/* [GS]etProcessDword offsets */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define GPD_APP_COMPAT_FLAGS (-56)
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define GPD_LOAD_DONE_EVENT (-52)
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define GPD_HINSTANCE16 (-48)
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define GPD_WINDOWS_VERSION (-44)
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define GPD_THDB (-40)
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define GPD_PDB (-36)
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define GPD_STARTF_SHELLDATA (-32)
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define GPD_STARTF_HOTKEY (-28)
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define GPD_STARTF_SHOWWINDOW (-24)
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define GPD_STARTF_SIZE (-20)
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define GPD_STARTF_POSITION (-16)
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define GPD_STARTF_FLAGS (-12)
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define GPD_PARENT (- 8)
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define GPD_FLAGS (- 4)
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#define GPD_USERDATA ( 0)
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncWORD WINAPI AllocCStoDSAlias16(WORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncWORD WINAPI AllocDStoCSAlias16(WORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHGLOBAL16 WINAPI AllocResource16(HINSTANCE16,HRSRC16,DWORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncWORD WINAPI AllocSelector16(WORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncWORD WINAPI AllocSelectorArray16(WORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncVOID WINAPI DirectedYield16(HTASK16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHGLOBAL16 WINAPI DirectResAlloc16(HINSTANCE16,WORD,UINT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncvoid WINAPI DisposeLZ32Handle(HANDLE);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHANDLE WINAPI DosFileHandleToWin32Handle(HFILE);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHANDLE16 WINAPI FarGetOwner16(HGLOBAL16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncVOID WINAPI FarSetOwner16(HGLOBAL16,HANDLE16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncFARPROC16 WINAPI FileCDR16(FARPROC16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncWORD WINAPI FreeSelector16(WORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHANDLE16 WINAPI GetAtomHandle16(ATOM);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHANDLE16 WINAPI GetCodeHandle16(FARPROC16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI GetCodeInfo16(FARPROC16,SEGINFO*);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncDWORD WINAPI GetCurrentPDB16(void);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHTASK16 WINAPI GetCurrentTask(void);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncSEGPTR WINAPI GetDOSEnvironment16(void);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHMODULE16 WINAPI GetExePtr(HANDLE16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncWORD WINAPI GetExeVersion16(void);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncWORD WINAPI GetExpWinVer16(HMODULE16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHQUEUE16 WINAPI GetFastQueue16(void);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncDWORD WINAPI GetHeapSpaces16(HMODULE16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncINT16 WINAPI GetInstanceData16(HINSTANCE16,WORD,INT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI GetModuleName16(HINSTANCE16,LPSTR,INT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncINT16 WINAPI GetModuleUsage16(HINSTANCE16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncUINT16 WINAPI GetNumTasks16(void);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncVOID WINAPI GetpWin16Lock(SYSLEVEL**);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncSEGPTR WINAPI GetpWin16Lock16(void);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncDWORD WINAPI GetProcessDword(DWORD,INT);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncDWORD WINAPI GetSelectorLimit16(WORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncFARPROC16 WINAPI GetSetKernelDOSProc16(FARPROC16 DosProc);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHINSTANCE16 WINAPI GetTaskDS16(void);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHQUEUE16 WINAPI GetTaskQueue16(HTASK16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHQUEUE16 WINAPI GetThreadQueue16(DWORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncDWORD WINAPI GetWinFlags16(void);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncDWORD WINAPI GlobalDOSAlloc16(DWORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncWORD WINAPI GlobalDOSFree16(WORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncvoid WINAPI GlobalFreeAll16(HGLOBAL16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncDWORD WINAPI GlobalHandleNoRIP16(WORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncWORD WINAPI GlobalHandleToSel16(HGLOBAL16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHGLOBAL16 WINAPI GlobalLRUNewest16(HGLOBAL16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHGLOBAL16 WINAPI GlobalLRUOldest16(HGLOBAL16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncVOID WINAPI GlobalNotify16(FARPROC16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncWORD WINAPI GlobalPageLock16(HGLOBAL16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncWORD WINAPI GlobalPageUnlock16(HGLOBAL16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncSEGPTR WINAPI HasGPHandler16(SEGPTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI IsSharedSelector16(HANDLE16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI IsTask16(HTASK16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHTASK16 WINAPI IsTaskLocked16(void);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncVOID WINAPI LogError16(UINT16, LPVOID);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncVOID WINAPI LogParamError16(UINT16,FARPROC16,LPVOID);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncWORD WINAPI LocalCountFree16(void);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncWORD WINAPI LocalHandleDelta16(WORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncWORD WINAPI LocalHeapSize16(void);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI LocalInit16(HANDLE16,WORD,WORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncFARPROC16 WINAPI LocalNotify16(FARPROC16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHTASK16 WINAPI LockCurrentTask16(BOOL16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncDWORD WINAPI MapLS(LPCVOID);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncLPVOID WINAPI MapSL(DWORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncVOID WINAPI OldYield16(void);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncVOID WINAPI WIN32_OldYield16(void);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncVOID WINAPI PostEvent16(HTASK16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncWORD WINAPI PrestoChangoSelector16(WORD,WORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncVOID WINAPI ReleaseThunkLock(DWORD*);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncVOID WINAPI RestoreThunkLock(DWORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncWORD WINAPI SelectorAccessRights16(WORD,WORD,WORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncvoid WINAPI SetFastQueue16(DWORD,HQUEUE16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncVOID WINAPI SetPriority16(HTASK16,INT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncFARPROC16 WINAPI SetResourceHandler16(HINSTANCE16,LPCSTR,FARPROC16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncWORD WINAPI SetSelectorLimit16(WORD,DWORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHQUEUE16 WINAPI SetTaskQueue16(HTASK16,HQUEUE16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHQUEUE16 WINAPI SetThreadQueue16(DWORD,HQUEUE16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncVOID WINAPI SwitchStackTo16(WORD,WORD,WORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncVOID WINAPI UnMapLS(DWORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI WaitEvent16(HTASK16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHFILE WINAPI Win32HandleToDosFileHandle(HANDLE);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncVOID WINAPI WriteOutProfiles16(void);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncVOID WINAPI hmemcpy16(LPVOID,LPCVOID,LONG);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncVOID WINAPI _CheckNotSysLevel(SYSLEVEL *lock);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncDWORD WINAPI _ConfirmSysLevel(SYSLEVEL*);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncDWORD WINAPI _ConfirmWin16Lock(void);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncVOID WINAPI _CreateSysLevel(SYSLEVEL*,INT);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncVOID WINAPI _EnterSysLevel(SYSLEVEL*);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncVOID WINAPI _EnterWin16Lock(void);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncVOID WINAPI _LeaveSysLevel(SYSLEVEL*);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncVOID WINAPI _LeaveWin16Lock(void);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncINT16 WINAPI AccessResource16(HINSTANCE16,HRSRC16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncATOM WINAPI AddAtom16(LPCSTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncUINT16 WINAPI CompareString16(DWORD,DWORD,LPCSTR,DWORD,LPCSTR,DWORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI CreateDirectory16(LPCSTR,LPVOID);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI DefineHandleTable16(WORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncATOM WINAPI DeleteAtom16(ATOM);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI DeleteFile16(LPCSTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncvoid WINAPI ExitKernel16(void);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncvoid WINAPI FatalAppExit16(UINT16,LPCSTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncATOM WINAPI FindAtom16(LPCSTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI FindClose16(HANDLE16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncVOID WINAPI FreeLibrary16(HINSTANCE16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHANDLE16 WINAPI FindFirstFile16(LPCSTR,LPWIN32_FIND_DATAA);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI FindNextFile16(HANDLE16,LPWIN32_FIND_DATAA);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHRSRC16 WINAPI FindResource16(HINSTANCE16,LPCSTR,LPCSTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI FreeModule16(HMODULE16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncvoid WINAPI FreeProcInstance16(FARPROC16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI FreeResource16(HGLOBAL16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncUINT16 WINAPI GetAtomName16(ATOM,LPSTR,INT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncUINT16 WINAPI GetCurrentDirectory16(UINT16,LPSTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI GetDiskFreeSpace16(LPCSTR,LPDWORD,LPDWORD,LPDWORD,LPDWORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncUINT16 WINAPI GetDriveType16(UINT16); /* yes, the arguments differ */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncINT16 WINAPI GetLocaleInfo16(LCID,LCTYPE,LPSTR,INT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncDWORD WINAPI GetFileAttributes16(LPCSTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncDWORD WINAPI GetFreeSpace16(UINT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncINT16 WINAPI GetModuleFileName16(HINSTANCE16,LPSTR,INT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHMODULE16 WINAPI GetModuleHandle16(LPCSTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncUINT16 WINAPI GetPrivateProfileInt16(LPCSTR,LPCSTR,INT16,LPCSTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncINT16 WINAPI GetPrivateProfileSection16(LPCSTR,LPSTR,UINT16,LPCSTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncWORD WINAPI GetPrivateProfileSectionNames16(LPSTR,UINT16,LPCSTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncINT16 WINAPI GetPrivateProfileString16(LPCSTR,LPCSTR,LPCSTR,LPSTR,UINT16,LPCSTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI GetPrivateProfileStruct16(LPCSTR,LPCSTR,LPVOID,UINT16,LPCSTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncFARPROC16 WINAPI GetProcAddress16(HMODULE16,LPCSTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncUINT16 WINAPI GetProfileInt16(LPCSTR,LPCSTR,INT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncINT16 WINAPI GetProfileSection16(LPCSTR,LPSTR,UINT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncWORD WINAPI GetProfileSectionNames16(LPSTR,WORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncINT16 WINAPI GetProfileString16(LPCSTR,LPCSTR,LPCSTR,LPSTR,UINT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncDWORD WINAPI GetSelectorBase(WORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI GetStringType16(LCID,DWORD,LPCSTR,INT16,LPWORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncUINT16 WINAPI GetSystemDirectory16(LPSTR,UINT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncUINT16 WINAPI GetTempFileName16(BYTE,LPCSTR,UINT16,LPSTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncDWORD WINAPI GetVersion16(void);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI GetVersionEx16(OSVERSIONINFO16*);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI GetWinDebugInfo16(LPWINDEBUGINFO16,UINT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncUINT16 WINAPI GetWindowsDirectory16(LPSTR,UINT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHGLOBAL16 WINAPI GlobalAlloc16(UINT16,DWORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncDWORD WINAPI GlobalCompact16(DWORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncLPVOID WINAPI GlobalLock16(HGLOBAL16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncWORD WINAPI GlobalFix16(HGLOBAL16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncUINT16 WINAPI GlobalFlags16(HGLOBAL16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHGLOBAL16 WINAPI GlobalFree16(HGLOBAL16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncDWORD WINAPI GlobalHandle16(WORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHGLOBAL16 WINAPI GlobalReAlloc16(HGLOBAL16,DWORD,UINT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncDWORD WINAPI GlobalSize16(HGLOBAL16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncVOID WINAPI GlobalUnfix16(HGLOBAL16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI GlobalUnlock16(HGLOBAL16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI GlobalUnWire16(HGLOBAL16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncSEGPTR WINAPI GlobalWire16(HGLOBAL16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncWORD WINAPI InitAtomTable16(WORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncvoid WINAPI InitTask16(CONTEXT*);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI IsBadCodePtr16(SEGPTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI IsBadHugeReadPtr16(SEGPTR,DWORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI IsBadHugeWritePtr16(SEGPTR,DWORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI IsBadReadPtr16(SEGPTR,UINT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI IsBadStringPtr16(SEGPTR,UINT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI IsBadWritePtr16(SEGPTR,UINT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI IsDBCSLeadByte16(BYTE);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHINSTANCE16 WINAPI LoadLibrary16(LPCSTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHINSTANCE16 WINAPI LoadModule16(LPCSTR,LPVOID);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHGLOBAL16 WINAPI LoadResource16(HINSTANCE16,HRSRC16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHLOCAL16 WINAPI LocalAlloc16(UINT16,WORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncUINT16 WINAPI LocalCompact16(UINT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncUINT16 WINAPI LocalFlags16(HLOCAL16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHLOCAL16 WINAPI LocalFree16(HLOCAL16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHLOCAL16 WINAPI LocalHandle16(WORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncSEGPTR WINAPI LocalLock16(HLOCAL16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHLOCAL16 WINAPI LocalReAlloc16(HLOCAL16,WORD,UINT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncUINT16 WINAPI LocalShrink16(HGLOBAL16,UINT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncUINT16 WINAPI LocalSize16(HLOCAL16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI LocalUnlock16(HLOCAL16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncLPVOID WINAPI LockResource16(HGLOBAL16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHGLOBAL16 WINAPI LockSegment16(HGLOBAL16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncFARPROC16 WINAPI MakeProcInstance16(FARPROC16,HANDLE16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHFILE16 WINAPI OpenFile16(LPCSTR,OFSTRUCT*,UINT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncDWORD WINAPI RegCloseKey16(HKEY);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncDWORD WINAPI RegCreateKey16(HKEY,LPCSTR,PHKEY);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncDWORD WINAPI RegDeleteKey16(HKEY,LPCSTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncDWORD WINAPI RegDeleteValue16(HKEY,LPSTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncDWORD WINAPI RegEnumKey16(HKEY,DWORD,LPSTR,DWORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncDWORD WINAPI RegEnumValue16(HKEY,DWORD,LPSTR,LPDWORD,LPDWORD,LPDWORD,LPBYTE,LPDWORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncDWORD WINAPI RegOpenKey16(HKEY,LPCSTR,PHKEY);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncDWORD WINAPI RegQueryValue16(HKEY,LPCSTR,LPSTR,LPDWORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncDWORD WINAPI RegQueryValueEx16(HKEY,LPCSTR,LPDWORD,LPDWORD,LPBYTE,LPDWORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncDWORD WINAPI RegSetValue16(HKEY,LPCSTR,DWORD,LPCSTR,DWORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncDWORD WINAPI RegSetValueEx16(HKEY,LPCSTR,DWORD,DWORD,const BYTE*,DWORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI RemoveDirectory16(LPCSTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI SetCurrentDirectory16(LPCSTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncUINT16 WINAPI SetErrorMode16(UINT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI SetFileAttributes16(LPCSTR,DWORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncUINT16 WINAPI SetHandleCount16(UINT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncWORD WINAPI SetSelectorBase(WORD,DWORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncLONG WINAPI SetSwapAreaSize16(WORD);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI SetWinDebugInfo16(LPWINDEBUGINFO16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncDWORD WINAPI SizeofResource16(HMODULE16,HRSRC16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncvoid WINAPI UnlockSegment16(HGLOBAL16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI WritePrivateProfileString16(LPCSTR,LPCSTR,LPCSTR,LPCSTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI WriteProfileString16(LPCSTR,LPCSTR,LPCSTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync/* Yield16 will only be available from kernel module, use WOWYield instead */
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncVOID WINAPI Yield16(void);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncSEGPTR WINAPI lstrcat16(SEGPTR,LPCSTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncSEGPTR WINAPI lstrcatn16(SEGPTR,LPCSTR,INT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncSEGPTR WINAPI lstrcpy16(SEGPTR,LPCSTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncSEGPTR WINAPI lstrcpyn16(SEGPTR,LPCSTR,INT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncINT16 WINAPI lstrlen16(LPCSTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHINSTANCE16 WINAPI WinExec16(LPCSTR,UINT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncLONG WINAPI _hread16(HFILE16,LPVOID,LONG);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncLONG WINAPI _hwrite16(HFILE16,LPCSTR,LONG);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHFILE16 WINAPI _lcreat16(LPCSTR,INT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHFILE16 WINAPI _lclose16(HFILE16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncLONG WINAPI _llseek16(HFILE16,LONG,INT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncHFILE16 WINAPI _lopen16(LPCSTR,INT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncUINT16 WINAPI _lread16(HFILE16,LPVOID,UINT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncUINT16 WINAPI _lwrite16(HFILE16,LPCSTR,UINT16);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI WritePrivateProfileSection16(LPCSTR,LPCSTR,LPCSTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI WritePrivateProfileStruct16(LPCSTR,LPCSTR,LPVOID,UINT16,LPCSTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsyncBOOL16 WINAPI WriteProfileSection16(LPCSTR,LPCSTR);
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync
3194da424708abdd288b28d96892b3a5f3f7df0bvboxsync#endif /* __WINE_WINE_WINBASE16_H */