Added CS_DBLCLKS so that systray receives double clicks.
[wine/multimedia.git] / server / trace.c
blob49f486b835e3cb0ee5cde557472dbebb0ac083bb
1 /*
2 * Server request tracing
4 * Copyright (C) 1999 Alexandre Julliard
6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Lesser General Public
8 * License as published by the Free Software Foundation; either
9 * version 2.1 of the License, or (at your option) any later version.
11 * This library is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * Lesser General Public License for more details.
16 * You should have received a copy of the GNU Lesser General Public
17 * License along with this library; if not, write to the Free Software
18 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
21 #include "config.h"
22 #include "wine/port.h"
24 #include <ctype.h>
25 #include <stdio.h>
26 #include <sys/types.h>
27 #include <sys/uio.h>
29 #include "winnt.h"
30 #include "winbase.h"
31 #include "wincon.h"
32 #include "request.h"
33 #include "unicode.h"
35 static int cur_pos;
36 static const void *cur_data;
37 static int cur_size;
39 /* utility functions */
41 inline static void remove_data( size_t size )
43 cur_data = (const char *)cur_data + size;
44 cur_size -= size;
47 static void dump_uints( const int *ptr, int len )
49 fputc( '{', stderr );
50 while (len > 0)
52 fprintf( stderr, "%08x", *ptr++ );
53 if (--len) fputc( ',', stderr );
55 fputc( '}', stderr );
58 static void dump_rectangle( const rectangle_t *rect )
60 fprintf( stderr, "{%d,%d;%d,%d}",
61 rect->left, rect->top, rect->right, rect->bottom );
64 static void dump_char_info( const char_info_t *info )
66 fprintf( stderr, "{'" );
67 dump_strW( &info->ch, 1, stderr, "\'\'" );
68 fprintf( stderr, "',%04x}", info->attr );
71 static void dump_context( const CONTEXT *context )
73 #ifdef __i386__
74 fprintf( stderr, "{flags=%08lx,eax=%08lx,ebx=%08lx,ecx=%08lx,edx=%08lx,esi=%08lx,edi=%08lx,"
75 "ebp=%08lx,eip=%08lx,esp=%08lx,eflags=%08lx,cs=%04lx,ds=%04lx,es=%04lx,"
76 "fs=%04lx,gs=%04lx,dr0=%08lx,dr1=%08lx,dr2=%08lx,dr3=%08lx,dr6=%08lx,dr7=%08lx,",
77 context->ContextFlags, context->Eax, context->Ebx, context->Ecx, context->Edx,
78 context->Esi, context->Edi, context->Ebp, context->Eip, context->Esp, context->EFlags,
79 context->SegCs, context->SegDs, context->SegEs, context->SegFs, context->SegGs,
80 context->Dr0, context->Dr1, context->Dr2, context->Dr3, context->Dr6, context->Dr7 );
81 fprintf( stderr, "float=" );
82 dump_uints( (int *)&context->FloatSave, sizeof(context->FloatSave) / sizeof(int) );
83 fprintf( stderr, "}" );
84 #else
85 dump_uints( (int *)context, sizeof(*context) / sizeof(int) );
86 #endif
89 static void dump_exc_record( const EXCEPTION_RECORD *rec )
91 int i;
92 fprintf( stderr, "{code=%lx,flags=%lx,rec=%p,addr=%p,params={",
93 rec->ExceptionCode, rec->ExceptionFlags, rec->ExceptionRecord,
94 rec->ExceptionAddress );
95 for (i = 0; i < min(rec->NumberParameters,EXCEPTION_MAXIMUM_PARAMETERS); i++)
97 if (i) fputc( ',', stderr );
98 fprintf( stderr, "%lx", rec->ExceptionInformation[i] );
100 fputc( '}', stderr );
103 static void dump_varargs_ints( size_t size )
105 const int *data = cur_data;
106 size_t len = size / sizeof(*data);
108 fputc( '{', stderr );
109 while (len > 0)
111 fprintf( stderr, "%d", *data++ );
112 if (--len) fputc( ',', stderr );
114 fputc( '}', stderr );
115 remove_data( size );
118 static void dump_varargs_handles( size_t size )
120 const obj_handle_t *data = cur_data;
121 size_t len = size / sizeof(*data);
123 fputc( '{', stderr );
124 while (len > 0)
126 fprintf( stderr, "%p", *data++ );
127 if (--len) fputc( ',', stderr );
129 fputc( '}', stderr );
130 remove_data( size );
133 static void dump_varargs_ptrs( size_t size )
135 void * const *data = cur_data;
136 size_t len = size / sizeof(*data);
138 fputc( '{', stderr );
139 while (len > 0)
141 fprintf( stderr, "%p", *data++ );
142 if (--len) fputc( ',', stderr );
144 fputc( '}', stderr );
145 remove_data( size );
148 static void dump_varargs_user_handles( size_t size )
150 const user_handle_t *data = cur_data;
151 size_t len = size / sizeof(*data);
153 fputc( '{', stderr );
154 while (len > 0)
156 fprintf( stderr, "%p", *data++ );
157 if (--len) fputc( ',', stderr );
159 fputc( '}', stderr );
160 remove_data( size );
163 static void dump_varargs_bytes( size_t size )
165 const unsigned char *data = cur_data;
166 size_t len = size;
168 fputc( '{', stderr );
169 while (len > 0)
171 fprintf( stderr, "%02x", *data++ );
172 if (--len) fputc( ',', stderr );
174 fputc( '}', stderr );
175 remove_data( size );
178 static void dump_varargs_string( size_t size )
180 fprintf( stderr, "\"%.*s\"", (int)size, (char *)cur_data );
181 remove_data( size );
184 static void dump_varargs_unicode_str( size_t size )
186 fprintf( stderr, "L\"" );
187 dump_strW( cur_data, size / sizeof(WCHAR), stderr, "\"\"" );
188 fputc( '\"', stderr );
189 remove_data( size );
192 static void dump_varargs_context( size_t size )
194 dump_context( cur_data );
195 remove_data( size );
198 static void dump_varargs_exc_event( size_t size )
200 const CONTEXT *ptr = cur_data;
201 fprintf( stderr, "{context=" );
202 dump_context( ptr );
203 fprintf( stderr, ",rec=" );
204 dump_exc_record( (EXCEPTION_RECORD *)(ptr + 1) );
205 fputc( '}', stderr );
206 remove_data( size );
209 static void dump_varargs_debug_event( size_t size )
211 const debug_event_t *event = cur_data;
213 if (!size)
215 fprintf( stderr, "{}" );
216 return;
218 switch(event->code)
220 case EXCEPTION_DEBUG_EVENT:
221 fprintf( stderr, "{exception," );
222 dump_exc_record( &event->info.exception.record );
223 fprintf( stderr, ",first=%d}", event->info.exception.first );
224 break;
225 case CREATE_THREAD_DEBUG_EVENT:
226 fprintf( stderr, "{create_thread,thread=%p,teb=%p,start=%p}",
227 event->info.create_thread.handle, event->info.create_thread.teb,
228 event->info.create_thread.start );
229 break;
230 case CREATE_PROCESS_DEBUG_EVENT:
231 fprintf( stderr, "{create_process,file=%p,process=%p,thread=%p,base=%p,offset=%d,"
232 "size=%d,teb=%p,start=%p,name=%p,unicode=%d}",
233 event->info.create_process.file, event->info.create_process.process,
234 event->info.create_process.thread, event->info.create_process.base,
235 event->info.create_process.dbg_offset, event->info.create_process.dbg_size,
236 event->info.create_process.teb, event->info.create_process.start,
237 event->info.create_process.name, event->info.create_process.unicode );
238 break;
239 case EXIT_THREAD_DEBUG_EVENT:
240 fprintf( stderr, "{exit_thread,code=%d}", event->info.exit.exit_code );
241 break;
242 case EXIT_PROCESS_DEBUG_EVENT:
243 fprintf( stderr, "{exit_process,code=%d}", event->info.exit.exit_code );
244 break;
245 case LOAD_DLL_DEBUG_EVENT:
246 fprintf( stderr, "{load_dll,file=%p,base=%p,offset=%d,size=%d,name=%p,unicode=%d}",
247 event->info.load_dll.handle, event->info.load_dll.base,
248 event->info.load_dll.dbg_offset, event->info.load_dll.dbg_size,
249 event->info.load_dll.name, event->info.load_dll.unicode );
250 break;
251 case UNLOAD_DLL_DEBUG_EVENT:
252 fprintf( stderr, "{unload_dll,base=%p}", event->info.unload_dll.base );
253 break;
254 case OUTPUT_DEBUG_STRING_EVENT:
255 fprintf( stderr, "{output_string,data=%p,unicode=%d,len=%d}",
256 event->info.output_string.string, event->info.output_string.unicode,
257 event->info.output_string.length );
258 break;
259 case RIP_EVENT:
260 fprintf( stderr, "{rip,err=%d,type=%d}",
261 event->info.rip_info.error, event->info.rip_info.type );
262 break;
263 case 0: /* zero is the code returned on timeouts */
264 fprintf( stderr, "{}" );
265 break;
266 default:
267 fprintf( stderr, "{code=??? (%d)}", event->code );
268 break;
270 remove_data( size );
273 static void dump_varargs_startup_info( size_t size )
275 const startup_info_t *ptr = cur_data;
276 startup_info_t info;
278 if (size < sizeof(info.size))
280 fprintf( stderr, "{}" );
281 return;
283 if (size > ptr->size) size = ptr->size;
284 memset( &info, 0, sizeof(info) );
285 memcpy( &info, ptr, min( size, sizeof(info) ));
287 fprintf( stderr, "{size=%d", info.size );
288 fprintf( stderr, ",x=%d", info.x );
289 fprintf( stderr, ",y=%d", info.y );
290 fprintf( stderr, ",cx=%d", info.cx );
291 fprintf( stderr, ",cy=%d", info.cy );
292 fprintf( stderr, ",x_chars=%d", info.x_chars );
293 fprintf( stderr, ",y_chars=%d", info.y_chars );
294 fprintf( stderr, ",attr=%d", info.attribute );
295 fprintf( stderr, ",cmd_show=%d", info.cmd_show );
296 fprintf( stderr, ",flags=%x", info.flags );
297 remove_data( size );
298 fprintf( stderr, ",filename=" );
299 /* FIXME: these should be unicode */
300 dump_varargs_string( min(cur_size,info.filename_len) );
301 fprintf( stderr, ",cmdline=" );
302 dump_varargs_string( min(cur_size,info.cmdline_len) );
303 fprintf( stderr, ",desktop=" );
304 dump_varargs_string( min(cur_size,info.desktop_len) );
305 fprintf( stderr, ",title=" );
306 dump_varargs_string( min(cur_size,info.title_len) );
307 fputc( '}', stderr );
310 static void dump_varargs_input_records( size_t size )
312 const INPUT_RECORD *rec = cur_data;
313 size_t len = size / sizeof(*rec);
315 fputc( '{', stderr );
316 while (len > 0)
318 fprintf( stderr, "{%04x,...}", rec->EventType );
319 rec++;
320 if (--len) fputc( ',', stderr );
322 fputc( '}', stderr );
323 remove_data( size );
326 static void dump_varargs_properties( size_t size )
328 const property_data_t *prop = cur_data;
329 size_t len = size / sizeof(*prop);
331 fputc( '{', stderr );
332 while (len > 0)
334 fprintf( stderr, "{atom=%04x,str=%d,handle=%p}",
335 prop->atom, prop->string, prop->handle );
336 prop++;
337 if (--len) fputc( ',', stderr );
339 fputc( '}', stderr );
340 remove_data( size );
343 typedef void (*dump_func)( const void *req );
345 /* Everything below this line is generated automatically by tools/make_requests */
346 /* ### make_requests begin ### */
348 static void dump_new_process_request( const struct new_process_request *req )
350 fprintf( stderr, " inherit_all=%d,", req->inherit_all );
351 fprintf( stderr, " use_handles=%d,", req->use_handles );
352 fprintf( stderr, " create_flags=%d,", req->create_flags );
353 fprintf( stderr, " exe_file=%p,", req->exe_file );
354 fprintf( stderr, " hstdin=%p,", req->hstdin );
355 fprintf( stderr, " hstdout=%p,", req->hstdout );
356 fprintf( stderr, " hstderr=%p,", req->hstderr );
357 fprintf( stderr, " info=" );
358 dump_varargs_startup_info( cur_size );
361 static void dump_new_process_reply( const struct new_process_reply *req )
363 fprintf( stderr, " info=%p", req->info );
366 static void dump_get_new_process_info_request( const struct get_new_process_info_request *req )
368 fprintf( stderr, " info=%p,", req->info );
369 fprintf( stderr, " pinherit=%d,", req->pinherit );
370 fprintf( stderr, " tinherit=%d", req->tinherit );
373 static void dump_get_new_process_info_reply( const struct get_new_process_info_reply *req )
375 fprintf( stderr, " pid=%08x,", req->pid );
376 fprintf( stderr, " phandle=%p,", req->phandle );
377 fprintf( stderr, " tid=%08x,", req->tid );
378 fprintf( stderr, " thandle=%p,", req->thandle );
379 fprintf( stderr, " success=%d", req->success );
382 static void dump_new_thread_request( const struct new_thread_request *req )
384 fprintf( stderr, " suspend=%d,", req->suspend );
385 fprintf( stderr, " inherit=%d,", req->inherit );
386 fprintf( stderr, " request_fd=%d", req->request_fd );
389 static void dump_new_thread_reply( const struct new_thread_reply *req )
391 fprintf( stderr, " tid=%08x,", req->tid );
392 fprintf( stderr, " handle=%p", req->handle );
395 static void dump_boot_done_request( const struct boot_done_request *req )
397 fprintf( stderr, " debug_level=%d", req->debug_level );
400 static void dump_init_process_request( const struct init_process_request *req )
402 fprintf( stderr, " ldt_copy=%p,", req->ldt_copy );
403 fprintf( stderr, " ppid=%d", req->ppid );
406 static void dump_init_process_reply( const struct init_process_reply *req )
408 fprintf( stderr, " create_flags=%d,", req->create_flags );
409 fprintf( stderr, " server_start=%08x,", req->server_start );
410 fprintf( stderr, " info_size=%d,", req->info_size );
411 fprintf( stderr, " exe_file=%p,", req->exe_file );
412 fprintf( stderr, " hstdin=%p,", req->hstdin );
413 fprintf( stderr, " hstdout=%p,", req->hstdout );
414 fprintf( stderr, " hstderr=%p", req->hstderr );
417 static void dump_get_startup_info_request( const struct get_startup_info_request *req )
421 static void dump_get_startup_info_reply( const struct get_startup_info_reply *req )
423 fprintf( stderr, " info=" );
424 dump_varargs_startup_info( cur_size );
427 static void dump_init_process_done_request( const struct init_process_done_request *req )
429 fprintf( stderr, " module=%p,", req->module );
430 fprintf( stderr, " module_size=%d,", req->module_size );
431 fprintf( stderr, " entry=%p,", req->entry );
432 fprintf( stderr, " name=%p,", req->name );
433 fprintf( stderr, " exe_file=%p,", req->exe_file );
434 fprintf( stderr, " gui=%d,", req->gui );
435 fprintf( stderr, " filename=" );
436 dump_varargs_string( cur_size );
439 static void dump_init_process_done_reply( const struct init_process_done_reply *req )
441 fprintf( stderr, " debugged=%d", req->debugged );
444 static void dump_init_thread_request( const struct init_thread_request *req )
446 fprintf( stderr, " unix_pid=%d,", req->unix_pid );
447 fprintf( stderr, " teb=%p,", req->teb );
448 fprintf( stderr, " entry=%p,", req->entry );
449 fprintf( stderr, " reply_fd=%d,", req->reply_fd );
450 fprintf( stderr, " wait_fd=%d", req->wait_fd );
453 static void dump_init_thread_reply( const struct init_thread_reply *req )
455 fprintf( stderr, " pid=%08x,", req->pid );
456 fprintf( stderr, " tid=%08x,", req->tid );
457 fprintf( stderr, " boot=%d,", req->boot );
458 fprintf( stderr, " version=%d", req->version );
461 static void dump_terminate_process_request( const struct terminate_process_request *req )
463 fprintf( stderr, " handle=%p,", req->handle );
464 fprintf( stderr, " exit_code=%d", req->exit_code );
467 static void dump_terminate_process_reply( const struct terminate_process_reply *req )
469 fprintf( stderr, " self=%d", req->self );
472 static void dump_terminate_thread_request( const struct terminate_thread_request *req )
474 fprintf( stderr, " handle=%p,", req->handle );
475 fprintf( stderr, " exit_code=%d", req->exit_code );
478 static void dump_terminate_thread_reply( const struct terminate_thread_reply *req )
480 fprintf( stderr, " self=%d,", req->self );
481 fprintf( stderr, " last=%d", req->last );
484 static void dump_get_process_info_request( const struct get_process_info_request *req )
486 fprintf( stderr, " handle=%p", req->handle );
489 static void dump_get_process_info_reply( const struct get_process_info_reply *req )
491 fprintf( stderr, " pid=%08x,", req->pid );
492 fprintf( stderr, " debugged=%d,", req->debugged );
493 fprintf( stderr, " exit_code=%d,", req->exit_code );
494 fprintf( stderr, " priority=%d,", req->priority );
495 fprintf( stderr, " process_affinity=%d,", req->process_affinity );
496 fprintf( stderr, " system_affinity=%d", req->system_affinity );
499 static void dump_set_process_info_request( const struct set_process_info_request *req )
501 fprintf( stderr, " handle=%p,", req->handle );
502 fprintf( stderr, " mask=%d,", req->mask );
503 fprintf( stderr, " priority=%d,", req->priority );
504 fprintf( stderr, " affinity=%d", req->affinity );
507 static void dump_get_thread_info_request( const struct get_thread_info_request *req )
509 fprintf( stderr, " handle=%p,", req->handle );
510 fprintf( stderr, " tid_in=%08x", req->tid_in );
513 static void dump_get_thread_info_reply( const struct get_thread_info_reply *req )
515 fprintf( stderr, " tid=%08x,", req->tid );
516 fprintf( stderr, " teb=%p,", req->teb );
517 fprintf( stderr, " exit_code=%d,", req->exit_code );
518 fprintf( stderr, " priority=%d", req->priority );
521 static void dump_set_thread_info_request( const struct set_thread_info_request *req )
523 fprintf( stderr, " handle=%p,", req->handle );
524 fprintf( stderr, " mask=%d,", req->mask );
525 fprintf( stderr, " priority=%d,", req->priority );
526 fprintf( stderr, " affinity=%d", req->affinity );
529 static void dump_suspend_thread_request( const struct suspend_thread_request *req )
531 fprintf( stderr, " handle=%p", req->handle );
534 static void dump_suspend_thread_reply( const struct suspend_thread_reply *req )
536 fprintf( stderr, " count=%d", req->count );
539 static void dump_resume_thread_request( const struct resume_thread_request *req )
541 fprintf( stderr, " handle=%p", req->handle );
544 static void dump_resume_thread_reply( const struct resume_thread_reply *req )
546 fprintf( stderr, " count=%d", req->count );
549 static void dump_load_dll_request( const struct load_dll_request *req )
551 fprintf( stderr, " handle=%p,", req->handle );
552 fprintf( stderr, " base=%p,", req->base );
553 fprintf( stderr, " size=%d,", req->size );
554 fprintf( stderr, " dbg_offset=%d,", req->dbg_offset );
555 fprintf( stderr, " dbg_size=%d,", req->dbg_size );
556 fprintf( stderr, " name=%p,", req->name );
557 fprintf( stderr, " filename=" );
558 dump_varargs_string( cur_size );
561 static void dump_unload_dll_request( const struct unload_dll_request *req )
563 fprintf( stderr, " base=%p", req->base );
566 static void dump_queue_apc_request( const struct queue_apc_request *req )
568 fprintf( stderr, " handle=%p,", req->handle );
569 fprintf( stderr, " user=%d,", req->user );
570 fprintf( stderr, " func=%p,", req->func );
571 fprintf( stderr, " param=%p", req->param );
574 static void dump_get_apc_request( const struct get_apc_request *req )
576 fprintf( stderr, " alertable=%d", req->alertable );
579 static void dump_get_apc_reply( const struct get_apc_reply *req )
581 fprintf( stderr, " func=%p,", req->func );
582 fprintf( stderr, " type=%d,", req->type );
583 fprintf( stderr, " args=" );
584 dump_varargs_ptrs( cur_size );
587 static void dump_close_handle_request( const struct close_handle_request *req )
589 fprintf( stderr, " handle=%p", req->handle );
592 static void dump_close_handle_reply( const struct close_handle_reply *req )
594 fprintf( stderr, " fd=%d", req->fd );
597 static void dump_set_handle_info_request( const struct set_handle_info_request *req )
599 fprintf( stderr, " handle=%p,", req->handle );
600 fprintf( stderr, " flags=%d,", req->flags );
601 fprintf( stderr, " mask=%d,", req->mask );
602 fprintf( stderr, " fd=%d", req->fd );
605 static void dump_set_handle_info_reply( const struct set_handle_info_reply *req )
607 fprintf( stderr, " old_flags=%d,", req->old_flags );
608 fprintf( stderr, " cur_fd=%d", req->cur_fd );
611 static void dump_dup_handle_request( const struct dup_handle_request *req )
613 fprintf( stderr, " src_process=%p,", req->src_process );
614 fprintf( stderr, " src_handle=%p,", req->src_handle );
615 fprintf( stderr, " dst_process=%p,", req->dst_process );
616 fprintf( stderr, " access=%08x,", req->access );
617 fprintf( stderr, " inherit=%d,", req->inherit );
618 fprintf( stderr, " options=%d", req->options );
621 static void dump_dup_handle_reply( const struct dup_handle_reply *req )
623 fprintf( stderr, " handle=%p,", req->handle );
624 fprintf( stderr, " fd=%d", req->fd );
627 static void dump_open_process_request( const struct open_process_request *req )
629 fprintf( stderr, " pid=%08x,", req->pid );
630 fprintf( stderr, " access=%08x,", req->access );
631 fprintf( stderr, " inherit=%d", req->inherit );
634 static void dump_open_process_reply( const struct open_process_reply *req )
636 fprintf( stderr, " handle=%p", req->handle );
639 static void dump_open_thread_request( const struct open_thread_request *req )
641 fprintf( stderr, " tid=%08x,", req->tid );
642 fprintf( stderr, " access=%08x,", req->access );
643 fprintf( stderr, " inherit=%d", req->inherit );
646 static void dump_open_thread_reply( const struct open_thread_reply *req )
648 fprintf( stderr, " handle=%p", req->handle );
651 static void dump_select_request( const struct select_request *req )
653 fprintf( stderr, " flags=%d,", req->flags );
654 fprintf( stderr, " cookie=%p,", req->cookie );
655 fprintf( stderr, " sec=%d,", req->sec );
656 fprintf( stderr, " usec=%d,", req->usec );
657 fprintf( stderr, " handles=" );
658 dump_varargs_handles( cur_size );
661 static void dump_create_event_request( const struct create_event_request *req )
663 fprintf( stderr, " manual_reset=%d,", req->manual_reset );
664 fprintf( stderr, " initial_state=%d,", req->initial_state );
665 fprintf( stderr, " inherit=%d,", req->inherit );
666 fprintf( stderr, " name=" );
667 dump_varargs_unicode_str( cur_size );
670 static void dump_create_event_reply( const struct create_event_reply *req )
672 fprintf( stderr, " handle=%p", req->handle );
675 static void dump_event_op_request( const struct event_op_request *req )
677 fprintf( stderr, " handle=%p,", req->handle );
678 fprintf( stderr, " op=%d", req->op );
681 static void dump_open_event_request( const struct open_event_request *req )
683 fprintf( stderr, " access=%08x,", req->access );
684 fprintf( stderr, " inherit=%d,", req->inherit );
685 fprintf( stderr, " name=" );
686 dump_varargs_unicode_str( cur_size );
689 static void dump_open_event_reply( const struct open_event_reply *req )
691 fprintf( stderr, " handle=%p", req->handle );
694 static void dump_create_mutex_request( const struct create_mutex_request *req )
696 fprintf( stderr, " owned=%d,", req->owned );
697 fprintf( stderr, " inherit=%d,", req->inherit );
698 fprintf( stderr, " name=" );
699 dump_varargs_unicode_str( cur_size );
702 static void dump_create_mutex_reply( const struct create_mutex_reply *req )
704 fprintf( stderr, " handle=%p", req->handle );
707 static void dump_release_mutex_request( const struct release_mutex_request *req )
709 fprintf( stderr, " handle=%p", req->handle );
712 static void dump_open_mutex_request( const struct open_mutex_request *req )
714 fprintf( stderr, " access=%08x,", req->access );
715 fprintf( stderr, " inherit=%d,", req->inherit );
716 fprintf( stderr, " name=" );
717 dump_varargs_unicode_str( cur_size );
720 static void dump_open_mutex_reply( const struct open_mutex_reply *req )
722 fprintf( stderr, " handle=%p", req->handle );
725 static void dump_create_semaphore_request( const struct create_semaphore_request *req )
727 fprintf( stderr, " initial=%08x,", req->initial );
728 fprintf( stderr, " max=%08x,", req->max );
729 fprintf( stderr, " inherit=%d,", req->inherit );
730 fprintf( stderr, " name=" );
731 dump_varargs_unicode_str( cur_size );
734 static void dump_create_semaphore_reply( const struct create_semaphore_reply *req )
736 fprintf( stderr, " handle=%p", req->handle );
739 static void dump_release_semaphore_request( const struct release_semaphore_request *req )
741 fprintf( stderr, " handle=%p,", req->handle );
742 fprintf( stderr, " count=%08x", req->count );
745 static void dump_release_semaphore_reply( const struct release_semaphore_reply *req )
747 fprintf( stderr, " prev_count=%08x", req->prev_count );
750 static void dump_open_semaphore_request( const struct open_semaphore_request *req )
752 fprintf( stderr, " access=%08x,", req->access );
753 fprintf( stderr, " inherit=%d,", req->inherit );
754 fprintf( stderr, " name=" );
755 dump_varargs_unicode_str( cur_size );
758 static void dump_open_semaphore_reply( const struct open_semaphore_reply *req )
760 fprintf( stderr, " handle=%p", req->handle );
763 static void dump_create_file_request( const struct create_file_request *req )
765 fprintf( stderr, " access=%08x,", req->access );
766 fprintf( stderr, " inherit=%d,", req->inherit );
767 fprintf( stderr, " sharing=%08x,", req->sharing );
768 fprintf( stderr, " create=%d,", req->create );
769 fprintf( stderr, " attrs=%08x,", req->attrs );
770 fprintf( stderr, " drive_type=%d,", req->drive_type );
771 fprintf( stderr, " filename=" );
772 dump_varargs_string( cur_size );
775 static void dump_create_file_reply( const struct create_file_reply *req )
777 fprintf( stderr, " handle=%p", req->handle );
780 static void dump_alloc_file_handle_request( const struct alloc_file_handle_request *req )
782 fprintf( stderr, " access=%08x,", req->access );
783 fprintf( stderr, " inherit=%d,", req->inherit );
784 fprintf( stderr, " fd=%d", req->fd );
787 static void dump_alloc_file_handle_reply( const struct alloc_file_handle_reply *req )
789 fprintf( stderr, " handle=%p", req->handle );
792 static void dump_get_handle_fd_request( const struct get_handle_fd_request *req )
794 fprintf( stderr, " handle=%p,", req->handle );
795 fprintf( stderr, " access=%08x", req->access );
798 static void dump_get_handle_fd_reply( const struct get_handle_fd_reply *req )
800 fprintf( stderr, " fd=%d,", req->fd );
801 fprintf( stderr, " type=%d,", req->type );
802 fprintf( stderr, " flags=%d", req->flags );
805 static void dump_set_file_pointer_request( const struct set_file_pointer_request *req )
807 fprintf( stderr, " handle=%p,", req->handle );
808 fprintf( stderr, " low=%d,", req->low );
809 fprintf( stderr, " high=%d,", req->high );
810 fprintf( stderr, " whence=%d", req->whence );
813 static void dump_set_file_pointer_reply( const struct set_file_pointer_reply *req )
815 fprintf( stderr, " new_low=%d,", req->new_low );
816 fprintf( stderr, " new_high=%d", req->new_high );
819 static void dump_truncate_file_request( const struct truncate_file_request *req )
821 fprintf( stderr, " handle=%p", req->handle );
824 static void dump_set_file_time_request( const struct set_file_time_request *req )
826 fprintf( stderr, " handle=%p,", req->handle );
827 fprintf( stderr, " access_time=%ld,", req->access_time );
828 fprintf( stderr, " write_time=%ld", req->write_time );
831 static void dump_flush_file_request( const struct flush_file_request *req )
833 fprintf( stderr, " handle=%p", req->handle );
836 static void dump_get_file_info_request( const struct get_file_info_request *req )
838 fprintf( stderr, " handle=%p", req->handle );
841 static void dump_get_file_info_reply( const struct get_file_info_reply *req )
843 fprintf( stderr, " type=%d,", req->type );
844 fprintf( stderr, " attr=%d,", req->attr );
845 fprintf( stderr, " access_time=%ld,", req->access_time );
846 fprintf( stderr, " write_time=%ld,", req->write_time );
847 fprintf( stderr, " size_high=%d,", req->size_high );
848 fprintf( stderr, " size_low=%d,", req->size_low );
849 fprintf( stderr, " links=%d,", req->links );
850 fprintf( stderr, " index_high=%d,", req->index_high );
851 fprintf( stderr, " index_low=%d,", req->index_low );
852 fprintf( stderr, " serial=%08x", req->serial );
855 static void dump_lock_file_request( const struct lock_file_request *req )
857 fprintf( stderr, " handle=%p,", req->handle );
858 fprintf( stderr, " offset_low=%08x,", req->offset_low );
859 fprintf( stderr, " offset_high=%08x,", req->offset_high );
860 fprintf( stderr, " count_low=%08x,", req->count_low );
861 fprintf( stderr, " count_high=%08x", req->count_high );
864 static void dump_unlock_file_request( const struct unlock_file_request *req )
866 fprintf( stderr, " handle=%p,", req->handle );
867 fprintf( stderr, " offset_low=%08x,", req->offset_low );
868 fprintf( stderr, " offset_high=%08x,", req->offset_high );
869 fprintf( stderr, " count_low=%08x,", req->count_low );
870 fprintf( stderr, " count_high=%08x", req->count_high );
873 static void dump_create_pipe_request( const struct create_pipe_request *req )
875 fprintf( stderr, " inherit=%d", req->inherit );
878 static void dump_create_pipe_reply( const struct create_pipe_reply *req )
880 fprintf( stderr, " handle_read=%p,", req->handle_read );
881 fprintf( stderr, " handle_write=%p", req->handle_write );
884 static void dump_create_socket_request( const struct create_socket_request *req )
886 fprintf( stderr, " access=%08x,", req->access );
887 fprintf( stderr, " inherit=%d,", req->inherit );
888 fprintf( stderr, " family=%d,", req->family );
889 fprintf( stderr, " type=%d,", req->type );
890 fprintf( stderr, " protocol=%d,", req->protocol );
891 fprintf( stderr, " flags=%08x", req->flags );
894 static void dump_create_socket_reply( const struct create_socket_reply *req )
896 fprintf( stderr, " handle=%p", req->handle );
899 static void dump_accept_socket_request( const struct accept_socket_request *req )
901 fprintf( stderr, " lhandle=%p,", req->lhandle );
902 fprintf( stderr, " access=%08x,", req->access );
903 fprintf( stderr, " inherit=%d", req->inherit );
906 static void dump_accept_socket_reply( const struct accept_socket_reply *req )
908 fprintf( stderr, " handle=%p", req->handle );
911 static void dump_set_socket_event_request( const struct set_socket_event_request *req )
913 fprintf( stderr, " handle=%p,", req->handle );
914 fprintf( stderr, " mask=%08x,", req->mask );
915 fprintf( stderr, " event=%p,", req->event );
916 fprintf( stderr, " window=%p,", req->window );
917 fprintf( stderr, " msg=%08x", req->msg );
920 static void dump_get_socket_event_request( const struct get_socket_event_request *req )
922 fprintf( stderr, " handle=%p,", req->handle );
923 fprintf( stderr, " service=%d,", req->service );
924 fprintf( stderr, " c_event=%p", req->c_event );
927 static void dump_get_socket_event_reply( const struct get_socket_event_reply *req )
929 fprintf( stderr, " mask=%08x,", req->mask );
930 fprintf( stderr, " pmask=%08x,", req->pmask );
931 fprintf( stderr, " state=%08x,", req->state );
932 fprintf( stderr, " errors=" );
933 dump_varargs_ints( cur_size );
936 static void dump_enable_socket_event_request( const struct enable_socket_event_request *req )
938 fprintf( stderr, " handle=%p,", req->handle );
939 fprintf( stderr, " mask=%08x,", req->mask );
940 fprintf( stderr, " sstate=%08x,", req->sstate );
941 fprintf( stderr, " cstate=%08x", req->cstate );
944 static void dump_set_socket_deferred_request( const struct set_socket_deferred_request *req )
946 fprintf( stderr, " handle=%p,", req->handle );
947 fprintf( stderr, " deferred=%p", req->deferred );
950 static void dump_alloc_console_request( const struct alloc_console_request *req )
952 fprintf( stderr, " access=%08x,", req->access );
953 fprintf( stderr, " inherit=%d,", req->inherit );
954 fprintf( stderr, " pid=%08x", req->pid );
957 static void dump_alloc_console_reply( const struct alloc_console_reply *req )
959 fprintf( stderr, " handle_in=%p,", req->handle_in );
960 fprintf( stderr, " event=%p", req->event );
963 static void dump_free_console_request( const struct free_console_request *req )
967 static void dump_get_console_renderer_events_request( const struct get_console_renderer_events_request *req )
969 fprintf( stderr, " handle=%p", req->handle );
972 static void dump_get_console_renderer_events_reply( const struct get_console_renderer_events_reply *req )
974 fprintf( stderr, " data=" );
975 dump_varargs_bytes( cur_size );
978 static void dump_open_console_request( const struct open_console_request *req )
980 fprintf( stderr, " from=%d,", req->from );
981 fprintf( stderr, " access=%08x,", req->access );
982 fprintf( stderr, " inherit=%d,", req->inherit );
983 fprintf( stderr, " share=%d", req->share );
986 static void dump_open_console_reply( const struct open_console_reply *req )
988 fprintf( stderr, " handle=%p", req->handle );
991 static void dump_get_console_mode_request( const struct get_console_mode_request *req )
993 fprintf( stderr, " handle=%p", req->handle );
996 static void dump_get_console_mode_reply( const struct get_console_mode_reply *req )
998 fprintf( stderr, " mode=%d", req->mode );
1001 static void dump_set_console_mode_request( const struct set_console_mode_request *req )
1003 fprintf( stderr, " handle=%p,", req->handle );
1004 fprintf( stderr, " mode=%d", req->mode );
1007 static void dump_set_console_input_info_request( const struct set_console_input_info_request *req )
1009 fprintf( stderr, " handle=%p,", req->handle );
1010 fprintf( stderr, " mask=%d,", req->mask );
1011 fprintf( stderr, " active_sb=%p,", req->active_sb );
1012 fprintf( stderr, " history_mode=%d,", req->history_mode );
1013 fprintf( stderr, " history_size=%d,", req->history_size );
1014 fprintf( stderr, " title=" );
1015 dump_varargs_unicode_str( cur_size );
1018 static void dump_get_console_input_info_request( const struct get_console_input_info_request *req )
1020 fprintf( stderr, " handle=%p", req->handle );
1023 static void dump_get_console_input_info_reply( const struct get_console_input_info_reply *req )
1025 fprintf( stderr, " history_mode=%d,", req->history_mode );
1026 fprintf( stderr, " history_size=%d,", req->history_size );
1027 fprintf( stderr, " history_index=%d,", req->history_index );
1028 fprintf( stderr, " title=" );
1029 dump_varargs_unicode_str( cur_size );
1032 static void dump_append_console_input_history_request( const struct append_console_input_history_request *req )
1034 fprintf( stderr, " handle=%p,", req->handle );
1035 fprintf( stderr, " line=" );
1036 dump_varargs_unicode_str( cur_size );
1039 static void dump_get_console_input_history_request( const struct get_console_input_history_request *req )
1041 fprintf( stderr, " handle=%p,", req->handle );
1042 fprintf( stderr, " index=%d", req->index );
1045 static void dump_get_console_input_history_reply( const struct get_console_input_history_reply *req )
1047 fprintf( stderr, " total=%d,", req->total );
1048 fprintf( stderr, " line=" );
1049 dump_varargs_unicode_str( cur_size );
1052 static void dump_create_console_output_request( const struct create_console_output_request *req )
1054 fprintf( stderr, " handle_in=%p,", req->handle_in );
1055 fprintf( stderr, " access=%d,", req->access );
1056 fprintf( stderr, " share=%d,", req->share );
1057 fprintf( stderr, " inherit=%d", req->inherit );
1060 static void dump_create_console_output_reply( const struct create_console_output_reply *req )
1062 fprintf( stderr, " handle_out=%p", req->handle_out );
1065 static void dump_set_console_output_info_request( const struct set_console_output_info_request *req )
1067 fprintf( stderr, " handle=%p,", req->handle );
1068 fprintf( stderr, " mask=%d,", req->mask );
1069 fprintf( stderr, " cursor_size=%d,", req->cursor_size );
1070 fprintf( stderr, " cursor_visible=%d,", req->cursor_visible );
1071 fprintf( stderr, " cursor_x=%d,", req->cursor_x );
1072 fprintf( stderr, " cursor_y=%d,", req->cursor_y );
1073 fprintf( stderr, " width=%d,", req->width );
1074 fprintf( stderr, " height=%d,", req->height );
1075 fprintf( stderr, " attr=%d,", req->attr );
1076 fprintf( stderr, " win_left=%d,", req->win_left );
1077 fprintf( stderr, " win_top=%d,", req->win_top );
1078 fprintf( stderr, " win_right=%d,", req->win_right );
1079 fprintf( stderr, " win_bottom=%d,", req->win_bottom );
1080 fprintf( stderr, " max_width=%d,", req->max_width );
1081 fprintf( stderr, " max_height=%d", req->max_height );
1084 static void dump_get_console_output_info_request( const struct get_console_output_info_request *req )
1086 fprintf( stderr, " handle=%p", req->handle );
1089 static void dump_get_console_output_info_reply( const struct get_console_output_info_reply *req )
1091 fprintf( stderr, " cursor_size=%d,", req->cursor_size );
1092 fprintf( stderr, " cursor_visible=%d,", req->cursor_visible );
1093 fprintf( stderr, " cursor_x=%d,", req->cursor_x );
1094 fprintf( stderr, " cursor_y=%d,", req->cursor_y );
1095 fprintf( stderr, " width=%d,", req->width );
1096 fprintf( stderr, " height=%d,", req->height );
1097 fprintf( stderr, " attr=%d,", req->attr );
1098 fprintf( stderr, " win_left=%d,", req->win_left );
1099 fprintf( stderr, " win_top=%d,", req->win_top );
1100 fprintf( stderr, " win_right=%d,", req->win_right );
1101 fprintf( stderr, " win_bottom=%d,", req->win_bottom );
1102 fprintf( stderr, " max_width=%d,", req->max_width );
1103 fprintf( stderr, " max_height=%d", req->max_height );
1106 static void dump_write_console_input_request( const struct write_console_input_request *req )
1108 fprintf( stderr, " handle=%p,", req->handle );
1109 fprintf( stderr, " rec=" );
1110 dump_varargs_input_records( cur_size );
1113 static void dump_write_console_input_reply( const struct write_console_input_reply *req )
1115 fprintf( stderr, " written=%d", req->written );
1118 static void dump_read_console_input_request( const struct read_console_input_request *req )
1120 fprintf( stderr, " handle=%p,", req->handle );
1121 fprintf( stderr, " flush=%d", req->flush );
1124 static void dump_read_console_input_reply( const struct read_console_input_reply *req )
1126 fprintf( stderr, " read=%d,", req->read );
1127 fprintf( stderr, " rec=" );
1128 dump_varargs_input_records( cur_size );
1131 static void dump_write_console_output_request( const struct write_console_output_request *req )
1133 fprintf( stderr, " handle=%p,", req->handle );
1134 fprintf( stderr, " x=%d,", req->x );
1135 fprintf( stderr, " y=%d,", req->y );
1136 fprintf( stderr, " mode=%d,", req->mode );
1137 fprintf( stderr, " wrap=%d,", req->wrap );
1138 fprintf( stderr, " data=" );
1139 dump_varargs_bytes( cur_size );
1142 static void dump_write_console_output_reply( const struct write_console_output_reply *req )
1144 fprintf( stderr, " written=%d,", req->written );
1145 fprintf( stderr, " width=%d,", req->width );
1146 fprintf( stderr, " height=%d", req->height );
1149 static void dump_fill_console_output_request( const struct fill_console_output_request *req )
1151 fprintf( stderr, " handle=%p,", req->handle );
1152 fprintf( stderr, " x=%d,", req->x );
1153 fprintf( stderr, " y=%d,", req->y );
1154 fprintf( stderr, " mode=%d,", req->mode );
1155 fprintf( stderr, " count=%d,", req->count );
1156 fprintf( stderr, " wrap=%d,", req->wrap );
1157 fprintf( stderr, " data=" );
1158 dump_char_info( &req->data );
1161 static void dump_fill_console_output_reply( const struct fill_console_output_reply *req )
1163 fprintf( stderr, " written=%d", req->written );
1166 static void dump_read_console_output_request( const struct read_console_output_request *req )
1168 fprintf( stderr, " handle=%p,", req->handle );
1169 fprintf( stderr, " x=%d,", req->x );
1170 fprintf( stderr, " y=%d,", req->y );
1171 fprintf( stderr, " mode=%d,", req->mode );
1172 fprintf( stderr, " wrap=%d", req->wrap );
1175 static void dump_read_console_output_reply( const struct read_console_output_reply *req )
1177 fprintf( stderr, " width=%d,", req->width );
1178 fprintf( stderr, " height=%d,", req->height );
1179 fprintf( stderr, " data=" );
1180 dump_varargs_bytes( cur_size );
1183 static void dump_move_console_output_request( const struct move_console_output_request *req )
1185 fprintf( stderr, " handle=%p,", req->handle );
1186 fprintf( stderr, " x_src=%d,", req->x_src );
1187 fprintf( stderr, " y_src=%d,", req->y_src );
1188 fprintf( stderr, " x_dst=%d,", req->x_dst );
1189 fprintf( stderr, " y_dst=%d,", req->y_dst );
1190 fprintf( stderr, " w=%d,", req->w );
1191 fprintf( stderr, " h=%d", req->h );
1194 static void dump_send_console_signal_request( const struct send_console_signal_request *req )
1196 fprintf( stderr, " signal=%d,", req->signal );
1197 fprintf( stderr, " group_id=%08x", req->group_id );
1200 static void dump_create_change_notification_request( const struct create_change_notification_request *req )
1202 fprintf( stderr, " subtree=%d,", req->subtree );
1203 fprintf( stderr, " filter=%d", req->filter );
1206 static void dump_create_change_notification_reply( const struct create_change_notification_reply *req )
1208 fprintf( stderr, " handle=%p", req->handle );
1211 static void dump_create_mapping_request( const struct create_mapping_request *req )
1213 fprintf( stderr, " size_high=%d,", req->size_high );
1214 fprintf( stderr, " size_low=%d,", req->size_low );
1215 fprintf( stderr, " protect=%d,", req->protect );
1216 fprintf( stderr, " access=%08x,", req->access );
1217 fprintf( stderr, " inherit=%d,", req->inherit );
1218 fprintf( stderr, " file_handle=%p,", req->file_handle );
1219 fprintf( stderr, " name=" );
1220 dump_varargs_unicode_str( cur_size );
1223 static void dump_create_mapping_reply( const struct create_mapping_reply *req )
1225 fprintf( stderr, " handle=%p", req->handle );
1228 static void dump_open_mapping_request( const struct open_mapping_request *req )
1230 fprintf( stderr, " access=%08x,", req->access );
1231 fprintf( stderr, " inherit=%d,", req->inherit );
1232 fprintf( stderr, " name=" );
1233 dump_varargs_unicode_str( cur_size );
1236 static void dump_open_mapping_reply( const struct open_mapping_reply *req )
1238 fprintf( stderr, " handle=%p", req->handle );
1241 static void dump_get_mapping_info_request( const struct get_mapping_info_request *req )
1243 fprintf( stderr, " handle=%p", req->handle );
1246 static void dump_get_mapping_info_reply( const struct get_mapping_info_reply *req )
1248 fprintf( stderr, " size_high=%d,", req->size_high );
1249 fprintf( stderr, " size_low=%d,", req->size_low );
1250 fprintf( stderr, " protect=%d,", req->protect );
1251 fprintf( stderr, " header_size=%d,", req->header_size );
1252 fprintf( stderr, " base=%p,", req->base );
1253 fprintf( stderr, " shared_file=%p,", req->shared_file );
1254 fprintf( stderr, " shared_size=%d,", req->shared_size );
1255 fprintf( stderr, " drive_type=%d", req->drive_type );
1258 static void dump_create_device_request( const struct create_device_request *req )
1260 fprintf( stderr, " access=%08x,", req->access );
1261 fprintf( stderr, " inherit=%d,", req->inherit );
1262 fprintf( stderr, " id=%d", req->id );
1265 static void dump_create_device_reply( const struct create_device_reply *req )
1267 fprintf( stderr, " handle=%p", req->handle );
1270 static void dump_create_snapshot_request( const struct create_snapshot_request *req )
1272 fprintf( stderr, " inherit=%d,", req->inherit );
1273 fprintf( stderr, " flags=%d,", req->flags );
1274 fprintf( stderr, " pid=%08x", req->pid );
1277 static void dump_create_snapshot_reply( const struct create_snapshot_reply *req )
1279 fprintf( stderr, " handle=%p", req->handle );
1282 static void dump_next_process_request( const struct next_process_request *req )
1284 fprintf( stderr, " handle=%p,", req->handle );
1285 fprintf( stderr, " reset=%d", req->reset );
1288 static void dump_next_process_reply( const struct next_process_reply *req )
1290 fprintf( stderr, " count=%d,", req->count );
1291 fprintf( stderr, " pid=%08x,", req->pid );
1292 fprintf( stderr, " ppid=%08x,", req->ppid );
1293 fprintf( stderr, " heap=%p,", req->heap );
1294 fprintf( stderr, " module=%p,", req->module );
1295 fprintf( stderr, " threads=%d,", req->threads );
1296 fprintf( stderr, " priority=%d,", req->priority );
1297 fprintf( stderr, " filename=" );
1298 dump_varargs_string( cur_size );
1301 static void dump_next_thread_request( const struct next_thread_request *req )
1303 fprintf( stderr, " handle=%p,", req->handle );
1304 fprintf( stderr, " reset=%d", req->reset );
1307 static void dump_next_thread_reply( const struct next_thread_reply *req )
1309 fprintf( stderr, " count=%d,", req->count );
1310 fprintf( stderr, " pid=%08x,", req->pid );
1311 fprintf( stderr, " tid=%08x,", req->tid );
1312 fprintf( stderr, " base_pri=%d,", req->base_pri );
1313 fprintf( stderr, " delta_pri=%d", req->delta_pri );
1316 static void dump_next_module_request( const struct next_module_request *req )
1318 fprintf( stderr, " handle=%p,", req->handle );
1319 fprintf( stderr, " reset=%d", req->reset );
1322 static void dump_next_module_reply( const struct next_module_reply *req )
1324 fprintf( stderr, " pid=%08x,", req->pid );
1325 fprintf( stderr, " base=%p,", req->base );
1326 fprintf( stderr, " size=%d,", req->size );
1327 fprintf( stderr, " filename=" );
1328 dump_varargs_string( cur_size );
1331 static void dump_wait_debug_event_request( const struct wait_debug_event_request *req )
1333 fprintf( stderr, " get_handle=%d", req->get_handle );
1336 static void dump_wait_debug_event_reply( const struct wait_debug_event_reply *req )
1338 fprintf( stderr, " pid=%08x,", req->pid );
1339 fprintf( stderr, " tid=%08x,", req->tid );
1340 fprintf( stderr, " wait=%p,", req->wait );
1341 fprintf( stderr, " event=" );
1342 dump_varargs_debug_event( cur_size );
1345 static void dump_queue_exception_event_request( const struct queue_exception_event_request *req )
1347 fprintf( stderr, " first=%d,", req->first );
1348 fprintf( stderr, " record=" );
1349 dump_varargs_exc_event( cur_size );
1352 static void dump_queue_exception_event_reply( const struct queue_exception_event_reply *req )
1354 fprintf( stderr, " handle=%p", req->handle );
1357 static void dump_get_exception_status_request( const struct get_exception_status_request *req )
1359 fprintf( stderr, " handle=%p", req->handle );
1362 static void dump_get_exception_status_reply( const struct get_exception_status_reply *req )
1364 fprintf( stderr, " status=%d,", req->status );
1365 fprintf( stderr, " context=" );
1366 dump_varargs_context( cur_size );
1369 static void dump_output_debug_string_request( const struct output_debug_string_request *req )
1371 fprintf( stderr, " string=%p,", req->string );
1372 fprintf( stderr, " unicode=%d,", req->unicode );
1373 fprintf( stderr, " length=%d", req->length );
1376 static void dump_continue_debug_event_request( const struct continue_debug_event_request *req )
1378 fprintf( stderr, " pid=%08x,", req->pid );
1379 fprintf( stderr, " tid=%08x,", req->tid );
1380 fprintf( stderr, " status=%d", req->status );
1383 static void dump_debug_process_request( const struct debug_process_request *req )
1385 fprintf( stderr, " pid=%08x,", req->pid );
1386 fprintf( stderr, " attach=%d", req->attach );
1389 static void dump_debug_break_request( const struct debug_break_request *req )
1391 fprintf( stderr, " handle=%p", req->handle );
1394 static void dump_debug_break_reply( const struct debug_break_reply *req )
1396 fprintf( stderr, " self=%d", req->self );
1399 static void dump_set_debugger_kill_on_exit_request( const struct set_debugger_kill_on_exit_request *req )
1401 fprintf( stderr, " kill_on_exit=%d", req->kill_on_exit );
1404 static void dump_read_process_memory_request( const struct read_process_memory_request *req )
1406 fprintf( stderr, " handle=%p,", req->handle );
1407 fprintf( stderr, " addr=%p", req->addr );
1410 static void dump_read_process_memory_reply( const struct read_process_memory_reply *req )
1412 fprintf( stderr, " data=" );
1413 dump_varargs_bytes( cur_size );
1416 static void dump_write_process_memory_request( const struct write_process_memory_request *req )
1418 fprintf( stderr, " handle=%p,", req->handle );
1419 fprintf( stderr, " addr=%p,", req->addr );
1420 fprintf( stderr, " first_mask=%08x,", req->first_mask );
1421 fprintf( stderr, " last_mask=%08x,", req->last_mask );
1422 fprintf( stderr, " data=" );
1423 dump_varargs_bytes( cur_size );
1426 static void dump_create_key_request( const struct create_key_request *req )
1428 fprintf( stderr, " parent=%p,", req->parent );
1429 fprintf( stderr, " access=%08x,", req->access );
1430 fprintf( stderr, " options=%08x,", req->options );
1431 fprintf( stderr, " modif=%ld,", req->modif );
1432 fprintf( stderr, " namelen=%d,", req->namelen );
1433 fprintf( stderr, " name=" );
1434 dump_varargs_unicode_str( min(cur_size,req->namelen) );
1435 fputc( ',', stderr );
1436 fprintf( stderr, " class=" );
1437 dump_varargs_unicode_str( cur_size );
1440 static void dump_create_key_reply( const struct create_key_reply *req )
1442 fprintf( stderr, " hkey=%p,", req->hkey );
1443 fprintf( stderr, " created=%d", req->created );
1446 static void dump_open_key_request( const struct open_key_request *req )
1448 fprintf( stderr, " parent=%p,", req->parent );
1449 fprintf( stderr, " access=%08x,", req->access );
1450 fprintf( stderr, " name=" );
1451 dump_varargs_unicode_str( cur_size );
1454 static void dump_open_key_reply( const struct open_key_reply *req )
1456 fprintf( stderr, " hkey=%p", req->hkey );
1459 static void dump_delete_key_request( const struct delete_key_request *req )
1461 fprintf( stderr, " hkey=%p", req->hkey );
1464 static void dump_enum_key_request( const struct enum_key_request *req )
1466 fprintf( stderr, " hkey=%p,", req->hkey );
1467 fprintf( stderr, " index=%d,", req->index );
1468 fprintf( stderr, " info_class=%d", req->info_class );
1471 static void dump_enum_key_reply( const struct enum_key_reply *req )
1473 fprintf( stderr, " subkeys=%d,", req->subkeys );
1474 fprintf( stderr, " max_subkey=%d,", req->max_subkey );
1475 fprintf( stderr, " max_class=%d,", req->max_class );
1476 fprintf( stderr, " values=%d,", req->values );
1477 fprintf( stderr, " max_value=%d,", req->max_value );
1478 fprintf( stderr, " max_data=%d,", req->max_data );
1479 fprintf( stderr, " modif=%ld,", req->modif );
1480 fprintf( stderr, " total=%d,", req->total );
1481 fprintf( stderr, " namelen=%d,", req->namelen );
1482 fprintf( stderr, " name=" );
1483 dump_varargs_unicode_str( min(cur_size,req->namelen) );
1484 fputc( ',', stderr );
1485 fprintf( stderr, " class=" );
1486 dump_varargs_unicode_str( cur_size );
1489 static void dump_set_key_value_request( const struct set_key_value_request *req )
1491 fprintf( stderr, " hkey=%p,", req->hkey );
1492 fprintf( stderr, " type=%d,", req->type );
1493 fprintf( stderr, " namelen=%d,", req->namelen );
1494 fprintf( stderr, " name=" );
1495 dump_varargs_unicode_str( min(cur_size,req->namelen) );
1496 fputc( ',', stderr );
1497 fprintf( stderr, " data=" );
1498 dump_varargs_bytes( cur_size );
1501 static void dump_get_key_value_request( const struct get_key_value_request *req )
1503 fprintf( stderr, " hkey=%p,", req->hkey );
1504 fprintf( stderr, " name=" );
1505 dump_varargs_unicode_str( cur_size );
1508 static void dump_get_key_value_reply( const struct get_key_value_reply *req )
1510 fprintf( stderr, " type=%d,", req->type );
1511 fprintf( stderr, " total=%d,", req->total );
1512 fprintf( stderr, " data=" );
1513 dump_varargs_bytes( cur_size );
1516 static void dump_enum_key_value_request( const struct enum_key_value_request *req )
1518 fprintf( stderr, " hkey=%p,", req->hkey );
1519 fprintf( stderr, " index=%d,", req->index );
1520 fprintf( stderr, " info_class=%d", req->info_class );
1523 static void dump_enum_key_value_reply( const struct enum_key_value_reply *req )
1525 fprintf( stderr, " type=%d,", req->type );
1526 fprintf( stderr, " total=%d,", req->total );
1527 fprintf( stderr, " namelen=%d,", req->namelen );
1528 fprintf( stderr, " name=" );
1529 dump_varargs_unicode_str( min(cur_size,req->namelen) );
1530 fputc( ',', stderr );
1531 fprintf( stderr, " data=" );
1532 dump_varargs_bytes( cur_size );
1535 static void dump_delete_key_value_request( const struct delete_key_value_request *req )
1537 fprintf( stderr, " hkey=%p,", req->hkey );
1538 fprintf( stderr, " name=" );
1539 dump_varargs_unicode_str( cur_size );
1542 static void dump_load_registry_request( const struct load_registry_request *req )
1544 fprintf( stderr, " hkey=%p,", req->hkey );
1545 fprintf( stderr, " file=%p,", req->file );
1546 fprintf( stderr, " name=" );
1547 dump_varargs_unicode_str( cur_size );
1550 static void dump_save_registry_request( const struct save_registry_request *req )
1552 fprintf( stderr, " hkey=%p,", req->hkey );
1553 fprintf( stderr, " file=%p", req->file );
1556 static void dump_save_registry_atexit_request( const struct save_registry_atexit_request *req )
1558 fprintf( stderr, " hkey=%p,", req->hkey );
1559 fprintf( stderr, " file=" );
1560 dump_varargs_string( cur_size );
1563 static void dump_set_registry_levels_request( const struct set_registry_levels_request *req )
1565 fprintf( stderr, " current=%d,", req->current );
1566 fprintf( stderr, " saving=%d,", req->saving );
1567 fprintf( stderr, " period=%d", req->period );
1570 static void dump_create_timer_request( const struct create_timer_request *req )
1572 fprintf( stderr, " inherit=%d,", req->inherit );
1573 fprintf( stderr, " manual=%d,", req->manual );
1574 fprintf( stderr, " name=" );
1575 dump_varargs_unicode_str( cur_size );
1578 static void dump_create_timer_reply( const struct create_timer_reply *req )
1580 fprintf( stderr, " handle=%p", req->handle );
1583 static void dump_open_timer_request( const struct open_timer_request *req )
1585 fprintf( stderr, " access=%08x,", req->access );
1586 fprintf( stderr, " inherit=%d,", req->inherit );
1587 fprintf( stderr, " name=" );
1588 dump_varargs_unicode_str( cur_size );
1591 static void dump_open_timer_reply( const struct open_timer_reply *req )
1593 fprintf( stderr, " handle=%p", req->handle );
1596 static void dump_set_timer_request( const struct set_timer_request *req )
1598 fprintf( stderr, " handle=%p,", req->handle );
1599 fprintf( stderr, " sec=%d,", req->sec );
1600 fprintf( stderr, " usec=%d,", req->usec );
1601 fprintf( stderr, " period=%d,", req->period );
1602 fprintf( stderr, " callback=%p,", req->callback );
1603 fprintf( stderr, " arg=%p", req->arg );
1606 static void dump_cancel_timer_request( const struct cancel_timer_request *req )
1608 fprintf( stderr, " handle=%p", req->handle );
1611 static void dump_get_thread_context_request( const struct get_thread_context_request *req )
1613 fprintf( stderr, " handle=%p,", req->handle );
1614 fprintf( stderr, " flags=%08x", req->flags );
1617 static void dump_get_thread_context_reply( const struct get_thread_context_reply *req )
1619 fprintf( stderr, " context=" );
1620 dump_varargs_context( cur_size );
1623 static void dump_set_thread_context_request( const struct set_thread_context_request *req )
1625 fprintf( stderr, " handle=%p,", req->handle );
1626 fprintf( stderr, " flags=%08x,", req->flags );
1627 fprintf( stderr, " context=" );
1628 dump_varargs_context( cur_size );
1631 static void dump_get_selector_entry_request( const struct get_selector_entry_request *req )
1633 fprintf( stderr, " handle=%p,", req->handle );
1634 fprintf( stderr, " entry=%d", req->entry );
1637 static void dump_get_selector_entry_reply( const struct get_selector_entry_reply *req )
1639 fprintf( stderr, " base=%08x,", req->base );
1640 fprintf( stderr, " limit=%08x,", req->limit );
1641 fprintf( stderr, " flags=%02x", req->flags );
1644 static void dump_add_atom_request( const struct add_atom_request *req )
1646 fprintf( stderr, " local=%d,", req->local );
1647 fprintf( stderr, " name=" );
1648 dump_varargs_unicode_str( cur_size );
1651 static void dump_add_atom_reply( const struct add_atom_reply *req )
1653 fprintf( stderr, " atom=%04x", req->atom );
1656 static void dump_delete_atom_request( const struct delete_atom_request *req )
1658 fprintf( stderr, " atom=%04x,", req->atom );
1659 fprintf( stderr, " local=%d", req->local );
1662 static void dump_find_atom_request( const struct find_atom_request *req )
1664 fprintf( stderr, " local=%d,", req->local );
1665 fprintf( stderr, " name=" );
1666 dump_varargs_unicode_str( cur_size );
1669 static void dump_find_atom_reply( const struct find_atom_reply *req )
1671 fprintf( stderr, " atom=%04x", req->atom );
1674 static void dump_get_atom_name_request( const struct get_atom_name_request *req )
1676 fprintf( stderr, " atom=%04x,", req->atom );
1677 fprintf( stderr, " local=%d", req->local );
1680 static void dump_get_atom_name_reply( const struct get_atom_name_reply *req )
1682 fprintf( stderr, " count=%d,", req->count );
1683 fprintf( stderr, " name=" );
1684 dump_varargs_unicode_str( cur_size );
1687 static void dump_init_atom_table_request( const struct init_atom_table_request *req )
1689 fprintf( stderr, " entries=%d", req->entries );
1692 static void dump_get_msg_queue_request( const struct get_msg_queue_request *req )
1696 static void dump_get_msg_queue_reply( const struct get_msg_queue_reply *req )
1698 fprintf( stderr, " handle=%p", req->handle );
1701 static void dump_set_queue_mask_request( const struct set_queue_mask_request *req )
1703 fprintf( stderr, " wake_mask=%08x,", req->wake_mask );
1704 fprintf( stderr, " changed_mask=%08x,", req->changed_mask );
1705 fprintf( stderr, " skip_wait=%d", req->skip_wait );
1708 static void dump_set_queue_mask_reply( const struct set_queue_mask_reply *req )
1710 fprintf( stderr, " wake_bits=%08x,", req->wake_bits );
1711 fprintf( stderr, " changed_bits=%08x", req->changed_bits );
1714 static void dump_get_queue_status_request( const struct get_queue_status_request *req )
1716 fprintf( stderr, " clear=%d", req->clear );
1719 static void dump_get_queue_status_reply( const struct get_queue_status_reply *req )
1721 fprintf( stderr, " wake_bits=%08x,", req->wake_bits );
1722 fprintf( stderr, " changed_bits=%08x", req->changed_bits );
1725 static void dump_wait_input_idle_request( const struct wait_input_idle_request *req )
1727 fprintf( stderr, " handle=%p,", req->handle );
1728 fprintf( stderr, " timeout=%d", req->timeout );
1731 static void dump_wait_input_idle_reply( const struct wait_input_idle_reply *req )
1733 fprintf( stderr, " event=%p", req->event );
1736 static void dump_send_message_request( const struct send_message_request *req )
1738 fprintf( stderr, " id=%08x,", req->id );
1739 fprintf( stderr, " type=%d,", req->type );
1740 fprintf( stderr, " win=%p,", req->win );
1741 fprintf( stderr, " msg=%08x,", req->msg );
1742 fprintf( stderr, " wparam=%08x,", req->wparam );
1743 fprintf( stderr, " lparam=%08x,", req->lparam );
1744 fprintf( stderr, " x=%d,", req->x );
1745 fprintf( stderr, " y=%d,", req->y );
1746 fprintf( stderr, " time=%08x,", req->time );
1747 fprintf( stderr, " info=%08x,", req->info );
1748 fprintf( stderr, " timeout=%d,", req->timeout );
1749 fprintf( stderr, " data=" );
1750 dump_varargs_bytes( cur_size );
1753 static void dump_get_message_request( const struct get_message_request *req )
1755 fprintf( stderr, " flags=%d,", req->flags );
1756 fprintf( stderr, " get_win=%p,", req->get_win );
1757 fprintf( stderr, " get_first=%08x,", req->get_first );
1758 fprintf( stderr, " get_last=%08x", req->get_last );
1761 static void dump_get_message_reply( const struct get_message_reply *req )
1763 fprintf( stderr, " type=%d,", req->type );
1764 fprintf( stderr, " win=%p,", req->win );
1765 fprintf( stderr, " msg=%08x,", req->msg );
1766 fprintf( stderr, " wparam=%08x,", req->wparam );
1767 fprintf( stderr, " lparam=%08x,", req->lparam );
1768 fprintf( stderr, " x=%d,", req->x );
1769 fprintf( stderr, " y=%d,", req->y );
1770 fprintf( stderr, " time=%08x,", req->time );
1771 fprintf( stderr, " info=%08x,", req->info );
1772 fprintf( stderr, " total=%d,", req->total );
1773 fprintf( stderr, " data=" );
1774 dump_varargs_bytes( cur_size );
1777 static void dump_reply_message_request( const struct reply_message_request *req )
1779 fprintf( stderr, " result=%08x,", req->result );
1780 fprintf( stderr, " remove=%d,", req->remove );
1781 fprintf( stderr, " data=" );
1782 dump_varargs_bytes( cur_size );
1785 static void dump_get_message_reply_request( const struct get_message_reply_request *req )
1787 fprintf( stderr, " cancel=%d", req->cancel );
1790 static void dump_get_message_reply_reply( const struct get_message_reply_reply *req )
1792 fprintf( stderr, " result=%08x,", req->result );
1793 fprintf( stderr, " data=" );
1794 dump_varargs_bytes( cur_size );
1797 static void dump_set_win_timer_request( const struct set_win_timer_request *req )
1799 fprintf( stderr, " win=%p,", req->win );
1800 fprintf( stderr, " msg=%08x,", req->msg );
1801 fprintf( stderr, " id=%08x,", req->id );
1802 fprintf( stderr, " rate=%08x,", req->rate );
1803 fprintf( stderr, " lparam=%08x", req->lparam );
1806 static void dump_kill_win_timer_request( const struct kill_win_timer_request *req )
1808 fprintf( stderr, " win=%p,", req->win );
1809 fprintf( stderr, " msg=%08x,", req->msg );
1810 fprintf( stderr, " id=%08x", req->id );
1813 static void dump_create_serial_request( const struct create_serial_request *req )
1815 fprintf( stderr, " access=%08x,", req->access );
1816 fprintf( stderr, " inherit=%d,", req->inherit );
1817 fprintf( stderr, " attributes=%08x,", req->attributes );
1818 fprintf( stderr, " sharing=%08x,", req->sharing );
1819 fprintf( stderr, " name=" );
1820 dump_varargs_string( cur_size );
1823 static void dump_create_serial_reply( const struct create_serial_reply *req )
1825 fprintf( stderr, " handle=%p", req->handle );
1828 static void dump_get_serial_info_request( const struct get_serial_info_request *req )
1830 fprintf( stderr, " handle=%p", req->handle );
1833 static void dump_get_serial_info_reply( const struct get_serial_info_reply *req )
1835 fprintf( stderr, " readinterval=%08x,", req->readinterval );
1836 fprintf( stderr, " readconst=%08x,", req->readconst );
1837 fprintf( stderr, " readmult=%08x,", req->readmult );
1838 fprintf( stderr, " writeconst=%08x,", req->writeconst );
1839 fprintf( stderr, " writemult=%08x,", req->writemult );
1840 fprintf( stderr, " eventmask=%08x,", req->eventmask );
1841 fprintf( stderr, " commerror=%08x", req->commerror );
1844 static void dump_set_serial_info_request( const struct set_serial_info_request *req )
1846 fprintf( stderr, " handle=%p,", req->handle );
1847 fprintf( stderr, " flags=%d,", req->flags );
1848 fprintf( stderr, " readinterval=%08x,", req->readinterval );
1849 fprintf( stderr, " readconst=%08x,", req->readconst );
1850 fprintf( stderr, " readmult=%08x,", req->readmult );
1851 fprintf( stderr, " writeconst=%08x,", req->writeconst );
1852 fprintf( stderr, " writemult=%08x,", req->writemult );
1853 fprintf( stderr, " eventmask=%08x,", req->eventmask );
1854 fprintf( stderr, " commerror=%08x", req->commerror );
1857 static void dump_register_async_request( const struct register_async_request *req )
1859 fprintf( stderr, " handle=%p,", req->handle );
1860 fprintf( stderr, " type=%d,", req->type );
1861 fprintf( stderr, " overlapped=%p,", req->overlapped );
1862 fprintf( stderr, " count=%d,", req->count );
1863 fprintf( stderr, " status=%08x", req->status );
1866 static void dump_create_named_pipe_request( const struct create_named_pipe_request *req )
1868 fprintf( stderr, " openmode=%08x,", req->openmode );
1869 fprintf( stderr, " pipemode=%08x,", req->pipemode );
1870 fprintf( stderr, " maxinstances=%08x,", req->maxinstances );
1871 fprintf( stderr, " outsize=%08x,", req->outsize );
1872 fprintf( stderr, " insize=%08x,", req->insize );
1873 fprintf( stderr, " timeout=%08x,", req->timeout );
1874 fprintf( stderr, " name=" );
1875 dump_varargs_unicode_str( cur_size );
1878 static void dump_create_named_pipe_reply( const struct create_named_pipe_reply *req )
1880 fprintf( stderr, " handle=%p", req->handle );
1883 static void dump_open_named_pipe_request( const struct open_named_pipe_request *req )
1885 fprintf( stderr, " access=%08x,", req->access );
1886 fprintf( stderr, " name=" );
1887 dump_varargs_unicode_str( cur_size );
1890 static void dump_open_named_pipe_reply( const struct open_named_pipe_reply *req )
1892 fprintf( stderr, " handle=%p", req->handle );
1895 static void dump_connect_named_pipe_request( const struct connect_named_pipe_request *req )
1897 fprintf( stderr, " handle=%p,", req->handle );
1898 fprintf( stderr, " overlapped=%p,", req->overlapped );
1899 fprintf( stderr, " func=%p", req->func );
1902 static void dump_wait_named_pipe_request( const struct wait_named_pipe_request *req )
1904 fprintf( stderr, " timeout=%08x,", req->timeout );
1905 fprintf( stderr, " overlapped=%p,", req->overlapped );
1906 fprintf( stderr, " func=%p,", req->func );
1907 fprintf( stderr, " name=" );
1908 dump_varargs_unicode_str( cur_size );
1911 static void dump_disconnect_named_pipe_request( const struct disconnect_named_pipe_request *req )
1913 fprintf( stderr, " handle=%p", req->handle );
1916 static void dump_get_named_pipe_info_request( const struct get_named_pipe_info_request *req )
1918 fprintf( stderr, " handle=%p", req->handle );
1921 static void dump_get_named_pipe_info_reply( const struct get_named_pipe_info_reply *req )
1923 fprintf( stderr, " flags=%08x,", req->flags );
1924 fprintf( stderr, " maxinstances=%08x,", req->maxinstances );
1925 fprintf( stderr, " outsize=%08x,", req->outsize );
1926 fprintf( stderr, " insize=%08x", req->insize );
1929 static void dump_create_smb_request( const struct create_smb_request *req )
1931 fprintf( stderr, " fd=%d,", req->fd );
1932 fprintf( stderr, " tree_id=%08x,", req->tree_id );
1933 fprintf( stderr, " user_id=%08x,", req->user_id );
1934 fprintf( stderr, " file_id=%08x,", req->file_id );
1935 fprintf( stderr, " dialect=%08x", req->dialect );
1938 static void dump_create_smb_reply( const struct create_smb_reply *req )
1940 fprintf( stderr, " handle=%p", req->handle );
1943 static void dump_get_smb_info_request( const struct get_smb_info_request *req )
1945 fprintf( stderr, " handle=%p,", req->handle );
1946 fprintf( stderr, " flags=%08x,", req->flags );
1947 fprintf( stderr, " offset=%08x", req->offset );
1950 static void dump_get_smb_info_reply( const struct get_smb_info_reply *req )
1952 fprintf( stderr, " tree_id=%08x,", req->tree_id );
1953 fprintf( stderr, " user_id=%08x,", req->user_id );
1954 fprintf( stderr, " dialect=%08x,", req->dialect );
1955 fprintf( stderr, " file_id=%08x,", req->file_id );
1956 fprintf( stderr, " offset=%08x", req->offset );
1959 static void dump_create_window_request( const struct create_window_request *req )
1961 fprintf( stderr, " parent=%p,", req->parent );
1962 fprintf( stderr, " owner=%p,", req->owner );
1963 fprintf( stderr, " atom=%04x", req->atom );
1966 static void dump_create_window_reply( const struct create_window_reply *req )
1968 fprintf( stderr, " handle=%p", req->handle );
1971 static void dump_link_window_request( const struct link_window_request *req )
1973 fprintf( stderr, " handle=%p,", req->handle );
1974 fprintf( stderr, " parent=%p,", req->parent );
1975 fprintf( stderr, " previous=%p", req->previous );
1978 static void dump_link_window_reply( const struct link_window_reply *req )
1980 fprintf( stderr, " full_parent=%p", req->full_parent );
1983 static void dump_destroy_window_request( const struct destroy_window_request *req )
1985 fprintf( stderr, " handle=%p", req->handle );
1988 static void dump_set_window_owner_request( const struct set_window_owner_request *req )
1990 fprintf( stderr, " handle=%p,", req->handle );
1991 fprintf( stderr, " owner=%p", req->owner );
1994 static void dump_set_window_owner_reply( const struct set_window_owner_reply *req )
1996 fprintf( stderr, " full_owner=%p,", req->full_owner );
1997 fprintf( stderr, " prev_owner=%p", req->prev_owner );
2000 static void dump_get_window_info_request( const struct get_window_info_request *req )
2002 fprintf( stderr, " handle=%p", req->handle );
2005 static void dump_get_window_info_reply( const struct get_window_info_reply *req )
2007 fprintf( stderr, " full_handle=%p,", req->full_handle );
2008 fprintf( stderr, " last_active=%p,", req->last_active );
2009 fprintf( stderr, " pid=%08x,", req->pid );
2010 fprintf( stderr, " tid=%08x,", req->tid );
2011 fprintf( stderr, " atom=%04x", req->atom );
2014 static void dump_set_window_info_request( const struct set_window_info_request *req )
2016 fprintf( stderr, " handle=%p,", req->handle );
2017 fprintf( stderr, " flags=%08x,", req->flags );
2018 fprintf( stderr, " style=%08x,", req->style );
2019 fprintf( stderr, " ex_style=%08x,", req->ex_style );
2020 fprintf( stderr, " id=%08x,", req->id );
2021 fprintf( stderr, " instance=%p,", req->instance );
2022 fprintf( stderr, " user_data=%p", req->user_data );
2025 static void dump_set_window_info_reply( const struct set_window_info_reply *req )
2027 fprintf( stderr, " old_style=%08x,", req->old_style );
2028 fprintf( stderr, " old_ex_style=%08x,", req->old_ex_style );
2029 fprintf( stderr, " old_id=%08x,", req->old_id );
2030 fprintf( stderr, " old_instance=%p,", req->old_instance );
2031 fprintf( stderr, " old_user_data=%p", req->old_user_data );
2034 static void dump_get_window_parents_request( const struct get_window_parents_request *req )
2036 fprintf( stderr, " handle=%p", req->handle );
2039 static void dump_get_window_parents_reply( const struct get_window_parents_reply *req )
2041 fprintf( stderr, " count=%d,", req->count );
2042 fprintf( stderr, " parents=" );
2043 dump_varargs_user_handles( cur_size );
2046 static void dump_get_window_children_request( const struct get_window_children_request *req )
2048 fprintf( stderr, " parent=%p,", req->parent );
2049 fprintf( stderr, " atom=%04x,", req->atom );
2050 fprintf( stderr, " tid=%08x", req->tid );
2053 static void dump_get_window_children_reply( const struct get_window_children_reply *req )
2055 fprintf( stderr, " count=%d,", req->count );
2056 fprintf( stderr, " children=" );
2057 dump_varargs_user_handles( cur_size );
2060 static void dump_get_window_tree_request( const struct get_window_tree_request *req )
2062 fprintf( stderr, " handle=%p", req->handle );
2065 static void dump_get_window_tree_reply( const struct get_window_tree_reply *req )
2067 fprintf( stderr, " parent=%p,", req->parent );
2068 fprintf( stderr, " owner=%p,", req->owner );
2069 fprintf( stderr, " next_sibling=%p,", req->next_sibling );
2070 fprintf( stderr, " prev_sibling=%p,", req->prev_sibling );
2071 fprintf( stderr, " first_sibling=%p,", req->first_sibling );
2072 fprintf( stderr, " last_sibling=%p,", req->last_sibling );
2073 fprintf( stderr, " first_child=%p,", req->first_child );
2074 fprintf( stderr, " last_child=%p", req->last_child );
2077 static void dump_set_window_rectangles_request( const struct set_window_rectangles_request *req )
2079 fprintf( stderr, " handle=%p,", req->handle );
2080 fprintf( stderr, " window=" );
2081 dump_rectangle( &req->window );
2082 fprintf( stderr, "," );
2083 fprintf( stderr, " client=" );
2084 dump_rectangle( &req->client );
2087 static void dump_get_window_rectangles_request( const struct get_window_rectangles_request *req )
2089 fprintf( stderr, " handle=%p", req->handle );
2092 static void dump_get_window_rectangles_reply( const struct get_window_rectangles_reply *req )
2094 fprintf( stderr, " window=" );
2095 dump_rectangle( &req->window );
2096 fprintf( stderr, "," );
2097 fprintf( stderr, " client=" );
2098 dump_rectangle( &req->client );
2101 static void dump_get_window_text_request( const struct get_window_text_request *req )
2103 fprintf( stderr, " handle=%p", req->handle );
2106 static void dump_get_window_text_reply( const struct get_window_text_reply *req )
2108 fprintf( stderr, " text=" );
2109 dump_varargs_unicode_str( cur_size );
2112 static void dump_set_window_text_request( const struct set_window_text_request *req )
2114 fprintf( stderr, " handle=%p,", req->handle );
2115 fprintf( stderr, " text=" );
2116 dump_varargs_unicode_str( cur_size );
2119 static void dump_inc_window_paint_count_request( const struct inc_window_paint_count_request *req )
2121 fprintf( stderr, " handle=%p,", req->handle );
2122 fprintf( stderr, " incr=%d", req->incr );
2125 static void dump_get_windows_offset_request( const struct get_windows_offset_request *req )
2127 fprintf( stderr, " from=%p,", req->from );
2128 fprintf( stderr, " to=%p", req->to );
2131 static void dump_get_windows_offset_reply( const struct get_windows_offset_reply *req )
2133 fprintf( stderr, " x=%d,", req->x );
2134 fprintf( stderr, " y=%d", req->y );
2137 static void dump_set_window_property_request( const struct set_window_property_request *req )
2139 fprintf( stderr, " window=%p,", req->window );
2140 fprintf( stderr, " atom=%04x,", req->atom );
2141 fprintf( stderr, " string=%d,", req->string );
2142 fprintf( stderr, " handle=%p", req->handle );
2145 static void dump_remove_window_property_request( const struct remove_window_property_request *req )
2147 fprintf( stderr, " window=%p,", req->window );
2148 fprintf( stderr, " atom=%04x", req->atom );
2151 static void dump_remove_window_property_reply( const struct remove_window_property_reply *req )
2153 fprintf( stderr, " handle=%p", req->handle );
2156 static void dump_get_window_property_request( const struct get_window_property_request *req )
2158 fprintf( stderr, " window=%p,", req->window );
2159 fprintf( stderr, " atom=%04x", req->atom );
2162 static void dump_get_window_property_reply( const struct get_window_property_reply *req )
2164 fprintf( stderr, " handle=%p", req->handle );
2167 static void dump_get_window_properties_request( const struct get_window_properties_request *req )
2169 fprintf( stderr, " window=%p", req->window );
2172 static void dump_get_window_properties_reply( const struct get_window_properties_reply *req )
2174 fprintf( stderr, " total=%d,", req->total );
2175 fprintf( stderr, " props=" );
2176 dump_varargs_properties( cur_size );
2179 static void dump_attach_thread_input_request( const struct attach_thread_input_request *req )
2181 fprintf( stderr, " tid_from=%08x,", req->tid_from );
2182 fprintf( stderr, " tid_to=%08x,", req->tid_to );
2183 fprintf( stderr, " attach=%d", req->attach );
2186 static void dump_get_thread_input_request( const struct get_thread_input_request *req )
2188 fprintf( stderr, " tid=%08x", req->tid );
2191 static void dump_get_thread_input_reply( const struct get_thread_input_reply *req )
2193 fprintf( stderr, " focus=%p,", req->focus );
2194 fprintf( stderr, " capture=%p,", req->capture );
2195 fprintf( stderr, " active=%p,", req->active );
2196 fprintf( stderr, " foreground=%p,", req->foreground );
2197 fprintf( stderr, " menu_owner=%p,", req->menu_owner );
2198 fprintf( stderr, " move_size=%p,", req->move_size );
2199 fprintf( stderr, " caret=%p,", req->caret );
2200 fprintf( stderr, " rect=" );
2201 dump_rectangle( &req->rect );
2204 static void dump_set_foreground_window_request( const struct set_foreground_window_request *req )
2206 fprintf( stderr, " handle=%p", req->handle );
2209 static void dump_set_foreground_window_reply( const struct set_foreground_window_reply *req )
2211 fprintf( stderr, " previous=%p,", req->previous );
2212 fprintf( stderr, " send_msg_old=%d,", req->send_msg_old );
2213 fprintf( stderr, " send_msg_new=%d", req->send_msg_new );
2216 static void dump_set_focus_window_request( const struct set_focus_window_request *req )
2218 fprintf( stderr, " handle=%p", req->handle );
2221 static void dump_set_focus_window_reply( const struct set_focus_window_reply *req )
2223 fprintf( stderr, " previous=%p", req->previous );
2226 static void dump_set_active_window_request( const struct set_active_window_request *req )
2228 fprintf( stderr, " handle=%p", req->handle );
2231 static void dump_set_active_window_reply( const struct set_active_window_reply *req )
2233 fprintf( stderr, " previous=%p", req->previous );
2236 static void dump_set_capture_window_request( const struct set_capture_window_request *req )
2238 fprintf( stderr, " handle=%p,", req->handle );
2239 fprintf( stderr, " flags=%08x", req->flags );
2242 static void dump_set_capture_window_reply( const struct set_capture_window_reply *req )
2244 fprintf( stderr, " previous=%p,", req->previous );
2245 fprintf( stderr, " full_handle=%p", req->full_handle );
2248 static void dump_set_caret_window_request( const struct set_caret_window_request *req )
2250 fprintf( stderr, " handle=%p,", req->handle );
2251 fprintf( stderr, " width=%d,", req->width );
2252 fprintf( stderr, " height=%d", req->height );
2255 static void dump_set_caret_window_reply( const struct set_caret_window_reply *req )
2257 fprintf( stderr, " previous=%p,", req->previous );
2258 fprintf( stderr, " old_rect=" );
2259 dump_rectangle( &req->old_rect );
2260 fprintf( stderr, "," );
2261 fprintf( stderr, " old_hide=%d,", req->old_hide );
2262 fprintf( stderr, " old_state=%d", req->old_state );
2265 static void dump_set_caret_info_request( const struct set_caret_info_request *req )
2267 fprintf( stderr, " flags=%08x,", req->flags );
2268 fprintf( stderr, " handle=%p,", req->handle );
2269 fprintf( stderr, " x=%d,", req->x );
2270 fprintf( stderr, " y=%d,", req->y );
2271 fprintf( stderr, " hide=%d,", req->hide );
2272 fprintf( stderr, " state=%d", req->state );
2275 static void dump_set_caret_info_reply( const struct set_caret_info_reply *req )
2277 fprintf( stderr, " full_handle=%p,", req->full_handle );
2278 fprintf( stderr, " old_rect=" );
2279 dump_rectangle( &req->old_rect );
2280 fprintf( stderr, "," );
2281 fprintf( stderr, " old_hide=%d,", req->old_hide );
2282 fprintf( stderr, " old_state=%d", req->old_state );
2285 static void dump_set_hook_request( const struct set_hook_request *req )
2287 fprintf( stderr, " id=%d,", req->id );
2288 fprintf( stderr, " tid=%08x,", req->tid );
2289 fprintf( stderr, " proc=%p,", req->proc );
2290 fprintf( stderr, " unicode=%d,", req->unicode );
2291 fprintf( stderr, " module=" );
2292 dump_varargs_unicode_str( cur_size );
2295 static void dump_set_hook_reply( const struct set_hook_reply *req )
2297 fprintf( stderr, " handle=%p", req->handle );
2300 static void dump_remove_hook_request( const struct remove_hook_request *req )
2302 fprintf( stderr, " handle=%p,", req->handle );
2303 fprintf( stderr, " id=%d,", req->id );
2304 fprintf( stderr, " proc=%p", req->proc );
2307 static void dump_start_hook_chain_request( const struct start_hook_chain_request *req )
2309 fprintf( stderr, " id=%d", req->id );
2312 static void dump_start_hook_chain_reply( const struct start_hook_chain_reply *req )
2314 fprintf( stderr, " handle=%p,", req->handle );
2315 fprintf( stderr, " proc=%p,", req->proc );
2316 fprintf( stderr, " unicode=%d,", req->unicode );
2317 fprintf( stderr, " module=" );
2318 dump_varargs_unicode_str( cur_size );
2321 static void dump_finish_hook_chain_request( const struct finish_hook_chain_request *req )
2323 fprintf( stderr, " id=%d", req->id );
2326 static void dump_get_next_hook_request( const struct get_next_hook_request *req )
2328 fprintf( stderr, " handle=%p", req->handle );
2331 static void dump_get_next_hook_reply( const struct get_next_hook_reply *req )
2333 fprintf( stderr, " next=%p,", req->next );
2334 fprintf( stderr, " id=%d,", req->id );
2335 fprintf( stderr, " proc=%p,", req->proc );
2336 fprintf( stderr, " prev_unicode=%d,", req->prev_unicode );
2337 fprintf( stderr, " next_unicode=%d,", req->next_unicode );
2338 fprintf( stderr, " module=" );
2339 dump_varargs_unicode_str( cur_size );
2342 static const dump_func req_dumpers[REQ_NB_REQUESTS] = {
2343 (dump_func)dump_new_process_request,
2344 (dump_func)dump_get_new_process_info_request,
2345 (dump_func)dump_new_thread_request,
2346 (dump_func)dump_boot_done_request,
2347 (dump_func)dump_init_process_request,
2348 (dump_func)dump_get_startup_info_request,
2349 (dump_func)dump_init_process_done_request,
2350 (dump_func)dump_init_thread_request,
2351 (dump_func)dump_terminate_process_request,
2352 (dump_func)dump_terminate_thread_request,
2353 (dump_func)dump_get_process_info_request,
2354 (dump_func)dump_set_process_info_request,
2355 (dump_func)dump_get_thread_info_request,
2356 (dump_func)dump_set_thread_info_request,
2357 (dump_func)dump_suspend_thread_request,
2358 (dump_func)dump_resume_thread_request,
2359 (dump_func)dump_load_dll_request,
2360 (dump_func)dump_unload_dll_request,
2361 (dump_func)dump_queue_apc_request,
2362 (dump_func)dump_get_apc_request,
2363 (dump_func)dump_close_handle_request,
2364 (dump_func)dump_set_handle_info_request,
2365 (dump_func)dump_dup_handle_request,
2366 (dump_func)dump_open_process_request,
2367 (dump_func)dump_open_thread_request,
2368 (dump_func)dump_select_request,
2369 (dump_func)dump_create_event_request,
2370 (dump_func)dump_event_op_request,
2371 (dump_func)dump_open_event_request,
2372 (dump_func)dump_create_mutex_request,
2373 (dump_func)dump_release_mutex_request,
2374 (dump_func)dump_open_mutex_request,
2375 (dump_func)dump_create_semaphore_request,
2376 (dump_func)dump_release_semaphore_request,
2377 (dump_func)dump_open_semaphore_request,
2378 (dump_func)dump_create_file_request,
2379 (dump_func)dump_alloc_file_handle_request,
2380 (dump_func)dump_get_handle_fd_request,
2381 (dump_func)dump_set_file_pointer_request,
2382 (dump_func)dump_truncate_file_request,
2383 (dump_func)dump_set_file_time_request,
2384 (dump_func)dump_flush_file_request,
2385 (dump_func)dump_get_file_info_request,
2386 (dump_func)dump_lock_file_request,
2387 (dump_func)dump_unlock_file_request,
2388 (dump_func)dump_create_pipe_request,
2389 (dump_func)dump_create_socket_request,
2390 (dump_func)dump_accept_socket_request,
2391 (dump_func)dump_set_socket_event_request,
2392 (dump_func)dump_get_socket_event_request,
2393 (dump_func)dump_enable_socket_event_request,
2394 (dump_func)dump_set_socket_deferred_request,
2395 (dump_func)dump_alloc_console_request,
2396 (dump_func)dump_free_console_request,
2397 (dump_func)dump_get_console_renderer_events_request,
2398 (dump_func)dump_open_console_request,
2399 (dump_func)dump_get_console_mode_request,
2400 (dump_func)dump_set_console_mode_request,
2401 (dump_func)dump_set_console_input_info_request,
2402 (dump_func)dump_get_console_input_info_request,
2403 (dump_func)dump_append_console_input_history_request,
2404 (dump_func)dump_get_console_input_history_request,
2405 (dump_func)dump_create_console_output_request,
2406 (dump_func)dump_set_console_output_info_request,
2407 (dump_func)dump_get_console_output_info_request,
2408 (dump_func)dump_write_console_input_request,
2409 (dump_func)dump_read_console_input_request,
2410 (dump_func)dump_write_console_output_request,
2411 (dump_func)dump_fill_console_output_request,
2412 (dump_func)dump_read_console_output_request,
2413 (dump_func)dump_move_console_output_request,
2414 (dump_func)dump_send_console_signal_request,
2415 (dump_func)dump_create_change_notification_request,
2416 (dump_func)dump_create_mapping_request,
2417 (dump_func)dump_open_mapping_request,
2418 (dump_func)dump_get_mapping_info_request,
2419 (dump_func)dump_create_device_request,
2420 (dump_func)dump_create_snapshot_request,
2421 (dump_func)dump_next_process_request,
2422 (dump_func)dump_next_thread_request,
2423 (dump_func)dump_next_module_request,
2424 (dump_func)dump_wait_debug_event_request,
2425 (dump_func)dump_queue_exception_event_request,
2426 (dump_func)dump_get_exception_status_request,
2427 (dump_func)dump_output_debug_string_request,
2428 (dump_func)dump_continue_debug_event_request,
2429 (dump_func)dump_debug_process_request,
2430 (dump_func)dump_debug_break_request,
2431 (dump_func)dump_set_debugger_kill_on_exit_request,
2432 (dump_func)dump_read_process_memory_request,
2433 (dump_func)dump_write_process_memory_request,
2434 (dump_func)dump_create_key_request,
2435 (dump_func)dump_open_key_request,
2436 (dump_func)dump_delete_key_request,
2437 (dump_func)dump_enum_key_request,
2438 (dump_func)dump_set_key_value_request,
2439 (dump_func)dump_get_key_value_request,
2440 (dump_func)dump_enum_key_value_request,
2441 (dump_func)dump_delete_key_value_request,
2442 (dump_func)dump_load_registry_request,
2443 (dump_func)dump_save_registry_request,
2444 (dump_func)dump_save_registry_atexit_request,
2445 (dump_func)dump_set_registry_levels_request,
2446 (dump_func)dump_create_timer_request,
2447 (dump_func)dump_open_timer_request,
2448 (dump_func)dump_set_timer_request,
2449 (dump_func)dump_cancel_timer_request,
2450 (dump_func)dump_get_thread_context_request,
2451 (dump_func)dump_set_thread_context_request,
2452 (dump_func)dump_get_selector_entry_request,
2453 (dump_func)dump_add_atom_request,
2454 (dump_func)dump_delete_atom_request,
2455 (dump_func)dump_find_atom_request,
2456 (dump_func)dump_get_atom_name_request,
2457 (dump_func)dump_init_atom_table_request,
2458 (dump_func)dump_get_msg_queue_request,
2459 (dump_func)dump_set_queue_mask_request,
2460 (dump_func)dump_get_queue_status_request,
2461 (dump_func)dump_wait_input_idle_request,
2462 (dump_func)dump_send_message_request,
2463 (dump_func)dump_get_message_request,
2464 (dump_func)dump_reply_message_request,
2465 (dump_func)dump_get_message_reply_request,
2466 (dump_func)dump_set_win_timer_request,
2467 (dump_func)dump_kill_win_timer_request,
2468 (dump_func)dump_create_serial_request,
2469 (dump_func)dump_get_serial_info_request,
2470 (dump_func)dump_set_serial_info_request,
2471 (dump_func)dump_register_async_request,
2472 (dump_func)dump_create_named_pipe_request,
2473 (dump_func)dump_open_named_pipe_request,
2474 (dump_func)dump_connect_named_pipe_request,
2475 (dump_func)dump_wait_named_pipe_request,
2476 (dump_func)dump_disconnect_named_pipe_request,
2477 (dump_func)dump_get_named_pipe_info_request,
2478 (dump_func)dump_create_smb_request,
2479 (dump_func)dump_get_smb_info_request,
2480 (dump_func)dump_create_window_request,
2481 (dump_func)dump_link_window_request,
2482 (dump_func)dump_destroy_window_request,
2483 (dump_func)dump_set_window_owner_request,
2484 (dump_func)dump_get_window_info_request,
2485 (dump_func)dump_set_window_info_request,
2486 (dump_func)dump_get_window_parents_request,
2487 (dump_func)dump_get_window_children_request,
2488 (dump_func)dump_get_window_tree_request,
2489 (dump_func)dump_set_window_rectangles_request,
2490 (dump_func)dump_get_window_rectangles_request,
2491 (dump_func)dump_get_window_text_request,
2492 (dump_func)dump_set_window_text_request,
2493 (dump_func)dump_inc_window_paint_count_request,
2494 (dump_func)dump_get_windows_offset_request,
2495 (dump_func)dump_set_window_property_request,
2496 (dump_func)dump_remove_window_property_request,
2497 (dump_func)dump_get_window_property_request,
2498 (dump_func)dump_get_window_properties_request,
2499 (dump_func)dump_attach_thread_input_request,
2500 (dump_func)dump_get_thread_input_request,
2501 (dump_func)dump_set_foreground_window_request,
2502 (dump_func)dump_set_focus_window_request,
2503 (dump_func)dump_set_active_window_request,
2504 (dump_func)dump_set_capture_window_request,
2505 (dump_func)dump_set_caret_window_request,
2506 (dump_func)dump_set_caret_info_request,
2507 (dump_func)dump_set_hook_request,
2508 (dump_func)dump_remove_hook_request,
2509 (dump_func)dump_start_hook_chain_request,
2510 (dump_func)dump_finish_hook_chain_request,
2511 (dump_func)dump_get_next_hook_request,
2514 static const dump_func reply_dumpers[REQ_NB_REQUESTS] = {
2515 (dump_func)dump_new_process_reply,
2516 (dump_func)dump_get_new_process_info_reply,
2517 (dump_func)dump_new_thread_reply,
2518 (dump_func)0,
2519 (dump_func)dump_init_process_reply,
2520 (dump_func)dump_get_startup_info_reply,
2521 (dump_func)dump_init_process_done_reply,
2522 (dump_func)dump_init_thread_reply,
2523 (dump_func)dump_terminate_process_reply,
2524 (dump_func)dump_terminate_thread_reply,
2525 (dump_func)dump_get_process_info_reply,
2526 (dump_func)0,
2527 (dump_func)dump_get_thread_info_reply,
2528 (dump_func)0,
2529 (dump_func)dump_suspend_thread_reply,
2530 (dump_func)dump_resume_thread_reply,
2531 (dump_func)0,
2532 (dump_func)0,
2533 (dump_func)0,
2534 (dump_func)dump_get_apc_reply,
2535 (dump_func)dump_close_handle_reply,
2536 (dump_func)dump_set_handle_info_reply,
2537 (dump_func)dump_dup_handle_reply,
2538 (dump_func)dump_open_process_reply,
2539 (dump_func)dump_open_thread_reply,
2540 (dump_func)0,
2541 (dump_func)dump_create_event_reply,
2542 (dump_func)0,
2543 (dump_func)dump_open_event_reply,
2544 (dump_func)dump_create_mutex_reply,
2545 (dump_func)0,
2546 (dump_func)dump_open_mutex_reply,
2547 (dump_func)dump_create_semaphore_reply,
2548 (dump_func)dump_release_semaphore_reply,
2549 (dump_func)dump_open_semaphore_reply,
2550 (dump_func)dump_create_file_reply,
2551 (dump_func)dump_alloc_file_handle_reply,
2552 (dump_func)dump_get_handle_fd_reply,
2553 (dump_func)dump_set_file_pointer_reply,
2554 (dump_func)0,
2555 (dump_func)0,
2556 (dump_func)0,
2557 (dump_func)dump_get_file_info_reply,
2558 (dump_func)0,
2559 (dump_func)0,
2560 (dump_func)dump_create_pipe_reply,
2561 (dump_func)dump_create_socket_reply,
2562 (dump_func)dump_accept_socket_reply,
2563 (dump_func)0,
2564 (dump_func)dump_get_socket_event_reply,
2565 (dump_func)0,
2566 (dump_func)0,
2567 (dump_func)dump_alloc_console_reply,
2568 (dump_func)0,
2569 (dump_func)dump_get_console_renderer_events_reply,
2570 (dump_func)dump_open_console_reply,
2571 (dump_func)dump_get_console_mode_reply,
2572 (dump_func)0,
2573 (dump_func)0,
2574 (dump_func)dump_get_console_input_info_reply,
2575 (dump_func)0,
2576 (dump_func)dump_get_console_input_history_reply,
2577 (dump_func)dump_create_console_output_reply,
2578 (dump_func)0,
2579 (dump_func)dump_get_console_output_info_reply,
2580 (dump_func)dump_write_console_input_reply,
2581 (dump_func)dump_read_console_input_reply,
2582 (dump_func)dump_write_console_output_reply,
2583 (dump_func)dump_fill_console_output_reply,
2584 (dump_func)dump_read_console_output_reply,
2585 (dump_func)0,
2586 (dump_func)0,
2587 (dump_func)dump_create_change_notification_reply,
2588 (dump_func)dump_create_mapping_reply,
2589 (dump_func)dump_open_mapping_reply,
2590 (dump_func)dump_get_mapping_info_reply,
2591 (dump_func)dump_create_device_reply,
2592 (dump_func)dump_create_snapshot_reply,
2593 (dump_func)dump_next_process_reply,
2594 (dump_func)dump_next_thread_reply,
2595 (dump_func)dump_next_module_reply,
2596 (dump_func)dump_wait_debug_event_reply,
2597 (dump_func)dump_queue_exception_event_reply,
2598 (dump_func)dump_get_exception_status_reply,
2599 (dump_func)0,
2600 (dump_func)0,
2601 (dump_func)0,
2602 (dump_func)dump_debug_break_reply,
2603 (dump_func)0,
2604 (dump_func)dump_read_process_memory_reply,
2605 (dump_func)0,
2606 (dump_func)dump_create_key_reply,
2607 (dump_func)dump_open_key_reply,
2608 (dump_func)0,
2609 (dump_func)dump_enum_key_reply,
2610 (dump_func)0,
2611 (dump_func)dump_get_key_value_reply,
2612 (dump_func)dump_enum_key_value_reply,
2613 (dump_func)0,
2614 (dump_func)0,
2615 (dump_func)0,
2616 (dump_func)0,
2617 (dump_func)0,
2618 (dump_func)dump_create_timer_reply,
2619 (dump_func)dump_open_timer_reply,
2620 (dump_func)0,
2621 (dump_func)0,
2622 (dump_func)dump_get_thread_context_reply,
2623 (dump_func)0,
2624 (dump_func)dump_get_selector_entry_reply,
2625 (dump_func)dump_add_atom_reply,
2626 (dump_func)0,
2627 (dump_func)dump_find_atom_reply,
2628 (dump_func)dump_get_atom_name_reply,
2629 (dump_func)0,
2630 (dump_func)dump_get_msg_queue_reply,
2631 (dump_func)dump_set_queue_mask_reply,
2632 (dump_func)dump_get_queue_status_reply,
2633 (dump_func)dump_wait_input_idle_reply,
2634 (dump_func)0,
2635 (dump_func)dump_get_message_reply,
2636 (dump_func)0,
2637 (dump_func)dump_get_message_reply_reply,
2638 (dump_func)0,
2639 (dump_func)0,
2640 (dump_func)dump_create_serial_reply,
2641 (dump_func)dump_get_serial_info_reply,
2642 (dump_func)0,
2643 (dump_func)0,
2644 (dump_func)dump_create_named_pipe_reply,
2645 (dump_func)dump_open_named_pipe_reply,
2646 (dump_func)0,
2647 (dump_func)0,
2648 (dump_func)0,
2649 (dump_func)dump_get_named_pipe_info_reply,
2650 (dump_func)dump_create_smb_reply,
2651 (dump_func)dump_get_smb_info_reply,
2652 (dump_func)dump_create_window_reply,
2653 (dump_func)dump_link_window_reply,
2654 (dump_func)0,
2655 (dump_func)dump_set_window_owner_reply,
2656 (dump_func)dump_get_window_info_reply,
2657 (dump_func)dump_set_window_info_reply,
2658 (dump_func)dump_get_window_parents_reply,
2659 (dump_func)dump_get_window_children_reply,
2660 (dump_func)dump_get_window_tree_reply,
2661 (dump_func)0,
2662 (dump_func)dump_get_window_rectangles_reply,
2663 (dump_func)dump_get_window_text_reply,
2664 (dump_func)0,
2665 (dump_func)0,
2666 (dump_func)dump_get_windows_offset_reply,
2667 (dump_func)0,
2668 (dump_func)dump_remove_window_property_reply,
2669 (dump_func)dump_get_window_property_reply,
2670 (dump_func)dump_get_window_properties_reply,
2671 (dump_func)0,
2672 (dump_func)dump_get_thread_input_reply,
2673 (dump_func)dump_set_foreground_window_reply,
2674 (dump_func)dump_set_focus_window_reply,
2675 (dump_func)dump_set_active_window_reply,
2676 (dump_func)dump_set_capture_window_reply,
2677 (dump_func)dump_set_caret_window_reply,
2678 (dump_func)dump_set_caret_info_reply,
2679 (dump_func)dump_set_hook_reply,
2680 (dump_func)0,
2681 (dump_func)dump_start_hook_chain_reply,
2682 (dump_func)0,
2683 (dump_func)dump_get_next_hook_reply,
2686 static const char * const req_names[REQ_NB_REQUESTS] = {
2687 "new_process",
2688 "get_new_process_info",
2689 "new_thread",
2690 "boot_done",
2691 "init_process",
2692 "get_startup_info",
2693 "init_process_done",
2694 "init_thread",
2695 "terminate_process",
2696 "terminate_thread",
2697 "get_process_info",
2698 "set_process_info",
2699 "get_thread_info",
2700 "set_thread_info",
2701 "suspend_thread",
2702 "resume_thread",
2703 "load_dll",
2704 "unload_dll",
2705 "queue_apc",
2706 "get_apc",
2707 "close_handle",
2708 "set_handle_info",
2709 "dup_handle",
2710 "open_process",
2711 "open_thread",
2712 "select",
2713 "create_event",
2714 "event_op",
2715 "open_event",
2716 "create_mutex",
2717 "release_mutex",
2718 "open_mutex",
2719 "create_semaphore",
2720 "release_semaphore",
2721 "open_semaphore",
2722 "create_file",
2723 "alloc_file_handle",
2724 "get_handle_fd",
2725 "set_file_pointer",
2726 "truncate_file",
2727 "set_file_time",
2728 "flush_file",
2729 "get_file_info",
2730 "lock_file",
2731 "unlock_file",
2732 "create_pipe",
2733 "create_socket",
2734 "accept_socket",
2735 "set_socket_event",
2736 "get_socket_event",
2737 "enable_socket_event",
2738 "set_socket_deferred",
2739 "alloc_console",
2740 "free_console",
2741 "get_console_renderer_events",
2742 "open_console",
2743 "get_console_mode",
2744 "set_console_mode",
2745 "set_console_input_info",
2746 "get_console_input_info",
2747 "append_console_input_history",
2748 "get_console_input_history",
2749 "create_console_output",
2750 "set_console_output_info",
2751 "get_console_output_info",
2752 "write_console_input",
2753 "read_console_input",
2754 "write_console_output",
2755 "fill_console_output",
2756 "read_console_output",
2757 "move_console_output",
2758 "send_console_signal",
2759 "create_change_notification",
2760 "create_mapping",
2761 "open_mapping",
2762 "get_mapping_info",
2763 "create_device",
2764 "create_snapshot",
2765 "next_process",
2766 "next_thread",
2767 "next_module",
2768 "wait_debug_event",
2769 "queue_exception_event",
2770 "get_exception_status",
2771 "output_debug_string",
2772 "continue_debug_event",
2773 "debug_process",
2774 "debug_break",
2775 "set_debugger_kill_on_exit",
2776 "read_process_memory",
2777 "write_process_memory",
2778 "create_key",
2779 "open_key",
2780 "delete_key",
2781 "enum_key",
2782 "set_key_value",
2783 "get_key_value",
2784 "enum_key_value",
2785 "delete_key_value",
2786 "load_registry",
2787 "save_registry",
2788 "save_registry_atexit",
2789 "set_registry_levels",
2790 "create_timer",
2791 "open_timer",
2792 "set_timer",
2793 "cancel_timer",
2794 "get_thread_context",
2795 "set_thread_context",
2796 "get_selector_entry",
2797 "add_atom",
2798 "delete_atom",
2799 "find_atom",
2800 "get_atom_name",
2801 "init_atom_table",
2802 "get_msg_queue",
2803 "set_queue_mask",
2804 "get_queue_status",
2805 "wait_input_idle",
2806 "send_message",
2807 "get_message",
2808 "reply_message",
2809 "get_message_reply",
2810 "set_win_timer",
2811 "kill_win_timer",
2812 "create_serial",
2813 "get_serial_info",
2814 "set_serial_info",
2815 "register_async",
2816 "create_named_pipe",
2817 "open_named_pipe",
2818 "connect_named_pipe",
2819 "wait_named_pipe",
2820 "disconnect_named_pipe",
2821 "get_named_pipe_info",
2822 "create_smb",
2823 "get_smb_info",
2824 "create_window",
2825 "link_window",
2826 "destroy_window",
2827 "set_window_owner",
2828 "get_window_info",
2829 "set_window_info",
2830 "get_window_parents",
2831 "get_window_children",
2832 "get_window_tree",
2833 "set_window_rectangles",
2834 "get_window_rectangles",
2835 "get_window_text",
2836 "set_window_text",
2837 "inc_window_paint_count",
2838 "get_windows_offset",
2839 "set_window_property",
2840 "remove_window_property",
2841 "get_window_property",
2842 "get_window_properties",
2843 "attach_thread_input",
2844 "get_thread_input",
2845 "set_foreground_window",
2846 "set_focus_window",
2847 "set_active_window",
2848 "set_capture_window",
2849 "set_caret_window",
2850 "set_caret_info",
2851 "set_hook",
2852 "remove_hook",
2853 "start_hook_chain",
2854 "finish_hook_chain",
2855 "get_next_hook",
2858 /* ### make_requests end ### */
2859 /* Everything above this line is generated automatically by tools/make_requests */
2861 static const char *get_status_name( unsigned int status )
2863 #define NAME(status) { #status, STATUS_##status }
2864 static const struct
2866 const char *name;
2867 unsigned int value;
2868 } status_names[] =
2870 NAME(ACCESS_DENIED),
2871 NAME(ACCESS_VIOLATION),
2872 NAME(BUFFER_OVERFLOW),
2873 NAME(CHILD_MUST_BE_VOLATILE),
2874 NAME(DIRECTORY_NOT_EMPTY),
2875 NAME(DISK_FULL),
2876 NAME(FILE_LOCK_CONFLICT),
2877 NAME(INVALID_FILE_FOR_SECTION),
2878 NAME(INVALID_HANDLE),
2879 NAME(INVALID_PARAMETER),
2880 NAME(KEY_DELETED),
2881 NAME(MEDIA_WRITE_PROTECTED),
2882 NAME(MUTANT_NOT_OWNED),
2883 NAME(NOT_REGISTRY_FILE),
2884 NAME(NO_MEMORY),
2885 NAME(NO_MORE_ENTRIES),
2886 NAME(NO_MORE_FILES),
2887 NAME(NO_SUCH_FILE),
2888 NAME(OBJECT_NAME_COLLISION),
2889 NAME(OBJECT_NAME_INVALID),
2890 NAME(OBJECT_NAME_NOT_FOUND),
2891 NAME(OBJECT_PATH_INVALID),
2892 NAME(OBJECT_TYPE_MISMATCH),
2893 NAME(PENDING),
2894 NAME(PIPE_BROKEN),
2895 NAME(SEMAPHORE_LIMIT_EXCEEDED),
2896 NAME(SHARING_VIOLATION),
2897 NAME(SUSPEND_COUNT_EXCEEDED),
2898 NAME(TIMEOUT),
2899 NAME(TOO_MANY_OPENED_FILES),
2900 NAME(UNSUCCESSFUL),
2901 NAME(USER_APC),
2902 { NULL, 0 } /* terminator */
2904 #undef NAME
2906 int i;
2907 static char buffer[10];
2909 if (status)
2911 for (i = 0; status_names[i].name; i++)
2912 if (status_names[i].value == status) return status_names[i].name;
2914 sprintf( buffer, "%x", status );
2915 return buffer;
2918 void trace_request(void)
2920 enum request req = current->req.request_header.req;
2921 if (req < REQ_NB_REQUESTS)
2923 fprintf( stderr, "%08x: %s(", (unsigned int)current, req_names[req] );
2924 if (req_dumpers[req])
2926 cur_pos = 0;
2927 cur_data = get_req_data();
2928 cur_size = get_req_data_size();
2929 req_dumpers[req]( &current->req );
2931 fprintf( stderr, " )\n" );
2933 else fprintf( stderr, "%08x: %d(?)\n", (unsigned int)current, req );
2936 void trace_reply( enum request req, const union generic_reply *reply )
2938 if (req < REQ_NB_REQUESTS)
2940 fprintf( stderr, "%08x: %s() = %s",
2941 (unsigned int)current, req_names[req], get_status_name(current->error) );
2942 if (reply_dumpers[req])
2944 fprintf( stderr, " {" );
2945 cur_pos = 0;
2946 cur_data = current->reply_data;
2947 cur_size = reply->reply_header.reply_size;
2948 reply_dumpers[req]( reply );
2949 fprintf( stderr, " }" );
2951 fputc( '\n', stderr );
2953 else fprintf( stderr, "%08x: %d() = %s\n",
2954 (unsigned int)current, req, get_status_name(current->error) );