Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
e8753b4b
Commit
e8753b4b
authored
Jun 11, 2021
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ntdll: Allow the dispatcher functions to return to the caller.
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
b564414e
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
13 additions
and
13 deletions
+13
-13
server.c
dlls/ntdll/unix/server.c
+5
-5
thread.c
dlls/ntdll/unix/thread.c
+1
-1
unix_private.h
dlls/ntdll/unix/unix_private.h
+7
-7
No files found.
dlls/ntdll/unix/server.c
View file @
e8753b4b
...
...
@@ -354,10 +354,10 @@ static int wait_select_reply( void *cookie )
/***********************************************************************
* invoke_user_apc
*/
static
void
invoke_user_apc
(
CONTEXT
*
context
,
const
user_apc_t
*
apc
,
NTSTATUS
status
)
static
NTSTATUS
invoke_user_apc
(
CONTEXT
*
context
,
const
user_apc_t
*
apc
,
NTSTATUS
status
)
{
call_user_apc_dispatcher
(
context
,
apc
->
args
[
0
],
apc
->
args
[
1
],
apc
->
args
[
2
],
wine_server_get_ptr
(
apc
->
func
),
pKiUserApcDispatcher
,
status
);
return
call_user_apc_dispatcher
(
context
,
apc
->
args
[
0
],
apc
->
args
[
1
],
apc
->
args
[
2
],
wine_server_get_ptr
(
apc
->
func
),
pKiUserApcDispatcher
,
status
);
}
...
...
@@ -675,7 +675,7 @@ unsigned int server_wait( const select_op_t *select_op, data_size_t size, UINT f
}
ret
=
server_select
(
select_op
,
size
,
flags
,
abs_timeout
,
NULL
,
NULL
,
&
apc
);
if
(
ret
==
STATUS_USER_APC
)
invoke_user_apc
(
NULL
,
&
apc
,
ret
);
if
(
ret
==
STATUS_USER_APC
)
return
invoke_user_apc
(
NULL
,
&
apc
,
ret
);
/* A test on Windows 2000 shows that Windows always yields during
a wait, but a wait that is hit by an event gets a priority
...
...
@@ -696,7 +696,7 @@ NTSTATUS WINAPI NtContinue( CONTEXT *context, BOOLEAN alertable )
if
(
alertable
)
{
status
=
server_select
(
NULL
,
0
,
SELECT_INTERRUPTIBLE
|
SELECT_ALERTABLE
,
0
,
NULL
,
NULL
,
&
apc
);
if
(
status
==
STATUS_USER_APC
)
invoke_user_apc
(
context
,
&
apc
,
status
);
if
(
status
==
STATUS_USER_APC
)
return
invoke_user_apc
(
context
,
&
apc
,
status
);
}
status
=
NtSetContextThread
(
GetCurrentThread
(),
context
);
if
(
!
status
&&
(
context
->
ContextFlags
&
CONTEXT_INTEGER
)
==
CONTEXT_INTEGER
)
...
...
dlls/ntdll/unix/thread.c
View file @
e8753b4b
...
...
@@ -1163,7 +1163,7 @@ NTSTATUS WINAPI NtRaiseException( EXCEPTION_RECORD *rec, CONTEXT *context, BOOL
if
(
status
==
DBG_CONTINUE
||
status
==
DBG_EXCEPTION_HANDLED
)
return
NtContinue
(
context
,
FALSE
);
if
(
first_chance
)
call_user_exception_dispatcher
(
rec
,
context
,
pKiUserExceptionDispatcher
);
if
(
first_chance
)
return
call_user_exception_dispatcher
(
rec
,
context
,
pKiUserExceptionDispatcher
);
if
(
rec
->
ExceptionFlags
&
EH_STACK_INVALID
)
ERR_
(
seh
)(
"Exception frame is not in stack limits => unable to dispatch exception.
\n
"
);
...
...
dlls/ntdll/unix/unix_private.h
View file @
e8753b4b
...
...
@@ -284,13 +284,13 @@ extern void add_completion( HANDLE handle, ULONG_PTR value, NTSTATUS status, ULO
extern
void
dbg_init
(
void
)
DECLSPEC_HIDDEN
;
extern
void
WINAPI
DECLSPEC_NORETURN
call_user_apc_dispatcher
(
CONTEXT
*
context_ptr
,
ULONG_PTR
arg1
,
ULONG_PTR
arg2
,
ULONG_PTR
arg3
,
PNTAPCFUNC
func
,
void
(
WINAPI
*
dispatcher
)(
CONTEXT
*
,
ULONG_PTR
,
ULONG_PTR
,
ULONG_PTR
,
PNTAPCFUNC
),
NTSTATUS
status
)
DECLSPEC_HIDDEN
;
extern
void
WINAPI
DECLSPEC_NORETURN
call_user_exception_dispatcher
(
EXCEPTION_RECORD
*
rec
,
CONTEXT
*
context
,
NTSTATUS
(
WINAPI
*
dispatcher
)(
EXCEPTION_RECORD
*
,
CONTEXT
*
)
)
DECLSPEC_HIDDEN
;
extern
NTSTATUS
WINAPI
call_user_apc_dispatcher
(
CONTEXT
*
context_ptr
,
ULONG_PTR
arg1
,
ULONG_PTR
arg2
,
ULONG_PTR
arg3
,
PNTAPCFUNC
func
,
void
(
WINAPI
*
dispatcher
)(
CONTEXT
*
,
ULONG_PTR
,
ULONG_PTR
,
ULONG_PTR
,
PNTAPCFUNC
),
NTSTATUS
status
)
DECLSPEC_HIDDEN
;
extern
NTSTATUS
WINAPI
call_user_exception_dispatcher
(
EXCEPTION_RECORD
*
rec
,
CONTEXT
*
context
,
NTSTATUS
(
WINAPI
*
dispatcher
)(
EXCEPTION_RECORD
*
,
CONTEXT
*
)
)
DECLSPEC_HIDDEN
;
extern
void
WINAPI
call_raise_user_exception_dispatcher
(
NTSTATUS
(
WINAPI
*
dispatcher
)(
void
)
)
DECLSPEC_HIDDEN
;
#define IMAGE_DLLCHARACTERISTICS_PREFER_NATIVE 0x0010
/* Wine extension */
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment