From 13b2587d4f55d64a1381c60ac34acf4abe6bb1e8 Mon Sep 17 00:00:00 2001 From: Jacek Caban Date: Thu, 25 Jun 2020 22:28:05 +0200 Subject: [PATCH] server: Remove no longer needed support for opening current console in open_console request. Signed-off-by: Jacek Caban Signed-off-by: Alexandre Julliard --- include/wine/server_protocol.h | 1 - server/console.c | 15 ++------------- server/protocol.def | 3 +-- 3 files changed, 3 insertions(+), 16 deletions(-) diff --git a/include/wine/server_protocol.h b/include/wine/server_protocol.h index 24bebb8f106..1acaded199c 100644 --- a/include/wine/server_protocol.h +++ b/include/wine/server_protocol.h @@ -1902,7 +1902,6 @@ struct open_console_request { struct request_header __header; obj_handle_t from; - unsigned int access; unsigned int attributes; int share; diff --git a/server/console.c b/server/console.c index 57592e6ab05..729cfa40612 100644 --- a/server/console.c +++ b/server/console.c @@ -1664,19 +1664,8 @@ DECL_HANDLER(open_console) { struct object *obj = NULL; - reply->handle = 0; - if (!req->from) - { - if (current->process->console) - obj = grab_object( (struct object*)current->process->console ); - } - else if (req->from == (obj_handle_t)1) - { - if (current->process->console && current->process->console->active) - obj = grab_object( (struct object*)current->process->console->active ); - } - else if ((obj = get_handle_obj( current->process, req->from, - FILE_READ_PROPERTIES|FILE_WRITE_PROPERTIES, &console_input_ops ))) + if ((obj = get_handle_obj( current->process, req->from, + FILE_READ_PROPERTIES|FILE_WRITE_PROPERTIES, &console_input_ops ))) { struct console_input *console = (struct console_input *)obj; obj = (console->active) ? grab_object( console->active ) : NULL; diff --git a/server/protocol.def b/server/protocol.def index c3442c06e9b..d412889518a 100644 --- a/server/protocol.def +++ b/server/protocol.def @@ -1523,8 +1523,7 @@ struct console_renderer_event /* Open a handle to the process console */ @REQ(open_console) - obj_handle_t from; /* 0 (resp 1) input (resp output) of current process console */ - /* otherwise console_in handle to get active screen buffer? */ + obj_handle_t from; /* console_in handle to get active screen buffer */ unsigned int access; /* wanted access rights */ unsigned int attributes; /* object attributes */ int share; /* share mask (only for output handles) */