diff --git a/dlls/win32u/message.c b/dlls/win32u/message.c index 3c8be48587a..044310a2f0e 100644 --- a/dlls/win32u/message.c +++ b/dlls/win32u/message.c @@ -2729,7 +2729,7 @@ int peek_message( MSG *msg, const struct peek_message_filter *filter ) { NTSTATUS res; size_t size = 0; - const message_data_t *msg_data = buffer; + const union message_data *msg_data = buffer; UINT wake_mask, signal_bits, wake_bits, changed_bits, clear_bits = 0; /* use the same logic as in server/queue.c get_message */ @@ -3320,7 +3320,7 @@ BOOL WINAPI NtUserGetMessage( MSG *msg, HWND hwnd, UINT first, UINT last ) static BOOL put_message_in_queue( const struct send_message_info *info, size_t *reply_size ) { struct packed_message data; - message_data_t msg_data; + union message_data msg_data; unsigned int res; int i; timeout_t timeout = TIMEOUT_INFINITE; diff --git a/include/wine/server_protocol.h b/include/wine/server_protocol.h index 430ccc965a6..eaff2b66929 100644 --- a/include/wine/server_protocol.h +++ b/include/wine/server_protocol.h @@ -344,13 +344,13 @@ typedef union } hw; } hw_input_t; -typedef union +union message_data { unsigned char bytes[1]; struct hardware_msg_data hardware; struct callback_msg_data callback; struct winevent_msg_data winevent; -} message_data_t; +}; struct filesystem_event diff --git a/server/protocol.def b/server/protocol.def index 16f33a3e658..c29a1ff9266 100644 --- a/server/protocol.def +++ b/server/protocol.def @@ -360,13 +360,13 @@ typedef union } hw; } hw_input_t; -typedef union +union message_data { unsigned char bytes[1]; /* raw data for sent messages */ struct hardware_msg_data hardware; struct callback_msg_data callback; struct winevent_msg_data winevent; -} message_data_t; +}; /* structure returned in filesystem events */ struct filesystem_event diff --git a/server/request_handlers.h b/server/request_handlers.h index d4fbfb34ca7..76ff0abeca7 100644 --- a/server/request_handlers.h +++ b/server/request_handlers.h @@ -613,7 +613,6 @@ C_ASSERT( sizeof(ioctl_code_t) == 4 ); C_ASSERT( sizeof(irp_params_t) == 32 ); C_ASSERT( sizeof(lparam_t) == 8 ); C_ASSERT( sizeof(mem_size_t) == 8 ); -C_ASSERT( sizeof(message_data_t) == 48 ); C_ASSERT( sizeof(mod_handle_t) == 8 ); C_ASSERT( sizeof(obj_handle_t) == 4 ); C_ASSERT( sizeof(obj_locator_t) == 16 ); @@ -642,6 +641,7 @@ C_ASSERT( sizeof(timeout_t) == 8 ); C_ASSERT( sizeof(udp_endpoint) == 32 ); C_ASSERT( sizeof(union apc_call) == 64 ); C_ASSERT( sizeof(union apc_result) == 40 ); +C_ASSERT( sizeof(union message_data) == 48 ); C_ASSERT( sizeof(unsigned __int64) == 8 ); C_ASSERT( sizeof(unsigned char) == 1 ); C_ASSERT( sizeof(unsigned int) == 4 ); diff --git a/tools/make_requests b/tools/make_requests index 2eaffe30c0b..bd69742a9b4 100755 --- a/tools/make_requests +++ b/tools/make_requests @@ -47,7 +47,6 @@ my %formats = "context_t" => [ 1728, 8 ], "cursor_pos_t" => [ 24, 8 ], "debug_event_t" => [ 160, 8 ], - "message_data_t" => [ 48, 8 ], "pe_image_info_t" => [ 88, 8 ], "property_data_t" => [ 16, 8 ], "select_op_t" => [ 264, 8 ], @@ -61,6 +60,7 @@ my %formats = "struct handle_info" => [ 20, 4 ], "struct luid" => [ 8, 4 ], "struct luid_attr" => [ 12, 4 ], + "union message_data" => [ 48, 8 ], "struct object_attributes" => [ 16, 4 ], "struct object_type_info" => [ 44, 4 ], "struct process_info" => [ 40, 8 ],