Commit 8e5d3042 authored by Alexandre Julliard's avatar Alexandre Julliard

ntdll: Move DbgUiIssueRemoteBreakin() to the Unix library.

parent 245efd04
...@@ -1788,16 +1788,5 @@ void WINAPI DbgUiRemoteBreakin( void *arg ) ...@@ -1788,16 +1788,5 @@ void WINAPI DbgUiRemoteBreakin( void *arg )
*/ */
NTSTATUS WINAPI DbgUiIssueRemoteBreakin( HANDLE process ) NTSTATUS WINAPI DbgUiIssueRemoteBreakin( HANDLE process )
{ {
apc_call_t call; return unix_funcs->DbgUiIssueRemoteBreakin( process );
apc_result_t result;
NTSTATUS status;
TRACE( "(%p)\n", process );
memset( &call, 0, sizeof(call) );
call.type = APC_BREAK_PROCESS;
status = unix_funcs->server_queue_process_apc( process, &call, &result );
if (status) return status;
return result.break_process.status;
} }
...@@ -1036,6 +1036,7 @@ static struct unix_funcs unix_funcs = ...@@ -1036,6 +1036,7 @@ static struct unix_funcs unix_funcs =
NtWaitForSingleObject, NtWaitForSingleObject,
NtWriteVirtualMemory, NtWriteVirtualMemory,
NtYieldExecution, NtYieldExecution,
DbgUiIssueRemoteBreakin,
get_main_args, get_main_args,
get_paths, get_paths,
get_dll_path, get_dll_path,
...@@ -1072,7 +1073,6 @@ static struct unix_funcs unix_funcs = ...@@ -1072,7 +1073,6 @@ static struct unix_funcs unix_funcs =
wine_server_call, wine_server_call,
server_select, server_select,
server_wait, server_wait,
server_queue_process_apc,
server_send_fd, server_send_fd,
server_get_unix_fd, server_get_unix_fd,
server_fd_to_handle, server_fd_to_handle,
......
...@@ -727,7 +727,7 @@ unsigned int CDECL server_wait( const select_op_t *select_op, data_size_t size, ...@@ -727,7 +727,7 @@ unsigned int CDECL server_wait( const select_op_t *select_op, data_size_t size,
/*********************************************************************** /***********************************************************************
* server_queue_process_apc * server_queue_process_apc
*/ */
unsigned int CDECL server_queue_process_apc( HANDLE process, const apc_call_t *call, apc_result_t *result ) unsigned int server_queue_process_apc( HANDLE process, const apc_call_t *call, apc_result_t *result )
{ {
for (;;) for (;;)
{ {
...@@ -1556,6 +1556,23 @@ size_t server_init_thread( void *entry_point, BOOL *suspend ) ...@@ -1556,6 +1556,23 @@ size_t server_init_thread( void *entry_point, BOOL *suspend )
} }
/***********************************************************************
* DbgUiIssueRemoteBreakin
*/
NTSTATUS WINAPI DbgUiIssueRemoteBreakin( HANDLE process )
{
apc_call_t call;
apc_result_t result;
NTSTATUS status;
memset( &call, 0, sizeof(call) );
call.type = APC_BREAK_PROCESS;
status = server_queue_process_apc( process, &call, &result );
if (status) return status;
return result.break_process.status;
}
/****************************************************************************** /******************************************************************************
* NtDuplicateObject * NtDuplicateObject
*/ */
......
...@@ -83,7 +83,6 @@ extern unsigned int CDECL server_select( const select_op_t *select_op, data_size ...@@ -83,7 +83,6 @@ extern unsigned int CDECL server_select( const select_op_t *select_op, data_size
user_apc_t *user_apc ) DECLSPEC_HIDDEN; user_apc_t *user_apc ) DECLSPEC_HIDDEN;
extern unsigned int CDECL server_wait( const select_op_t *select_op, data_size_t size, UINT flags, extern unsigned int CDECL server_wait( const select_op_t *select_op, data_size_t size, UINT flags,
const LARGE_INTEGER *timeout ) DECLSPEC_HIDDEN; const LARGE_INTEGER *timeout ) DECLSPEC_HIDDEN;
extern unsigned int CDECL server_queue_process_apc( HANDLE process, const apc_call_t *call, apc_result_t *result ) DECLSPEC_HIDDEN;
extern void CDECL server_send_fd( int fd ) DECLSPEC_HIDDEN; extern void CDECL server_send_fd( int fd ) DECLSPEC_HIDDEN;
extern int CDECL server_get_unix_fd( HANDLE handle, unsigned int wanted_access, int *unix_fd, extern int CDECL server_get_unix_fd( HANDLE handle, unsigned int wanted_access, int *unix_fd,
int *needs_close, enum server_fd_type *type, int *needs_close, enum server_fd_type *type,
...@@ -127,6 +126,8 @@ extern NTSTATUS context_from_server( CONTEXT *to, const context_t *from ) DECLSP ...@@ -127,6 +126,8 @@ extern NTSTATUS context_from_server( CONTEXT *to, const context_t *from ) DECLSP
extern void wait_suspend( CONTEXT *context ) DECLSPEC_HIDDEN; extern void wait_suspend( CONTEXT *context ) DECLSPEC_HIDDEN;
extern NTSTATUS set_thread_context( HANDLE handle, const context_t *context, BOOL *self ) DECLSPEC_HIDDEN; extern NTSTATUS set_thread_context( HANDLE handle, const context_t *context, BOOL *self ) DECLSPEC_HIDDEN;
extern NTSTATUS get_thread_context( HANDLE handle, context_t *context, unsigned int flags, BOOL *self ) DECLSPEC_HIDDEN; extern NTSTATUS get_thread_context( HANDLE handle, context_t *context, unsigned int flags, BOOL *self ) DECLSPEC_HIDDEN;
extern unsigned int server_queue_process_apc( HANDLE process, const apc_call_t *call,
apc_result_t *result ) DECLSPEC_HIDDEN;
extern NTSTATUS alloc_object_attributes( const OBJECT_ATTRIBUTES *attr, struct object_attributes **ret, extern NTSTATUS alloc_object_attributes( const OBJECT_ATTRIBUTES *attr, struct object_attributes **ret,
data_size_t *ret_len ) DECLSPEC_HIDDEN; data_size_t *ret_len ) DECLSPEC_HIDDEN;
......
...@@ -28,7 +28,7 @@ struct ldt_copy; ...@@ -28,7 +28,7 @@ struct ldt_copy;
struct msghdr; struct msghdr;
/* increment this when you change the function table */ /* increment this when you change the function table */
#define NTDLL_UNIXLIB_VERSION 29 #define NTDLL_UNIXLIB_VERSION 30
struct unix_funcs struct unix_funcs
{ {
...@@ -131,6 +131,9 @@ struct unix_funcs ...@@ -131,6 +131,9 @@ struct unix_funcs
SIZE_T size, SIZE_T *bytes_written ); SIZE_T size, SIZE_T *bytes_written );
NTSTATUS (WINAPI *NtYieldExecution)(void); NTSTATUS (WINAPI *NtYieldExecution)(void);
/* other Win32 API functions */
NTSTATUS (WINAPI *DbgUiIssueRemoteBreakin)( HANDLE process );
/* environment functions */ /* environment functions */
void (CDECL *get_main_args)( int *argc, char **argv[], char **envp[] ); void (CDECL *get_main_args)( int *argc, char **argv[], char **envp[] );
void (CDECL *get_paths)( const char **builddir, const char **datadir, const char **configdir ); void (CDECL *get_paths)( const char **builddir, const char **datadir, const char **configdir );
...@@ -183,7 +186,6 @@ struct unix_funcs ...@@ -183,7 +186,6 @@ struct unix_funcs
user_apc_t *user_apc ); user_apc_t *user_apc );
unsigned int (CDECL *server_wait)( const select_op_t *select_op, data_size_t size, UINT flags, unsigned int (CDECL *server_wait)( const select_op_t *select_op, data_size_t size, UINT flags,
const LARGE_INTEGER *timeout ); const LARGE_INTEGER *timeout );
unsigned int (CDECL *server_queue_process_apc)( HANDLE process, const apc_call_t *call, apc_result_t *result );
void (CDECL *server_send_fd)( int fd ); void (CDECL *server_send_fd)( int fd );
int (CDECL *server_get_unix_fd)( HANDLE handle, unsigned int wanted_access, int *unix_fd, int (CDECL *server_get_unix_fd)( HANDLE handle, unsigned int wanted_access, int *unix_fd,
int *needs_close, enum server_fd_type *type, unsigned int *options ); int *needs_close, enum server_fd_type *type, unsigned int *options );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment