ntdll: Implement NtContinue() in the Unix library.

Signed-off-by: Alexandre Julliard <julliard@winehq.org>
feature/deterministic
Alexandre Julliard 2020-06-06 15:16:38 +02:00
parent e561ce4b92
commit 95e2d05e5d
5 changed files with 26 additions and 3 deletions

View File

@ -157,7 +157,7 @@
@ stdcall NtCompleteConnectPort(ptr)
# @ stub NtCompressKey
@ stdcall NtConnectPort(ptr ptr ptr ptr ptr ptr ptr ptr)
@ stub NtContinue
@ stdcall NtContinue(ptr long)
# @ stub NtCreateDebugObject
@ stdcall NtCreateDirectoryObject(ptr long ptr)
@ stdcall NtCreateEvent(ptr long ptr long long)
@ -1145,7 +1145,7 @@
@ stdcall -private ZwCompleteConnectPort(ptr) NtCompleteConnectPort
# @ stub ZwCompressKey
@ stdcall -private ZwConnectPort(ptr ptr ptr ptr ptr ptr ptr ptr) NtConnectPort
@ stub ZwContinue
@ stdcall -private ZwContinue(ptr long) NtContinue
# @ stub ZwCreateDebugObject
@ stdcall -private ZwCreateDirectoryObject(ptr long ptr) NtCreateDirectoryObject
@ stdcall -private ZwCreateEvent(ptr long ptr long long) NtCreateEvent

View File

@ -602,6 +602,15 @@ NTSTATUS get_thread_context( HANDLE handle, context_t *context, unsigned int fla
}
/***********************************************************************
* NtContinue (NTDLL.@)
*/
NTSTATUS WINAPI NtContinue( CONTEXT *context, BOOLEAN alertable )
{
return unix_funcs->NtContinue( context, alertable );
}
/***********************************************************************
* NtSetContextThread (NTDLL.@)
* ZwSetContextThread (NTDLL.@)

View File

@ -988,6 +988,7 @@ static struct unix_funcs unix_funcs =
NtCancelTimer,
NtClearEvent,
NtClose,
NtContinue,
NtCreateEvent,
NtCreateKeyedEvent,
NtCreateMutant,

View File

@ -470,6 +470,18 @@ NTSTATUS WINAPI NtRaiseException( EXCEPTION_RECORD *rec, CONTEXT *context, BOOL
}
/***********************************************************************
* NtContinue (NTDLL.@)
*/
NTSTATUS WINAPI NtContinue( CONTEXT *context, BOOLEAN alertable )
{
static const LARGE_INTEGER zero_timeout;
if (alertable) server_wait( NULL, 0, SELECT_INTERRUPTIBLE | SELECT_ALERTABLE, &zero_timeout );
return NtSetContextThread( GetCurrentThread(), context );
}
/***********************************************************************
* set_thread_context
*/

View File

@ -28,7 +28,7 @@ struct ldt_copy;
struct msghdr;
/* increment this when you change the function table */
#define NTDLL_UNIXLIB_VERSION 31
#define NTDLL_UNIXLIB_VERSION 32
struct unix_funcs
{
@ -39,6 +39,7 @@ struct unix_funcs
NTSTATUS (WINAPI *NtCancelTimer)( HANDLE handle, BOOLEAN *state );
NTSTATUS (WINAPI *NtClearEvent)( HANDLE handle );
NTSTATUS (WINAPI *NtClose)( HANDLE handle );
NTSTATUS (WINAPI *NtContinue)( CONTEXT *context, BOOLEAN alertable );
NTSTATUS (WINAPI *NtCreateEvent)( HANDLE *handle, ACCESS_MASK access,
const OBJECT_ATTRIBUTES *attr, EVENT_TYPE type, BOOLEAN state );
NTSTATUS (WINAPI *NtCreateKeyedEvent)( HANDLE *handle, ACCESS_MASK access,