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
99e1e810
Commit
99e1e810
authored
Jul 26, 2000
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Return the proper error code when a 16-bit task failed to start
(thanks to Peter Ganten).
parent
1f5e4314
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
2 deletions
+11
-2
module.c
loader/ne/module.c
+11
-2
No files found.
loader/ne/module.c
View file @
99e1e810
...
...
@@ -1004,6 +1004,7 @@ HINSTANCE16 WINAPI LoadModule16( LPCSTR name, LPVOID paramBlock )
TDB
*
pTask
;
LPSTR
cmdline
;
WORD
cmdShow
;
HANDLE
hThread
;
int
socket
;
/* Load module */
...
...
@@ -1049,7 +1050,7 @@ HINSTANCE16 WINAPI LoadModule16( LPCSTR name, LPVOID paramBlock )
req
->
suspend
=
0
;
req
->
inherit
=
0
;
if
(
server_call_fd
(
REQ_NEW_THREAD
,
-
1
,
&
socket
))
return
0
;
CloseHandle
(
req
->
handle
)
;
hThread
=
req
->
handle
;
if
(
!
(
teb
=
THREAD_Create
(
socket
,
0
,
FALSE
)))
goto
error
;
teb
->
startup
=
NE_InitProcess
;
...
...
@@ -1072,7 +1073,14 @@ HINSTANCE16 WINAPI LoadModule16( LPCSTR name, LPVOID paramBlock )
do
{
DirectedYield16
(
hTask
);
if
(
!
IsTask16
(
hTask
))
break
;
if
(
!
IsTask16
(
hTask
))
/* thread has died */
{
DWORD
exit_code
;
WaitForSingleObject
(
hThread
,
INFINITE
);
GetExitCodeThread
(
hThread
,
&
exit_code
);
CloseHandle
(
hThread
);
return
exit_code
;
}
if
(
!
(
pTask
=
(
TDB
*
)
GlobalLock16
(
hTask
)))
break
;
instance
=
pTask
->
hInstance
;
GlobalUnlock16
(
hTask
);
...
...
@@ -1083,6 +1091,7 @@ HINSTANCE16 WINAPI LoadModule16( LPCSTR name, LPVOID paramBlock )
error:
/* FIXME: free TEB and task */
close
(
socket
);
CloseHandle
(
hThread
);
return
0
;
/* FIXME */
}
...
...
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