Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
869b0442
Commit
869b0442
authored
Apr 01, 2002
by
Jukka Heinonen
Committed by
Alexandre Julliard
Apr 01, 2002
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Routine DOSVM_Wait now wakes up if new events are queued and it
returns if it processed any queued events.
parent
96328b37
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
4 deletions
+15
-4
dosvm.c
dlls/winedos/dosvm.c
+15
-4
No files found.
dlls/winedos/dosvm.c
View file @
869b0442
...
...
@@ -85,6 +85,7 @@ typedef struct _DOSEVENT {
static
CRITICAL_SECTION
qcrit
=
CRITICAL_SECTION_INIT
(
"DOSVM"
);
static
struct
_DOSEVENT
*
pending_event
,
*
current_event
;
static
int
sig_sent
;
static
HANDLE
event_notifier
;
static
CONTEXT86
*
current_context
;
static
int
DOSVM_SimulateInt
(
int
vect
,
CONTEXT86
*
context
,
BOOL
inwine
)
...
...
@@ -210,6 +211,10 @@ void WINAPI DOSVM_QueueEvent( INT irq, INT priority, DOSRELAY relay, LPVOID data
}
else
{
TRACE
(
"new event queued (time=%ld)
\n
"
,
GetTickCount
());
}
/* Wake up DOSVM_Wait so that it can serve pending events. */
SetEvent
(
event_notifier
);
LeaveCriticalSection
(
&
qcrit
);
}
else
{
/* DOS subsystem not running */
...
...
@@ -299,13 +304,14 @@ void WINAPI DOSVM_Wait( INT read_pipe, HANDLE hObject )
{
MSG
msg
;
DWORD
waitret
;
HANDLE
objs
[
2
];
HANDLE
objs
[
3
];
int
objc
;
BOOL
got_msg
=
FALSE
;
objs
[
0
]
=
GetStdHandle
(
STD_INPUT_HANDLE
);
objs
[
1
]
=
hObject
;
objc
=
hObject
?
2
:
1
;
objs
[
1
]
=
event_notifier
;
objs
[
2
]
=
hObject
;
objc
=
hObject
?
3
:
2
;
do
{
/* check for messages (waste time before the response check below) */
if
(
PeekMessageA
)
...
...
@@ -335,6 +341,7 @@ chk_console_input:
IF_SET
(
&
context
);
SET_PEND
(
&
context
);
DOSVM_SendQueuedEvents
(
&
context
);
got_msg
=
TRUE
;
}
if
(
got_msg
)
break
;
}
else
{
...
...
@@ -356,7 +363,7 @@ chk_console_input:
ERR_
(
module
)(
"dosvm wait error=%ld
\n
"
,
GetLastError
());
}
if
((
read_pipe
!=
-
1
)
&&
hObject
)
{
if
(
waitret
==
(
WAIT_OBJECT_0
+
1
))
break
;
if
(
waitret
==
(
WAIT_OBJECT_0
+
2
))
break
;
}
if
(
waitret
==
WAIT_OBJECT_0
)
goto
chk_console_input
;
...
...
@@ -677,6 +684,10 @@ BOOL WINAPI DOSVM_Init( HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved
TRACE
(
"Initializing DOS memory structures
\n
"
);
DOSMEM_Init
(
TRUE
);
DOSDEV_InstallDOSDevices
();
event_notifier
=
CreateEventA
(
NULL
,
FALSE
,
FALSE
,
NULL
);
if
(
!
event_notifier
)
ERR
(
"Failed to create event object!
\n
"
);
}
return
TRUE
;
}
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