Commit a4ab07a6 authored by Jacek Caban's avatar Jacek Caban Committed by Alexandre Julliard

server: Get rid of no longer needed write_console_input request.

parent 640773aa
......@@ -2148,20 +2148,6 @@ struct get_console_output_info_reply
};
struct write_console_input_request
{
struct request_header __header;
obj_handle_t handle;
/* VARARG(rec,input_records); */
};
struct write_console_input_reply
{
struct reply_header __header;
int written;
char __pad_12[4];
};
struct write_console_output_request
{
......@@ -5847,7 +5833,6 @@ enum request
REQ_create_console_output,
REQ_set_console_output_info,
REQ_get_console_output_info,
REQ_write_console_input,
REQ_write_console_output,
REQ_fill_console_output,
REQ_read_console_output,
......@@ -6148,7 +6133,6 @@ union generic_request
struct create_console_output_request create_console_output_request;
struct set_console_output_info_request set_console_output_info_request;
struct get_console_output_info_request get_console_output_info_request;
struct write_console_input_request write_console_input_request;
struct write_console_output_request write_console_output_request;
struct fill_console_output_request fill_console_output_request;
struct read_console_output_request read_console_output_request;
......@@ -6447,7 +6431,6 @@ union generic_reply
struct create_console_output_reply create_console_output_reply;
struct set_console_output_info_reply set_console_output_info_reply;
struct get_console_output_info_reply get_console_output_info_reply;
struct write_console_input_reply write_console_input_reply;
struct write_console_output_reply write_console_output_reply;
struct fill_console_output_reply fill_console_output_reply;
struct read_console_output_reply read_console_output_reply;
......@@ -6669,7 +6652,7 @@ union generic_reply
/* ### protocol_version begin ### */
#define SERVER_PROTOCOL_VERSION 617
#define SERVER_PROTOCOL_VERSION 618
/* ### protocol_version end ### */
......
......@@ -755,12 +755,12 @@ static int write_console_input( struct console_input* console, int count,
INPUT_RECORD *new_rec;
struct async *async;
if (!count) return 0;
if (!count) return 1;
if (!(new_rec = realloc( console->records,
(console->recnum + count) * sizeof(INPUT_RECORD) )))
{
set_error( STATUS_NO_MEMORY );
return -1;
return 0;
}
console->records = new_rec;
memcpy( new_rec + console->recnum, records, count * sizeof(INPUT_RECORD) );
......@@ -795,7 +795,7 @@ static int write_console_input( struct console_input* console, int count,
release_object( async );
}
if (console->recnum) set_event( console->event );
return count;
return 1;
}
/* set misc console input information */
......@@ -1538,7 +1538,7 @@ static int console_ioctl( struct fd *fd, ioctl_code_t code, struct async *async
}
case IOCTL_CONDRV_WRITE_INPUT:
return write_console_input( console, get_req_data_size() / sizeof(INPUT_RECORD), get_req_data() ) != -1;
return write_console_input( console, get_req_data_size() / sizeof(INPUT_RECORD), get_req_data() );
case IOCTL_CONDRV_PEEK:
if (get_reply_max_size() % sizeof(INPUT_RECORD))
......@@ -1845,20 +1845,6 @@ DECL_HANDLER(set_console_mode)
set_console_mode( req->handle, req->mode );
}
/* add input records to a console input queue */
DECL_HANDLER(write_console_input)
{
struct console_input *console;
reply->written = 0;
if (!(console = (struct console_input *)get_handle_obj( current->process, req->handle,
FILE_WRITE_PROPERTIES, &console_input_ops )))
return;
reply->written = write_console_input( console, get_req_data_size() / sizeof(INPUT_RECORD),
get_req_data() );
release_object( console );
}
/* appends a string to console's history */
DECL_HANDLER(append_console_input_history)
{
......
......@@ -1697,14 +1697,6 @@ struct console_renderer_event
VARARG(face_name,unicode_str); /* font face name */
@END
/* Add input records to a console input queue */
@REQ(write_console_input)
obj_handle_t handle; /* handle to the console input */
VARARG(rec,input_records); /* input records */
@REPLY
int written; /* number of records written */
@END
/* write data (chars and/or attributes) in a screen buffer */
@REQ(write_console_output)
......
......@@ -195,7 +195,6 @@ DECL_HANDLER(get_console_input_history);
DECL_HANDLER(create_console_output);
DECL_HANDLER(set_console_output_info);
DECL_HANDLER(get_console_output_info);
DECL_HANDLER(write_console_input);
DECL_HANDLER(write_console_output);
DECL_HANDLER(fill_console_output);
DECL_HANDLER(read_console_output);
......@@ -495,7 +494,6 @@ static const req_handler req_handlers[REQ_NB_REQUESTS] =
(req_handler)req_create_console_output,
(req_handler)req_set_console_output_info,
(req_handler)req_get_console_output_info,
(req_handler)req_write_console_input,
(req_handler)req_write_console_output,
(req_handler)req_fill_console_output,
(req_handler)req_read_console_output,
......@@ -1236,10 +1234,6 @@ C_ASSERT( FIELD_OFFSET(struct get_console_output_info_reply, font_height) == 38
C_ASSERT( FIELD_OFFSET(struct get_console_output_info_reply, font_weight) == 40 );
C_ASSERT( FIELD_OFFSET(struct get_console_output_info_reply, font_pitch_family) == 42 );
C_ASSERT( sizeof(struct get_console_output_info_reply) == 48 );
C_ASSERT( FIELD_OFFSET(struct write_console_input_request, handle) == 12 );
C_ASSERT( sizeof(struct write_console_input_request) == 16 );
C_ASSERT( FIELD_OFFSET(struct write_console_input_reply, written) == 8 );
C_ASSERT( sizeof(struct write_console_input_reply) == 16 );
C_ASSERT( FIELD_OFFSET(struct write_console_output_request, handle) == 12 );
C_ASSERT( FIELD_OFFSET(struct write_console_output_request, x) == 16 );
C_ASSERT( FIELD_OFFSET(struct write_console_output_request, y) == 20 );
......
......@@ -859,22 +859,6 @@ static void dump_varargs_startup_info( const char *prefix, data_size_t size )
remove_data( size );
}
static void dump_varargs_input_records( const char *prefix, data_size_t size )
{
const INPUT_RECORD *rec = cur_data;
data_size_t len = size / sizeof(*rec);
fprintf( stderr,"%s{", prefix );
while (len > 0)
{
fprintf( stderr, "{%04x,...}", rec->EventType );
rec++;
if (--len) fputc( ',', stderr );
}
fputc( '}', stderr );
remove_data( size );
}
static void dump_varargs_rectangles( const char *prefix, data_size_t size )
{
const rectangle_t *rect = cur_data;
......@@ -2221,17 +2205,6 @@ static void dump_get_console_output_info_reply( const struct get_console_output_
dump_varargs_unicode_str( ", face_name=", cur_size );
}
static void dump_write_console_input_request( const struct write_console_input_request *req )
{
fprintf( stderr, " handle=%04x", req->handle );
dump_varargs_input_records( ", rec=", cur_size );
}
static void dump_write_console_input_reply( const struct write_console_input_reply *req )
{
fprintf( stderr, " written=%d", req->written );
}
static void dump_write_console_output_request( const struct write_console_output_request *req )
{
fprintf( stderr, " handle=%04x", req->handle );
......@@ -4690,7 +4663,6 @@ static const dump_func req_dumpers[REQ_NB_REQUESTS] = {
(dump_func)dump_create_console_output_request,
(dump_func)dump_set_console_output_info_request,
(dump_func)dump_get_console_output_info_request,
(dump_func)dump_write_console_input_request,
(dump_func)dump_write_console_output_request,
(dump_func)dump_fill_console_output_request,
(dump_func)dump_read_console_output_request,
......@@ -4987,7 +4959,6 @@ static const dump_func reply_dumpers[REQ_NB_REQUESTS] = {
(dump_func)dump_create_console_output_reply,
NULL,
(dump_func)dump_get_console_output_info_reply,
(dump_func)dump_write_console_input_reply,
(dump_func)dump_write_console_output_reply,
(dump_func)dump_fill_console_output_reply,
(dump_func)dump_read_console_output_reply,
......@@ -5284,7 +5255,6 @@ static const char * const req_names[REQ_NB_REQUESTS] = {
"create_console_output",
"set_console_output_info",
"get_console_output_info",
"write_console_input",
"write_console_output",
"fill_console_output",
"read_console_output",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment