ntdll: Rename NTDLL_wait_for_multiple_objects to server_select since it's more generic now.
This commit is contained in:
parent
947e337480
commit
a56ffb6326
|
@ -235,7 +235,7 @@ static inline NTSTATUS wait_semaphore( RTL_CRITICAL_SECTION *crit, int timeout )
|
|||
time.QuadPart = timeout * (LONGLONG)-10000000;
|
||||
select_op.wait.op = SELECT_WAIT;
|
||||
select_op.wait.handles[0] = wine_server_obj_handle( sem );
|
||||
ret = NTDLL_wait_for_multiple_objects( &select_op, offsetof( select_op_t, wait.handles[1] ), 0, &time );
|
||||
ret = server_select( &select_op, offsetof( select_op_t, wait.handles[1] ), 0, &time );
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
|
|
|
@ -81,7 +81,7 @@ void wait_suspend( CONTEXT *context )
|
|||
|
||||
/* wait with 0 timeout, will only return once the thread is no longer suspended */
|
||||
timeout.QuadPart = 0;
|
||||
NTDLL_wait_for_multiple_objects( NULL, 0, SELECT_INTERRUPTIBLE, &timeout );
|
||||
server_select( NULL, 0, SELECT_INTERRUPTIBLE, &timeout );
|
||||
|
||||
/* retrieve the new context */
|
||||
SERVER_START_REQ( get_suspend_context )
|
||||
|
@ -134,7 +134,7 @@ NTSTATUS send_debug_event( EXCEPTION_RECORD *rec, int first_chance, CONTEXT *con
|
|||
|
||||
select_op.wait.op = SELECT_WAIT;
|
||||
select_op.wait.handles[0] = handle;
|
||||
NTDLL_wait_for_multiple_objects( &select_op, offsetof( select_op_t, wait.handles[1] ), SELECT_INTERRUPTIBLE, NULL );
|
||||
server_select( &select_op, offsetof( select_op_t, wait.handles[1] ), SELECT_INTERRUPTIBLE, NULL );
|
||||
|
||||
SERVER_START_REQ( get_exception_status )
|
||||
{
|
||||
|
|
|
@ -63,8 +63,8 @@ extern LPCSTR debugstr_us( const UNICODE_STRING *str ) DECLSPEC_HIDDEN;
|
|||
extern LPCSTR debugstr_ObjectAttributes(const OBJECT_ATTRIBUTES *oa) DECLSPEC_HIDDEN;
|
||||
|
||||
extern NTSTATUS NTDLL_queue_process_apc( HANDLE process, const apc_call_t *call, apc_result_t *result ) DECLSPEC_HIDDEN;
|
||||
extern NTSTATUS NTDLL_wait_for_multiple_objects( const select_op_t *select_op, data_size_t size,
|
||||
UINT flags, const LARGE_INTEGER *timeout ) DECLSPEC_HIDDEN;
|
||||
extern NTSTATUS server_select( const select_op_t *select_op, data_size_t size,
|
||||
UINT flags, const LARGE_INTEGER *timeout ) DECLSPEC_HIDDEN;
|
||||
|
||||
/* init routines */
|
||||
extern NTSTATUS signal_alloc_thread( TEB **teb ) DECLSPEC_HIDDEN;
|
||||
|
|
|
@ -1102,12 +1102,10 @@ NTSTATUS NTDLL_queue_process_apc( HANDLE process, const apc_call_t *call, apc_re
|
|||
|
||||
|
||||
/***********************************************************************
|
||||
* NTDLL_wait_for_multiple_objects
|
||||
*
|
||||
* Implementation of NtWaitForMultipleObjects
|
||||
* server_select
|
||||
*/
|
||||
NTSTATUS NTDLL_wait_for_multiple_objects( const select_op_t *select_op, data_size_t size, UINT flags,
|
||||
const LARGE_INTEGER *timeout )
|
||||
NTSTATUS server_select( const select_op_t *select_op, data_size_t size, UINT flags,
|
||||
const LARGE_INTEGER *timeout )
|
||||
{
|
||||
NTSTATUS ret;
|
||||
int cookie;
|
||||
|
@ -1178,7 +1176,7 @@ NTSTATUS WINAPI NtWaitForMultipleObjects( DWORD count, const HANDLE *handles,
|
|||
if (alertable) flags |= SELECT_ALERTABLE;
|
||||
select_op.wait.op = wait_all ? SELECT_WAIT_ALL : SELECT_WAIT;
|
||||
for (i = 0; i < count; i++) select_op.wait.handles[i] = wine_server_obj_handle( handles[i] );
|
||||
return NTDLL_wait_for_multiple_objects( &select_op, offsetof( select_op_t, wait.handles[count] ), flags, timeout );
|
||||
return server_select( &select_op, offsetof( select_op_t, wait.handles[count] ), flags, timeout );
|
||||
}
|
||||
|
||||
|
||||
|
@ -1206,7 +1204,7 @@ NTSTATUS WINAPI NtSignalAndWaitForSingleObject( HANDLE hSignalObject, HANDLE hWa
|
|||
select_op.signal_and_wait.op = SELECT_SIGNAL_AND_WAIT;
|
||||
select_op.signal_and_wait.wait = wine_server_obj_handle( hWaitObject );
|
||||
select_op.signal_and_wait.signal = wine_server_obj_handle( hSignalObject );
|
||||
return NTDLL_wait_for_multiple_objects( &select_op, sizeof(select_op.signal_and_wait), flags, timeout );
|
||||
return server_select( &select_op, sizeof(select_op.signal_and_wait), flags, timeout );
|
||||
}
|
||||
|
||||
|
||||
|
@ -1231,8 +1229,7 @@ NTSTATUS WINAPI NtDelayExecution( BOOLEAN alertable, const LARGE_INTEGER *timeou
|
|||
{
|
||||
/* if alertable, we need to query the server */
|
||||
if (alertable)
|
||||
return NTDLL_wait_for_multiple_objects( NULL, 0, SELECT_INTERRUPTIBLE | SELECT_ALERTABLE,
|
||||
timeout );
|
||||
return server_select( NULL, 0, SELECT_INTERRUPTIBLE | SELECT_ALERTABLE, timeout );
|
||||
|
||||
if (!timeout || timeout->QuadPart == TIMEOUT_INFINITE) /* sleep forever */
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue