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
25f7aa52
Commit
25f7aa52
authored
Jul 06, 2020
by
Jacek Caban
Committed by
Alexandre Julliard
Jul 06, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
kernel32: Use IOCTL_CONDRV_READ_INPUT in read_console_input.
Signed-off-by:
Jacek Caban
<
jacek@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
af9a8b1b
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
18 deletions
+6
-18
console.c
dlls/kernel32/console.c
+6
-18
No files found.
dlls/kernel32/console.c
View file @
25f7aa52
...
...
@@ -54,6 +54,7 @@
#include "winnls.h"
#include "winerror.h"
#include "wincon.h"
#include "wine/condrv.h"
#include "wine/server.h"
#include "wine/exception.h"
#include "wine/unicode.h"
...
...
@@ -409,6 +410,8 @@ static enum read_console_input_return read_console_input(HANDLE handle, PINPUT_R
{
int
fd
;
enum
read_console_input_return
ret
;
int
blocking
=
timeout
!=
0
;
DWORD
read_bytes
;
if
((
fd
=
get_console_bare_fd
(
handle
))
!=
-
1
)
{
...
...
@@ -421,25 +424,10 @@ static enum read_console_input_return read_console_input(HANDLE handle, PINPUT_R
close
(
fd
);
if
(
ret
!=
rci_gotone
)
return
ret
;
}
else
{
if
(
!
VerifyConsoleIoHandle
(
handle
))
return
rci_error
;
if
(
WaitForSingleObject
(
handle
,
timeout
)
!=
WAIT_OBJECT_0
)
return
rci_timeout
;
}
SERVER_START_REQ
(
read_console_input
)
{
req
->
handle
=
console_handle_unmap
(
handle
);
req
->
flush
=
TRUE
;
wine_server_set_reply
(
req
,
ir
,
sizeof
(
INPUT_RECORD
)
);
if
(
wine_server_call_err
(
req
)
||
!
reply
->
read
)
ret
=
rci_error
;
else
ret
=
rci_gotone
;
}
SERVER_END_REQ
;
return
ret
;
if
(
!
DeviceIoControl
(
handle
,
IOCTL_CONDRV_READ_INPUT
,
&
blocking
,
sizeof
(
blocking
),
ir
,
sizeof
(
*
ir
),
&
read_bytes
,
NULL
))
return
rci_error
;
return
read_bytes
?
rci_gotone
:
rci_timeout
;
}
...
...
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