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
f5badeac
Commit
f5badeac
authored
Jul 13, 2020
by
Jacek Caban
Committed by
Alexandre Julliard
Jul 13, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
kernel32: Use IOCTL_CONDRV_GET_MODE in VerifyConsoleIoHandle.
Signed-off-by:
Jacek Caban
<
jacek@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
48a23dbd
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
13 deletions
+7
-13
console.c
dlls/kernel32/console.c
+7
-13
No files found.
dlls/kernel32/console.c
View file @
f5badeac
...
...
@@ -249,16 +249,10 @@ HANDLE WINAPI OpenConsoleW(LPCWSTR name, DWORD access, BOOL inherit, DWORD creat
*/
BOOL
WINAPI
VerifyConsoleIoHandle
(
HANDLE
handle
)
{
BOOL
ret
;
if
(
!
is_console_handle
(
handle
))
return
FALSE
;
SERVER_START_REQ
(
get_console_mode
)
{
req
->
handle
=
console_handle_unmap
(
handle
);
ret
=
!
wine_server_call
(
req
);
}
SERVER_END_REQ
;
return
ret
;
IO_STATUS_BLOCK
io
;
DWORD
mode
;
return
!
NtDeviceIoControlFile
(
handle
,
NULL
,
NULL
,
NULL
,
&
io
,
IOCTL_CONDRV_GET_MODE
,
NULL
,
0
,
&
mode
,
sizeof
(
mode
)
);
}
/******************************************************************
...
...
@@ -1181,7 +1175,7 @@ BOOL CONSOLE_Init(RTL_USER_PROCESS_PARAMETERS *params)
*/
if
(
!
params
->
hStdInput
||
params
->
hStdInput
==
INVALID_HANDLE_VALUE
)
params
->
hStdInput
=
0
;
else
if
(
VerifyConsoleIoHandle
(
console_handle_map
(
params
->
hStdInput
)
))
else
if
(
VerifyConsoleIoHandle
(
params
->
hStdInput
))
{
params
->
hStdInput
=
console_handle_map
(
params
->
hStdInput
);
save_console_mode
(
params
->
hStdInput
);
...
...
@@ -1189,12 +1183,12 @@ BOOL CONSOLE_Init(RTL_USER_PROCESS_PARAMETERS *params)
if
(
!
params
->
hStdOutput
||
params
->
hStdOutput
==
INVALID_HANDLE_VALUE
)
params
->
hStdOutput
=
0
;
else
if
(
VerifyConsoleIoHandle
(
console_handle_map
(
params
->
hStdOutput
)
))
else
if
(
VerifyConsoleIoHandle
(
params
->
hStdOutput
))
params
->
hStdOutput
=
console_handle_map
(
params
->
hStdOutput
);
if
(
!
params
->
hStdError
||
params
->
hStdError
==
INVALID_HANDLE_VALUE
)
params
->
hStdError
=
0
;
else
if
(
VerifyConsoleIoHandle
(
console_handle_map
(
params
->
hStdError
)
))
else
if
(
VerifyConsoleIoHandle
(
params
->
hStdError
))
params
->
hStdError
=
console_handle_map
(
params
->
hStdError
);
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