ddraw: Get rid of a cast from a COM object to an iface.
[wine.git] / server / trace.c
blobd48c2050689bed7b4970971bda400dbdb714240e
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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
21 #include "config.h"
22 #include "wine/port.h"
24 #include <ctype.h>
25 #include <stdarg.h>
26 #include <stdio.h>
27 #include <sys/types.h>
29 #ifdef HAVE_SYS_UIO_H
30 #include <sys/uio.h>
31 #endif
33 #include "ntstatus.h"
34 #define WIN32_NO_STATUS
35 #include "windef.h"
36 #include "winbase.h"
37 #include "wincon.h"
38 #include "winternl.h"
39 #include "winuser.h"
40 #include "winioctl.h"
41 #include "ddk/wdm.h"
42 #define USE_WS_PREFIX
43 #include "winsock2.h"
44 #include "file.h"
45 #include "request.h"
46 #include "unicode.h"
48 static const void *cur_data;
49 static data_size_t cur_size;
51 static const char *get_status_name( unsigned int status );
53 /* utility functions */
55 static inline void remove_data( data_size_t size )
57 cur_data = (const char *)cur_data + size;
58 cur_size -= size;
61 static void dump_uints( const int *ptr, int len )
63 fputc( '{', stderr );
64 while (len > 0)
66 fprintf( stderr, "%08x", *ptr++ );
67 if (--len) fputc( ',', stderr );
69 fputc( '}', stderr );
72 static void dump_handles( const char *prefix, const obj_handle_t *data, data_size_t size )
74 data_size_t len = size / sizeof(*data);
76 fprintf( stderr,"%s{", prefix );
77 while (len > 0)
79 fprintf( stderr, "%04x", *data++ );
80 if (--len) fputc( ',', stderr );
82 fputc( '}', stderr );
85 static void dump_timeout( const char *prefix, const timeout_t *time )
87 fprintf( stderr, "%s%s", prefix, get_timeout_str(*time) );
90 static void dump_uint64( const char *prefix, const unsigned __int64 *val )
92 if ((unsigned int)*val != *val)
93 fprintf( stderr, "%s%x%08x", prefix, (unsigned int)(*val >> 32), (unsigned int)*val );
94 else
95 fprintf( stderr, "%s%08x", prefix, (unsigned int)*val );
98 static void dump_rectangle( const char *prefix, const rectangle_t *rect )
100 fprintf( stderr, "%s{%d,%d;%d,%d}", prefix,
101 rect->left, rect->top, rect->right, rect->bottom );
104 static void dump_char_info( const char *prefix, const char_info_t *info )
106 fprintf( stderr, "%s{'", prefix );
107 dump_strW( &info->ch, 1, stderr, "\'\'" );
108 fprintf( stderr, "',%04x}", info->attr );
111 static void dump_ioctl_code( const char *prefix, const ioctl_code_t *code )
113 switch(*code)
115 #define CASE(c) case c: fprintf( stderr, "%s%s", prefix, #c ); break
116 CASE(FSCTL_DISMOUNT_VOLUME);
117 CASE(FSCTL_PIPE_DISCONNECT);
118 CASE(FSCTL_PIPE_LISTEN);
119 CASE(FSCTL_PIPE_WAIT);
120 CASE(WS_SIO_ADDRESS_LIST_CHANGE);
121 default: fprintf( stderr, "%s%08x", prefix, *code ); break;
122 #undef CASE
126 static void dump_cpu_type( const char *prefix, const cpu_type_t *code )
128 switch (*code)
130 #define CASE(c) case CPU_##c: fprintf( stderr, "%s%s", prefix, #c ); break
131 CASE(x86);
132 CASE(x86_64);
133 CASE(POWERPC);
134 CASE(ARM);
135 CASE(ARM64);
136 default: fprintf( stderr, "%s%u", prefix, *code ); break;
137 #undef CASE
141 static void dump_apc_call( const char *prefix, const apc_call_t *call )
143 fprintf( stderr, "%s{", prefix );
144 switch(call->type)
146 case APC_NONE:
147 fprintf( stderr, "APC_NONE" );
148 break;
149 case APC_USER:
150 dump_uint64( "APC_USER,func=", &call->user.func );
151 dump_uint64( ",args={", &call->user.args[0] );
152 dump_uint64( ",", &call->user.args[1] );
153 dump_uint64( ",", &call->user.args[2] );
154 fputc( '}', stderr );
155 break;
156 case APC_TIMER:
157 dump_timeout( "APC_TIMER,time=", &call->timer.time );
158 dump_uint64( ",arg=", &call->timer.arg );
159 break;
160 case APC_ASYNC_IO:
161 dump_uint64( "APC_ASYNC_IO,func=", &call->async_io.func );
162 dump_uint64( ",user=", &call->async_io.user );
163 dump_uint64( ",sb=", &call->async_io.sb );
164 fprintf( stderr, ",status=%s", get_status_name(call->async_io.status) );
165 break;
166 case APC_VIRTUAL_ALLOC:
167 dump_uint64( "APC_VIRTUAL_ALLOC,addr==", &call->virtual_alloc.addr );
168 dump_uint64( ",size=", &call->virtual_alloc.size );
169 fprintf( stderr, ",zero_bits=%u,op_type=%x,prot=%x",
170 call->virtual_alloc.zero_bits, call->virtual_alloc.op_type,
171 call->virtual_alloc.prot );
172 break;
173 case APC_VIRTUAL_FREE:
174 dump_uint64( "APC_VIRTUAL_FREE,addr=", &call->virtual_free.addr );
175 dump_uint64( ",size=", &call->virtual_free.size );
176 fprintf( stderr, ",op_type=%x", call->virtual_free.op_type );
177 break;
178 case APC_VIRTUAL_QUERY:
179 dump_uint64( "APC_VIRTUAL_QUERY,addr=", &call->virtual_query.addr );
180 break;
181 case APC_VIRTUAL_PROTECT:
182 dump_uint64( "APC_VIRTUAL_PROTECT,addr=", &call->virtual_protect.addr );
183 dump_uint64( ",size=", &call->virtual_protect.size );
184 fprintf( stderr, ",prot=%x", call->virtual_protect.prot );
185 break;
186 case APC_VIRTUAL_FLUSH:
187 dump_uint64( "APC_VIRTUAL_FLUSH,addr=", &call->virtual_flush.addr );
188 dump_uint64( ",size=", &call->virtual_flush.size );
189 break;
190 case APC_VIRTUAL_LOCK:
191 dump_uint64( "APC_VIRTUAL_LOCK,addr=", &call->virtual_lock.addr );
192 dump_uint64( ",size=", &call->virtual_lock.size );
193 break;
194 case APC_VIRTUAL_UNLOCK:
195 dump_uint64( "APC_VIRTUAL_UNLOCK,addr=", &call->virtual_unlock.addr );
196 dump_uint64( ",size=", &call->virtual_unlock.size );
197 break;
198 case APC_MAP_VIEW:
199 fprintf( stderr, "APC_MAP_VIEW,handle=%04x", call->map_view.handle );
200 dump_uint64( ",addr=", &call->map_view.addr );
201 dump_uint64( ",size=", &call->map_view.size );
202 dump_uint64( ",offset=", &call->map_view.offset );
203 fprintf( stderr, ",zero_bits=%u,alloc_type=%x,prot=%x",
204 call->map_view.zero_bits, call->map_view.alloc_type, call->map_view.prot );
205 break;
206 case APC_UNMAP_VIEW:
207 dump_uint64( "APC_UNMAP_VIEW,addr=", &call->unmap_view.addr );
208 break;
209 case APC_CREATE_THREAD:
210 dump_uint64( "APC_CREATE_THREAD,func=", &call->create_thread.func );
211 dump_uint64( ",arg=", &call->create_thread.arg );
212 dump_uint64( ",reserve=", &call->create_thread.reserve );
213 dump_uint64( ",commit=", &call->create_thread.commit );
214 fprintf( stderr, ",suspend=%u", call->create_thread.suspend );
215 break;
216 default:
217 fprintf( stderr, "type=%u", call->type );
218 break;
220 fputc( '}', stderr );
223 static void dump_apc_result( const char *prefix, const apc_result_t *result )
225 fprintf( stderr, "%s{", prefix );
226 switch(result->type)
228 case APC_NONE:
229 break;
230 case APC_ASYNC_IO:
231 fprintf( stderr, "APC_ASYNC_IO,status=%s,total=%u",
232 get_status_name( result->async_io.status ), result->async_io.total );
233 dump_uint64( ",apc=", &result->async_io.apc );
234 dump_uint64( ",arg=", &result->async_io.arg );
235 break;
236 case APC_VIRTUAL_ALLOC:
237 fprintf( stderr, "APC_VIRTUAL_ALLOC,status=%s",
238 get_status_name( result->virtual_alloc.status ));
239 dump_uint64( ",addr=", &result->virtual_alloc.addr );
240 dump_uint64( ",size=", &result->virtual_alloc.size );
241 break;
242 case APC_VIRTUAL_FREE:
243 fprintf( stderr, "APC_VIRTUAL_FREE,status=%s",
244 get_status_name( result->virtual_free.status ));
245 dump_uint64( ",addr=", &result->virtual_free.addr );
246 dump_uint64( ",size=", &result->virtual_free.size );
247 break;
248 case APC_VIRTUAL_QUERY:
249 fprintf( stderr, "APC_VIRTUAL_QUERY,status=%s",
250 get_status_name( result->virtual_query.status ));
251 dump_uint64( ",base=", &result->virtual_query.base );
252 dump_uint64( ",alloc_base=", &result->virtual_query.alloc_base );
253 dump_uint64( ",size=", &result->virtual_query.size );
254 fprintf( stderr, ",state=%x,prot=%x,alloc_prot=%x,alloc_type=%x",
255 result->virtual_query.state, result->virtual_query.prot,
256 result->virtual_query.alloc_prot, result->virtual_query.alloc_type );
257 break;
258 case APC_VIRTUAL_PROTECT:
259 fprintf( stderr, "APC_VIRTUAL_PROTECT,status=%s",
260 get_status_name( result->virtual_protect.status ));
261 dump_uint64( ",addr=", &result->virtual_protect.addr );
262 dump_uint64( ",size=", &result->virtual_protect.size );
263 fprintf( stderr, ",prot=%x", result->virtual_protect.prot );
264 break;
265 case APC_VIRTUAL_FLUSH:
266 fprintf( stderr, "APC_VIRTUAL_FLUSH,status=%s",
267 get_status_name( result->virtual_flush.status ));
268 dump_uint64( ",addr=", &result->virtual_flush.addr );
269 dump_uint64( ",size=", &result->virtual_flush.size );
270 break;
271 case APC_VIRTUAL_LOCK:
272 fprintf( stderr, "APC_VIRTUAL_LOCK,status=%s",
273 get_status_name( result->virtual_lock.status ));
274 dump_uint64( ",addr=", &result->virtual_lock.addr );
275 dump_uint64( ",size=", &result->virtual_lock.size );
276 break;
277 case APC_VIRTUAL_UNLOCK:
278 fprintf( stderr, "APC_VIRTUAL_UNLOCK,status=%s",
279 get_status_name( result->virtual_unlock.status ));
280 dump_uint64( ",addr=", &result->virtual_unlock.addr );
281 dump_uint64( ",size=", &result->virtual_unlock.size );
282 break;
283 case APC_MAP_VIEW:
284 fprintf( stderr, "APC_MAP_VIEW,status=%s",
285 get_status_name( result->map_view.status ));
286 dump_uint64( ",addr=", &result->map_view.addr );
287 dump_uint64( ",size=", &result->map_view.size );
288 break;
289 case APC_UNMAP_VIEW:
290 fprintf( stderr, "APC_UNMAP_VIEW,status=%s",
291 get_status_name( result->unmap_view.status ) );
292 break;
293 case APC_CREATE_THREAD:
294 fprintf( stderr, "APC_CREATE_THREAD,status=%s,tid=%04x,handle=%04x",
295 get_status_name( result->create_thread.status ),
296 result->create_thread.tid, result->create_thread.handle );
297 break;
298 default:
299 fprintf( stderr, "type=%u", result->type );
300 break;
302 fputc( '}', stderr );
305 static void dump_async_data( const char *prefix, const async_data_t *data )
307 fprintf( stderr, "%s{handle=%04x,event=%04x", prefix, data->handle, data->event );
308 dump_uint64( ",callback=", &data->callback );
309 dump_uint64( ",iosb=", &data->iosb );
310 dump_uint64( ",arg=", &data->arg );
311 dump_uint64( ",cvalue=", &data->cvalue );
312 fputc( '}', stderr );
315 static void dump_irp_params( const char *prefix, const irp_params_t *data )
317 switch (data->major)
319 case IRP_MJ_CREATE:
320 fprintf( stderr, "%s{major=CREATE,access=%08x,sharing=%08x,options=%08x",
321 prefix, data->create.access, data->create.sharing, data->create.options );
322 dump_uint64( ",device=", &data->create.device );
323 fputc( '}', stderr );
324 break;
325 case IRP_MJ_CLOSE:
326 fprintf( stderr, "%s{major=CLOSE", prefix );
327 dump_uint64( ",file=", &data->close.file );
328 fputc( '}', stderr );
329 break;
330 case IRP_MJ_READ:
331 fprintf( stderr, "%s{major=READ,key=%08x", prefix, data->read.key );
332 dump_uint64( ",pos=", &data->read.pos );
333 dump_uint64( ",file=", &data->read.file );
334 fputc( '}', stderr );
335 break;
336 case IRP_MJ_WRITE:
337 fprintf( stderr, "%s{major=WRITE,key=%08x", prefix, data->write.key );
338 dump_uint64( ",pos=", &data->write.pos );
339 dump_uint64( ",file=", &data->write.file );
340 fputc( '}', stderr );
341 break;
342 case IRP_MJ_FLUSH_BUFFERS:
343 fprintf( stderr, "%s{major=FLUSH_BUFFERS", prefix );
344 dump_uint64( ",file=", &data->flush.file );
345 fputc( '}', stderr );
346 break;
347 case IRP_MJ_DEVICE_CONTROL:
348 fprintf( stderr, "%s{major=DEVICE_CONTROL", prefix );
349 dump_ioctl_code( ",code=", &data->ioctl.code );
350 dump_uint64( ",file=", &data->ioctl.file );
351 fputc( '}', stderr );
352 break;
353 case IRP_MJ_MAXIMUM_FUNCTION + 1: /* invalid */
354 fprintf( stderr, "%s{}", prefix );
355 break;
356 default:
357 fprintf( stderr, "%s{major=%u}", prefix, data->major );
358 break;
362 static void dump_hw_input( const char *prefix, const hw_input_t *input )
364 switch (input->type)
366 case INPUT_MOUSE:
367 fprintf( stderr, "%s{type=MOUSE,x=%d,y=%d,data=%08x,flags=%08x,time=%u",
368 prefix, input->mouse.x, input->mouse.y, input->mouse.data, input->mouse.flags,
369 input->mouse.time );
370 dump_uint64( ",info=", &input->mouse.info );
371 fputc( '}', stderr );
372 break;
373 case INPUT_KEYBOARD:
374 fprintf( stderr, "%s{type=KEYBOARD,vkey=%04hx,scan=%04hx,flags=%08x,time=%u",
375 prefix, input->kbd.vkey, input->kbd.scan, input->kbd.flags, input->kbd.time );
376 dump_uint64( ",info=", &input->kbd.info );
377 fputc( '}', stderr );
378 break;
379 case INPUT_HARDWARE:
380 fprintf( stderr, "%s{type=HARDWARE,msg=%04x", prefix, input->hw.msg );
381 dump_uint64( ",lparam=", &input->hw.lparam );
382 fputc( '}', stderr );
383 break;
384 default:
385 fprintf( stderr, "%s{type=%04x}", prefix, input->type );
386 break;
390 static void dump_luid( const char *prefix, const luid_t *luid )
392 fprintf( stderr, "%s%d.%u", prefix, luid->high_part, luid->low_part );
395 static void dump_varargs_ints( const char *prefix, data_size_t size )
397 const int *data = cur_data;
398 data_size_t len = size / sizeof(*data);
400 fprintf( stderr,"%s{", prefix );
401 while (len > 0)
403 fprintf( stderr, "%d", *data++ );
404 if (--len) fputc( ',', stderr );
406 fputc( '}', stderr );
407 remove_data( size );
410 static void dump_varargs_uints64( const char *prefix, data_size_t size )
412 const unsigned __int64 *data = cur_data;
413 data_size_t len = size / sizeof(*data);
415 fprintf( stderr,"%s{", prefix );
416 while (len > 0)
418 dump_uint64( "", data++ );
419 if (--len) fputc( ',', stderr );
421 fputc( '}', stderr );
422 remove_data( size );
425 static void dump_varargs_apc_result( const char *prefix, data_size_t size )
427 const apc_result_t *result = cur_data;
429 if (size >= sizeof(*result))
431 dump_apc_result( prefix, result );
432 size = sizeof(*result);
434 remove_data( size );
437 static void dump_varargs_select_op( const char *prefix, data_size_t size )
439 select_op_t data;
441 if (!size)
443 fprintf( stderr, "%s{}", prefix );
444 return;
446 memset( &data, 0, sizeof(data) );
447 memcpy( &data, cur_data, min( size, sizeof(data) ));
449 fprintf( stderr, "%s{", prefix );
450 switch (data.op)
452 case SELECT_NONE:
453 fprintf( stderr, "NONE" );
454 break;
455 case SELECT_WAIT:
456 case SELECT_WAIT_ALL:
457 fprintf( stderr, "%s", data.op == SELECT_WAIT ? "WAIT" : "WAIT_ALL" );
458 if (size > offsetof( select_op_t, wait.handles ))
459 dump_handles( ",handles=", data.wait.handles,
460 min( size, sizeof(data.wait) ) - offsetof( select_op_t, wait.handles ));
461 break;
462 case SELECT_SIGNAL_AND_WAIT:
463 fprintf( stderr, "SIGNAL_AND_WAIT,signal=%04x,wait=%04x",
464 data.signal_and_wait.signal, data.signal_and_wait.wait );
465 break;
466 case SELECT_KEYED_EVENT_WAIT:
467 case SELECT_KEYED_EVENT_RELEASE:
468 fprintf( stderr, "KEYED_EVENT_%s,handle=%04x",
469 data.op == SELECT_KEYED_EVENT_WAIT ? "WAIT" : "RELEASE",
470 data.keyed_event.handle );
471 dump_uint64( ",key=", &data.keyed_event.key );
472 break;
473 default:
474 fprintf( stderr, "op=%u", data.op );
475 break;
477 fputc( '}', stderr );
478 remove_data( size );
481 static void dump_varargs_user_handles( const char *prefix, data_size_t size )
483 const user_handle_t *data = cur_data;
484 data_size_t len = size / sizeof(*data);
486 fprintf( stderr,"%s{", prefix );
487 while (len > 0)
489 fprintf( stderr, "%08x", *data++ );
490 if (--len) fputc( ',', stderr );
492 fputc( '}', stderr );
493 remove_data( size );
496 static void dump_varargs_bytes( const char *prefix, data_size_t size )
498 const unsigned char *data = cur_data;
499 data_size_t len = min( 1024, size );
501 fprintf( stderr,"%s{", prefix );
502 while (len > 0)
504 fprintf( stderr, "%02x", *data++ );
505 if (--len) fputc( ',', stderr );
507 if (size > 1024) fprintf( stderr, "...(total %u)", size );
508 fputc( '}', stderr );
509 remove_data( size );
512 static void dump_varargs_string( const char *prefix, data_size_t size )
514 fprintf( stderr, "%s\"%.*s\"", prefix, (int)size, (const char *)cur_data );
515 remove_data( size );
518 static void dump_varargs_unicode_str( const char *prefix, data_size_t size )
520 fprintf( stderr, "%sL\"", prefix );
521 dump_strW( cur_data, size / sizeof(WCHAR), stderr, "\"\"" );
522 fputc( '\"', stderr );
523 remove_data( size );
526 static void dump_varargs_context( const char *prefix, data_size_t size )
528 const context_t *context = cur_data;
529 context_t ctx;
530 unsigned int i;
532 if (!size)
534 fprintf( stderr, "%s{}", prefix );
535 return;
537 size = min( size, sizeof(ctx) );
538 memset( &ctx, 0, sizeof(ctx) );
539 memcpy( &ctx, context, size );
541 fprintf( stderr,"%s{", prefix );
542 dump_cpu_type( "cpu=", &ctx.cpu );
543 switch (ctx.cpu)
545 case CPU_x86:
546 if (ctx.flags & SERVER_CTX_CONTROL)
547 fprintf( stderr, ",eip=%08x,esp=%08x,ebp=%08x,eflags=%08x,cs=%04x,ss=%04x",
548 ctx.ctl.i386_regs.eip, ctx.ctl.i386_regs.esp, ctx.ctl.i386_regs.ebp,
549 ctx.ctl.i386_regs.eflags, ctx.ctl.i386_regs.cs, ctx.ctl.i386_regs.ss );
550 if (ctx.flags & SERVER_CTX_SEGMENTS)
551 fprintf( stderr, ",ds=%04x,es=%04x,fs=%04x,gs=%04x",
552 ctx.seg.i386_regs.ds, ctx.seg.i386_regs.es,
553 ctx.seg.i386_regs.fs, ctx.seg.i386_regs.gs );
554 if (ctx.flags & SERVER_CTX_INTEGER)
555 fprintf( stderr, ",eax=%08x,ebx=%08x,ecx=%08x,edx=%08x,esi=%08x,edi=%08x",
556 ctx.integer.i386_regs.eax, ctx.integer.i386_regs.ebx, ctx.integer.i386_regs.ecx,
557 ctx.integer.i386_regs.edx, ctx.integer.i386_regs.esi, ctx.integer.i386_regs.edi );
558 if (ctx.flags & SERVER_CTX_DEBUG_REGISTERS)
559 fprintf( stderr, ",dr0=%08x,dr1=%08x,dr2=%08x,dr3=%08x,dr6=%08x,dr7=%08x",
560 ctx.debug.i386_regs.dr0, ctx.debug.i386_regs.dr1, ctx.debug.i386_regs.dr2,
561 ctx.debug.i386_regs.dr3, ctx.debug.i386_regs.dr6, ctx.debug.i386_regs.dr7 );
562 if (ctx.flags & SERVER_CTX_FLOATING_POINT)
564 fprintf( stderr, ",fp.ctrl=%08x,fp.status=%08x,fp.tag=%08x,fp.err_off=%08x,fp.err_sel=%08x",
565 ctx.fp.i386_regs.ctrl, ctx.fp.i386_regs.status, ctx.fp.i386_regs.tag,
566 ctx.fp.i386_regs.err_off, ctx.fp.i386_regs.err_sel );
567 fprintf( stderr, ",fp.data_off=%08x,fp.data_sel=%08x,fp.cr0npx=%08x",
568 ctx.fp.i386_regs.data_off, ctx.fp.i386_regs.data_sel, ctx.fp.i386_regs.cr0npx );
569 for (i = 0; i < 8; i++)
570 fprintf( stderr, ",fp.reg%u=%Lg", i, *(long double *)&ctx.fp.i386_regs.regs[10*i] );
572 if (ctx.flags & SERVER_CTX_EXTENDED_REGISTERS)
574 fprintf( stderr, ",extended=" );
575 dump_uints( (const int *)ctx.ext.i386_regs, sizeof(ctx.ext.i386_regs) / sizeof(int) );
577 break;
578 case CPU_x86_64:
579 if (ctx.flags & SERVER_CTX_CONTROL)
581 dump_uint64( ",rip=", &ctx.ctl.x86_64_regs.rip );
582 dump_uint64( ",rbp=", &ctx.ctl.x86_64_regs.rbp );
583 dump_uint64( ",rsp=", &ctx.ctl.x86_64_regs.rsp );
584 fprintf( stderr, ",cs=%04x,ss=%04x,flags=%08x",
585 ctx.ctl.x86_64_regs.cs, ctx.ctl.x86_64_regs.ss, ctx.ctl.x86_64_regs.flags );
587 if (ctx.flags & SERVER_CTX_INTEGER)
589 dump_uint64( ",rax=", &ctx.integer.x86_64_regs.rax );
590 dump_uint64( ",rbx=", &ctx.integer.x86_64_regs.rbx );
591 dump_uint64( ",rcx=", &ctx.integer.x86_64_regs.rcx );
592 dump_uint64( ",rdx=", &ctx.integer.x86_64_regs.rdx );
593 dump_uint64( ",rsi=", &ctx.integer.x86_64_regs.rsi );
594 dump_uint64( ",rdi=", &ctx.integer.x86_64_regs.rdi );
595 dump_uint64( ",r8=", &ctx.integer.x86_64_regs.r8 );
596 dump_uint64( ",r9=", &ctx.integer.x86_64_regs.r9 );
597 dump_uint64( ",r10=", &ctx.integer.x86_64_regs.r10 );
598 dump_uint64( ",r11=", &ctx.integer.x86_64_regs.r11 );
599 dump_uint64( ",r12=", &ctx.integer.x86_64_regs.r12 );
600 dump_uint64( ",r13=", &ctx.integer.x86_64_regs.r13 );
601 dump_uint64( ",r14=", &ctx.integer.x86_64_regs.r14 );
602 dump_uint64( ",r15=", &ctx.integer.x86_64_regs.r15 );
604 if (ctx.flags & SERVER_CTX_SEGMENTS)
605 fprintf( stderr, ",ds=%04x,es=%04x,fs=%04x,gs=%04x",
606 ctx.seg.x86_64_regs.ds, ctx.seg.x86_64_regs.es,
607 ctx.seg.x86_64_regs.fs, ctx.seg.x86_64_regs.gs );
608 if (ctx.flags & SERVER_CTX_DEBUG_REGISTERS)
610 dump_uint64( ",dr0=", &ctx.debug.x86_64_regs.dr0 );
611 dump_uint64( ",dr1=", &ctx.debug.x86_64_regs.dr1 );
612 dump_uint64( ",dr2=", &ctx.debug.x86_64_regs.dr2 );
613 dump_uint64( ",dr3=", &ctx.debug.x86_64_regs.dr3 );
614 dump_uint64( ",dr6=", &ctx.debug.x86_64_regs.dr6 );
615 dump_uint64( ",dr7=", &ctx.debug.x86_64_regs.dr7 );
617 if (ctx.flags & SERVER_CTX_FLOATING_POINT)
619 for (i = 0; i < 32; i++)
620 fprintf( stderr, ",fp%u=%08x%08x%08x%08x", i,
621 (unsigned int)(ctx.fp.x86_64_regs.fpregs[i].high >> 32),
622 (unsigned int)ctx.fp.x86_64_regs.fpregs[i].high,
623 (unsigned int)(ctx.fp.x86_64_regs.fpregs[i].low >> 32),
624 (unsigned int)ctx.fp.x86_64_regs.fpregs[i].low );
626 break;
627 case CPU_POWERPC:
628 if (ctx.flags & SERVER_CTX_CONTROL)
629 fprintf( stderr, ",iar=%08x,msr=%08x,ctr=%08x,lr=%08x,dar=%08x,dsisr=%08x,trap=%08x",
630 ctx.ctl.powerpc_regs.iar, ctx.ctl.powerpc_regs.msr, ctx.ctl.powerpc_regs.ctr,
631 ctx.ctl.powerpc_regs.lr, ctx.ctl.powerpc_regs.dar, ctx.ctl.powerpc_regs.dsisr,
632 ctx.ctl.powerpc_regs.trap );
633 if (ctx.flags & SERVER_CTX_INTEGER)
635 for (i = 0; i < 32; i++) fprintf( stderr, ",gpr%u=%08x", i, ctx.integer.powerpc_regs.gpr[i] );
636 fprintf( stderr, ",cr=%08x,xer=%08x",
637 ctx.integer.powerpc_regs.cr, ctx.integer.powerpc_regs.xer );
639 if (ctx.flags & SERVER_CTX_DEBUG_REGISTERS)
640 for (i = 0; i < 8; i++) fprintf( stderr, ",dr%u=%08x", i, ctx.debug.powerpc_regs.dr[i] );
641 if (ctx.flags & SERVER_CTX_FLOATING_POINT)
643 for (i = 0; i < 32; i++) fprintf( stderr, ",fpr%u=%g", i, ctx.fp.powerpc_regs.fpr[i] );
644 fprintf( stderr, ",fpscr=%g", ctx.fp.powerpc_regs.fpscr );
646 break;
647 case CPU_ARM:
648 if (ctx.flags & SERVER_CTX_CONTROL)
649 fprintf( stderr, ",sp=%08x,lr=%08x,pc=%08x,cpsr=%08x",
650 ctx.ctl.arm_regs.sp, ctx.ctl.arm_regs.lr,
651 ctx.ctl.arm_regs.pc, ctx.ctl.arm_regs.cpsr );
652 if (ctx.flags & SERVER_CTX_INTEGER)
653 for (i = 0; i < 13; i++) fprintf( stderr, ",r%u=%08x", i, ctx.integer.arm_regs.r[i] );
654 break;
655 case CPU_ARM64:
656 if (ctx.flags & SERVER_CTX_CONTROL)
658 dump_uint64( ",sp=", &ctx.ctl.arm64_regs.sp );
659 dump_uint64( ",pc=", &ctx.ctl.arm64_regs.pc );
660 dump_uint64( ",pstate=", &ctx.ctl.arm64_regs.pstate );
662 if (ctx.flags & SERVER_CTX_INTEGER)
664 dump_uint64( ",x0=", &ctx.integer.arm64_regs.x[0] );
665 dump_uint64( ",x1=", &ctx.integer.arm64_regs.x[1] );
666 dump_uint64( ",x2=", &ctx.integer.arm64_regs.x[2] );
667 dump_uint64( ",x3=", &ctx.integer.arm64_regs.x[3] );
668 dump_uint64( ",x4=", &ctx.integer.arm64_regs.x[4] );
669 dump_uint64( ",x5=", &ctx.integer.arm64_regs.x[5] );
670 dump_uint64( ",x6=", &ctx.integer.arm64_regs.x[6] );
671 dump_uint64( ",x7=", &ctx.integer.arm64_regs.x[7] );
672 dump_uint64( ",x8=", &ctx.integer.arm64_regs.x[8] );
673 dump_uint64( ",x9=", &ctx.integer.arm64_regs.x[9] );
674 dump_uint64( ",x10=", &ctx.integer.arm64_regs.x[10] );
675 dump_uint64( ",x11=", &ctx.integer.arm64_regs.x[11] );
676 dump_uint64( ",x12=", &ctx.integer.arm64_regs.x[12] );
677 dump_uint64( ",x13=", &ctx.integer.arm64_regs.x[13] );
678 dump_uint64( ",x14=", &ctx.integer.arm64_regs.x[14] );
679 dump_uint64( ",x15=", &ctx.integer.arm64_regs.x[15] );
680 dump_uint64( ",x16=", &ctx.integer.arm64_regs.x[16] );
681 dump_uint64( ",x17=", &ctx.integer.arm64_regs.x[17] );
682 dump_uint64( ",x18=", &ctx.integer.arm64_regs.x[18] );
683 dump_uint64( ",x19=", &ctx.integer.arm64_regs.x[19] );
684 dump_uint64( ",x20=", &ctx.integer.arm64_regs.x[20] );
685 dump_uint64( ",x21=", &ctx.integer.arm64_regs.x[21] );
686 dump_uint64( ",x22=", &ctx.integer.arm64_regs.x[22] );
687 dump_uint64( ",x23=", &ctx.integer.arm64_regs.x[23] );
688 dump_uint64( ",x24=", &ctx.integer.arm64_regs.x[24] );
689 dump_uint64( ",x25=", &ctx.integer.arm64_regs.x[25] );
690 dump_uint64( ",x26=", &ctx.integer.arm64_regs.x[26] );
691 dump_uint64( ",x27=", &ctx.integer.arm64_regs.x[27] );
692 dump_uint64( ",x28=", &ctx.integer.arm64_regs.x[28] );
693 dump_uint64( ",x29=", &ctx.integer.arm64_regs.x[29] );
694 dump_uint64( ",x30=", &ctx.integer.arm64_regs.x[30] );
696 break;
698 fputc( '}', stderr );
699 remove_data( size );
702 static void dump_varargs_debug_event( const char *prefix, data_size_t size )
704 debug_event_t event;
705 unsigned int i;
707 if (!size)
709 fprintf( stderr, "%s{}", prefix );
710 return;
712 size = min( size, sizeof(event) );
713 memset( &event, 0, sizeof(event) );
714 memcpy( &event, cur_data, size );
716 switch(event.code)
718 case EXCEPTION_DEBUG_EVENT:
719 fprintf( stderr, "%s{exception,first=%d,exc_code=%08x,flags=%08x", prefix,
720 event.exception.first, event.exception.exc_code, event.exception.flags );
721 dump_uint64( ",record=", &event.exception.record );
722 dump_uint64( ",address=", &event.exception.address );
723 fprintf( stderr, ",params={" );
724 event.exception.nb_params = min( event.exception.nb_params, EXCEPTION_MAXIMUM_PARAMETERS );
725 for (i = 0; i < event.exception.nb_params; i++)
727 dump_uint64( "", &event.exception.params[i] );
728 if (i < event.exception.nb_params) fputc( ',', stderr );
730 fprintf( stderr, "}}" );
731 break;
732 case CREATE_THREAD_DEBUG_EVENT:
733 fprintf( stderr, "%s{create_thread,thread=%04x", prefix, event.create_thread.handle );
734 dump_uint64( ",teb=", &event.create_thread.teb );
735 dump_uint64( ",start=", &event.create_thread.start );
736 fputc( '}', stderr );
737 break;
738 case CREATE_PROCESS_DEBUG_EVENT:
739 fprintf( stderr, "%s{create_process,file=%04x,process=%04x,thread=%04x", prefix,
740 event.create_process.file, event.create_process.process,
741 event.create_process.thread );
742 dump_uint64( ",base=", &event.create_process.base );
743 fprintf( stderr, ",offset=%d,size=%d",
744 event.create_process.dbg_offset, event.create_process.dbg_size );
745 dump_uint64( ",teb=", &event.create_process.teb );
746 dump_uint64( ",start=", &event.create_process.start );
747 dump_uint64( ",name=", &event.create_process.name );
748 fprintf( stderr, ",unicode=%d}", event.create_process.unicode );
749 break;
750 case EXIT_THREAD_DEBUG_EVENT:
751 fprintf( stderr, "%s{exit_thread,code=%d}", prefix, event.exit.exit_code );
752 break;
753 case EXIT_PROCESS_DEBUG_EVENT:
754 fprintf( stderr, "%s{exit_process,code=%d}", prefix, event.exit.exit_code );
755 break;
756 case LOAD_DLL_DEBUG_EVENT:
757 fprintf( stderr, "%s{load_dll,file=%04x", prefix, event.load_dll.handle );
758 dump_uint64( ",base=", &event.load_dll.base );
759 fprintf( stderr, ",offset=%d,size=%d",
760 event.load_dll.dbg_offset, event.load_dll.dbg_size );
761 dump_uint64( ",name=", &event.load_dll.name );
762 fprintf( stderr, ",unicode=%d}", event.load_dll.unicode );
763 break;
764 case UNLOAD_DLL_DEBUG_EVENT:
765 fprintf( stderr, "%s{unload_dll", prefix );
766 dump_uint64( ",base=", &event.unload_dll.base );
767 fputc( '}', stderr );
768 break;
769 case 0: /* zero is the code returned on timeouts */
770 fprintf( stderr, "%s{}", prefix );
771 break;
772 default:
773 fprintf( stderr, "%s{code=??? (%d)}", prefix, event.code );
774 break;
776 remove_data( size );
779 /* dump a unicode string contained in a buffer; helper for dump_varargs_startup_info */
780 static data_size_t dump_inline_unicode_string( const char *prefix, data_size_t pos, data_size_t len, data_size_t total_size )
782 fputs( prefix, stderr );
783 if (pos >= total_size) return pos;
784 if (len > total_size - pos) len = total_size - pos;
785 len /= sizeof(WCHAR);
786 dump_strW( (const WCHAR *)cur_data + pos/sizeof(WCHAR), len, stderr, "\"\"" );
787 return pos + len * sizeof(WCHAR);
790 static void dump_varargs_startup_info( const char *prefix, data_size_t size )
792 startup_info_t info;
793 data_size_t pos = sizeof(info);
795 memset( &info, 0, sizeof(info) );
796 memcpy( &info, cur_data, min( size, sizeof(info) ));
798 fprintf( stderr,
799 "%s{debug_flags=%x,console_flags=%x,console=%04x,hstdin=%04x,hstdout=%04x,hstderr=%04x,"
800 "x=%u,y=%u,xsize=%u,ysize=%u,xchars=%u,ychars=%u,attribute=%02x,flags=%x,show=%u",
801 prefix, info.debug_flags, info.console_flags, info.console,
802 info.hstdin, info.hstdout, info.hstderr, info.x, info.y, info.xsize, info.ysize,
803 info.xchars, info.ychars, info.attribute, info.flags, info.show );
804 pos = dump_inline_unicode_string( ",curdir=L\"", pos, info.curdir_len, size );
805 pos = dump_inline_unicode_string( "\",dllpath=L\"", pos, info.dllpath_len, size );
806 pos = dump_inline_unicode_string( "\",imagepath=L\"", pos, info.imagepath_len, size );
807 pos = dump_inline_unicode_string( "\",cmdline=L\"", pos, info.cmdline_len, size );
808 pos = dump_inline_unicode_string( "\",title=L\"", pos, info.title_len, size );
809 pos = dump_inline_unicode_string( "\",desktop=L\"", pos, info.desktop_len, size );
810 pos = dump_inline_unicode_string( "\",shellinfo=L\"", pos, info.shellinfo_len, size );
811 pos = dump_inline_unicode_string( "\",runtime=L\"", pos, info.runtime_len, size );
812 fprintf( stderr, "\"}" );
813 remove_data( size );
816 static void dump_varargs_input_records( const char *prefix, data_size_t size )
818 const INPUT_RECORD *rec = cur_data;
819 data_size_t len = size / sizeof(*rec);
821 fprintf( stderr,"%s{", prefix );
822 while (len > 0)
824 fprintf( stderr, "{%04x,...}", rec->EventType );
825 rec++;
826 if (--len) fputc( ',', stderr );
828 fputc( '}', stderr );
829 remove_data( size );
832 static void dump_varargs_rectangles( const char *prefix, data_size_t size )
834 const rectangle_t *rect = cur_data;
835 data_size_t len = size / sizeof(*rect);
837 fprintf( stderr,"%s{", prefix );
838 while (len > 0)
840 dump_rectangle( "", rect++ );
841 if (--len) fputc( ',', stderr );
843 fputc( '}', stderr );
844 remove_data( size );
847 static void dump_varargs_message_data( const char *prefix, data_size_t size )
849 /* FIXME: dump the structured data */
850 dump_varargs_bytes( prefix, size );
853 static void dump_varargs_properties( const char *prefix, data_size_t size )
855 const property_data_t *prop = cur_data;
856 data_size_t len = size / sizeof(*prop);
858 fprintf( stderr,"%s{", prefix );
859 while (len > 0)
861 fprintf( stderr, "{atom=%04x,str=%d", prop->atom, prop->string );
862 dump_uint64( ",data=", &prop->data );
863 fputc( '}', stderr );
864 prop++;
865 if (--len) fputc( ',', stderr );
867 fputc( '}', stderr );
868 remove_data( size );
871 static void dump_varargs_LUID_AND_ATTRIBUTES( const char *prefix, data_size_t size )
873 const LUID_AND_ATTRIBUTES *lat = cur_data;
874 data_size_t len = size / sizeof(*lat);
876 fprintf( stderr,"%s{", prefix );
877 while (len > 0)
879 fprintf( stderr, "{luid=%08x%08x,attr=%x}",
880 lat->Luid.HighPart, lat->Luid.LowPart, lat->Attributes );
881 lat++;
882 if (--len) fputc( ',', stderr );
884 fputc( '}', stderr );
885 remove_data( size );
888 static void dump_inline_sid( const char *prefix, const SID *sid, data_size_t size )
890 DWORD i;
892 /* security check */
893 if ((FIELD_OFFSET(SID, SubAuthority[0]) > size) ||
894 (FIELD_OFFSET(SID, SubAuthority[sid->SubAuthorityCount]) > size))
896 fprintf( stderr, "<invalid sid>" );
897 return;
900 fprintf( stderr,"%s{", prefix );
901 fprintf( stderr, "S-%u-%u", sid->Revision, MAKELONG(
902 MAKEWORD( sid->IdentifierAuthority.Value[5],
903 sid->IdentifierAuthority.Value[4] ),
904 MAKEWORD( sid->IdentifierAuthority.Value[3],
905 sid->IdentifierAuthority.Value[2] ) ) );
906 for (i = 0; i < sid->SubAuthorityCount; i++)
907 fprintf( stderr, "-%u", sid->SubAuthority[i] );
908 fputc( '}', stderr );
911 static void dump_varargs_SID( const char *prefix, data_size_t size )
913 const SID *sid = cur_data;
914 dump_inline_sid( prefix, sid, size );
915 remove_data( size );
918 static void dump_inline_acl( const char *prefix, const ACL *acl, data_size_t size )
920 const ACE_HEADER *ace;
921 ULONG i;
923 fprintf( stderr,"%s{", prefix );
924 if (size)
926 if (size < sizeof(ACL))
928 fprintf( stderr, "<invalid acl>}" );
929 return;
931 size -= sizeof(ACL);
932 ace = (const ACE_HEADER *)(acl + 1);
933 for (i = 0; i < acl->AceCount; i++)
935 const SID *sid = NULL;
936 data_size_t sid_size = 0;
938 if (size < sizeof(ACE_HEADER) || size < ace->AceSize) break;
939 size -= ace->AceSize;
940 if (i != 0) fputc( ',', stderr );
941 fprintf( stderr, "{AceType=" );
942 switch (ace->AceType)
944 case ACCESS_DENIED_ACE_TYPE:
945 sid = (const SID *)&((const ACCESS_DENIED_ACE *)ace)->SidStart;
946 sid_size = ace->AceSize - FIELD_OFFSET(ACCESS_DENIED_ACE, SidStart);
947 fprintf( stderr, "ACCESS_DENIED_ACE_TYPE,Mask=%x",
948 ((const ACCESS_DENIED_ACE *)ace)->Mask );
949 break;
950 case ACCESS_ALLOWED_ACE_TYPE:
951 sid = (const SID *)&((const ACCESS_ALLOWED_ACE *)ace)->SidStart;
952 sid_size = ace->AceSize - FIELD_OFFSET(ACCESS_ALLOWED_ACE, SidStart);
953 fprintf( stderr, "ACCESS_ALLOWED_ACE_TYPE,Mask=%x",
954 ((const ACCESS_ALLOWED_ACE *)ace)->Mask );
955 break;
956 case SYSTEM_AUDIT_ACE_TYPE:
957 sid = (const SID *)&((const SYSTEM_AUDIT_ACE *)ace)->SidStart;
958 sid_size = ace->AceSize - FIELD_OFFSET(SYSTEM_AUDIT_ACE, SidStart);
959 fprintf( stderr, "SYSTEM_AUDIT_ACE_TYPE,Mask=%x",
960 ((const SYSTEM_AUDIT_ACE *)ace)->Mask );
961 break;
962 case SYSTEM_ALARM_ACE_TYPE:
963 sid = (const SID *)&((const SYSTEM_ALARM_ACE *)ace)->SidStart;
964 sid_size = ace->AceSize - FIELD_OFFSET(SYSTEM_ALARM_ACE, SidStart);
965 fprintf( stderr, "SYSTEM_ALARM_ACE_TYPE,Mask=%x",
966 ((const SYSTEM_ALARM_ACE *)ace)->Mask );
967 break;
968 case SYSTEM_MANDATORY_LABEL_ACE_TYPE:
969 sid = (const SID *)&((const SYSTEM_MANDATORY_LABEL_ACE *)ace)->SidStart;
970 sid_size = ace->AceSize - FIELD_OFFSET(SYSTEM_MANDATORY_LABEL_ACE, SidStart);
971 fprintf( stderr, "SYSTEM_MANDATORY_LABEL_ACE_TYPE,Mask=%x",
972 ((const SYSTEM_MANDATORY_LABEL_ACE *)ace)->Mask );
973 break;
974 default:
975 fprintf( stderr, "unknown<%d>", ace->AceType );
976 break;
978 fprintf( stderr, ",AceFlags=%x", ace->AceFlags );
979 if (sid)
980 dump_inline_sid( ",Sid=", sid, sid_size );
981 ace = (const ACE_HEADER *)((const char *)ace + ace->AceSize);
982 fputc( '}', stderr );
985 fputc( '}', stderr );
988 static void dump_varargs_ACL( const char *prefix, data_size_t size )
990 const ACL *acl = cur_data;
991 dump_inline_acl( prefix, acl, size );
992 remove_data( size );
995 static void dump_inline_security_descriptor( const char *prefix, const struct security_descriptor *sd, data_size_t size )
997 fprintf( stderr,"%s{", prefix );
998 if (size >= sizeof(struct security_descriptor))
1000 size_t offset = sizeof(struct security_descriptor);
1001 fprintf( stderr, "control=%08x", sd->control );
1002 if ((sd->owner_len > FIELD_OFFSET(SID, SubAuthority[255])) || (offset + sd->owner_len > size))
1003 return;
1004 if (sd->owner_len)
1005 dump_inline_sid( ",owner=", (const SID *)((const char *)sd + offset), sd->owner_len );
1006 else
1007 fprintf( stderr, ",owner=<not present>" );
1008 offset += sd->owner_len;
1009 if ((sd->group_len > FIELD_OFFSET(SID, SubAuthority[255])) || (offset + sd->group_len > size))
1010 return;
1011 if (sd->group_len)
1012 dump_inline_sid( ",group=", (const SID *)((const char *)sd + offset), sd->group_len );
1013 else
1014 fprintf( stderr, ",group=<not present>" );
1015 offset += sd->group_len;
1016 if ((sd->sacl_len >= MAX_ACL_LEN) || (offset + sd->sacl_len > size))
1017 return;
1018 dump_inline_acl( ",sacl=", (const ACL *)((const char *)sd + offset), sd->sacl_len );
1019 offset += sd->sacl_len;
1020 if ((sd->dacl_len >= MAX_ACL_LEN) || (offset + sd->dacl_len > size))
1021 return;
1022 dump_inline_acl( ",dacl=", (const ACL *)((const char *)sd + offset), sd->dacl_len );
1023 offset += sd->dacl_len;
1025 fputc( '}', stderr );
1028 static void dump_varargs_security_descriptor( const char *prefix, data_size_t size )
1030 const struct security_descriptor *sd = cur_data;
1031 dump_inline_security_descriptor( prefix, sd, size );
1032 remove_data( size );
1035 static void dump_varargs_token_groups( const char *prefix, data_size_t size )
1037 const struct token_groups *tg = cur_data;
1039 fprintf( stderr,"%s{", prefix );
1040 if (size >= sizeof(struct token_groups))
1042 size_t offset = sizeof(*tg);
1043 fprintf( stderr, "count=%08x,", tg->count );
1044 if (tg->count * sizeof(unsigned int) <= size)
1046 unsigned int i;
1047 const unsigned int *attr = (const unsigned int *)(tg + 1);
1049 offset += tg->count * sizeof(unsigned int);
1051 fputc( '[', stderr );
1052 for (i = 0; i < tg->count; i++)
1054 const SID *sid = (const SID *)((const char *)cur_data + offset);
1055 if (i != 0)
1056 fputc( ',', stderr );
1057 fputc( '{', stderr );
1058 fprintf( stderr, "attributes=%08x", attr[i] );
1059 dump_inline_sid( ",sid=", sid, size - offset );
1060 if ((offset + FIELD_OFFSET(SID, SubAuthority[0]) > size) ||
1061 (offset + FIELD_OFFSET(SID, SubAuthority[sid->SubAuthorityCount]) > size))
1062 break;
1063 offset += FIELD_OFFSET(SID, SubAuthority[sid->SubAuthorityCount]);
1064 fputc( '}', stderr );
1066 fputc( ']', stderr );
1069 fputc( '}', stderr );
1072 static void dump_varargs_object_attributes( const char *prefix, data_size_t size )
1074 const struct object_attributes *objattr = cur_data;
1076 fprintf( stderr,"%s{", prefix );
1077 if (size)
1079 const WCHAR *str;
1081 if (size < sizeof(*objattr) ||
1082 (size - sizeof(*objattr) < objattr->sd_len) ||
1083 (size - sizeof(*objattr) - objattr->sd_len < objattr->name_len))
1085 fprintf( stderr, "***invalid***}" );
1086 remove_data( size );
1087 return;
1090 fprintf( stderr, "rootdir=%04x,attributes=%08x", objattr->rootdir, objattr->attributes );
1091 dump_inline_security_descriptor( ",sd=", (const struct security_descriptor *)(objattr + 1), objattr->sd_len );
1092 str = (const WCHAR *)objattr + (sizeof(*objattr) + objattr->sd_len) / sizeof(WCHAR);
1093 fprintf( stderr, ",name=L\"" );
1094 dump_strW( str, objattr->name_len / sizeof(WCHAR), stderr, "\"\"" );
1095 fputc( '\"', stderr );
1096 remove_data( ((sizeof(*objattr) + objattr->sd_len) / sizeof(WCHAR)) * sizeof(WCHAR) +
1097 (objattr->name_len / sizeof(WCHAR)) * sizeof(WCHAR) );
1099 fputc( '}', stderr );
1102 static void dump_varargs_filesystem_event( const char *prefix, data_size_t size )
1104 static const char * const actions[] = {
1105 NULL,
1106 "ADDED",
1107 "REMOVED",
1108 "MODIFIED",
1109 "RENAMED_OLD_NAME",
1110 "RENAMED_NEW_NAME",
1111 "ADDED_STREAM",
1112 "REMOVED_STREAM",
1113 "MODIFIED_STREAM"
1116 fprintf( stderr,"%s{", prefix );
1117 while (size)
1119 const struct filesystem_event *event = cur_data;
1120 data_size_t len = (offsetof( struct filesystem_event, name[event->len] ) + sizeof(int)-1)
1121 / sizeof(int) * sizeof(int);
1122 if (size < len) break;
1123 if (event->action < sizeof(actions)/sizeof(actions[0]) && actions[event->action])
1124 fprintf( stderr, "{action=%s", actions[event->action] );
1125 else
1126 fprintf( stderr, "{action=%u", event->action );
1127 fprintf( stderr, ",name=\"%.*s\"}", event->len, event->name );
1128 size -= len;
1129 remove_data( len );
1130 if (size)fputc( ',', stderr );
1132 fputc( '}', stderr );
1135 static void dump_varargs_rawinput_devices(const char *prefix, data_size_t size )
1137 const struct rawinput_device *device;
1139 fprintf( stderr, "%s{", prefix );
1140 while (size >= sizeof(*device))
1142 device = cur_data;
1143 fprintf( stderr, "{usage_page=%04x,usage=%04x,flags=%08x,target=%08x}",
1144 device->usage_page, device->usage, device->flags, device->target );
1145 size -= sizeof(*device);
1146 remove_data( sizeof(*device) );
1147 if (size) fputc( ',', stderr );
1149 fputc( '}', stderr );
1152 static void dump_varargs_handle_infos( const char *prefix, data_size_t size )
1154 const struct handle_info *handle;
1156 fprintf( stderr, "%s{", prefix );
1157 while (size >= sizeof(*handle))
1159 handle = cur_data;
1160 fprintf( stderr, "{owner=%04x,handle=%04x,access=%08x}",
1161 handle->owner, handle->handle, handle->access );
1162 size -= sizeof(*handle);
1163 remove_data( sizeof(*handle) );
1164 if (size) fputc( ',', stderr );
1166 fputc( '}', stderr );
1169 typedef void (*dump_func)( const void *req );
1171 /* Everything below this line is generated automatically by tools/make_requests */
1172 /* ### make_requests begin ### */
1174 static void dump_new_process_request( const struct new_process_request *req )
1176 fprintf( stderr, " inherit_all=%d", req->inherit_all );
1177 fprintf( stderr, ", create_flags=%08x", req->create_flags );
1178 fprintf( stderr, ", socket_fd=%d", req->socket_fd );
1179 fprintf( stderr, ", exe_file=%04x", req->exe_file );
1180 fprintf( stderr, ", process_access=%08x", req->process_access );
1181 fprintf( stderr, ", process_attr=%08x", req->process_attr );
1182 fprintf( stderr, ", thread_access=%08x", req->thread_access );
1183 fprintf( stderr, ", thread_attr=%08x", req->thread_attr );
1184 dump_cpu_type( ", cpu=", &req->cpu );
1185 fprintf( stderr, ", info_size=%u", req->info_size );
1186 dump_varargs_startup_info( ", info=", min(cur_size,req->info_size) );
1187 dump_varargs_unicode_str( ", env=", cur_size );
1190 static void dump_new_process_reply( const struct new_process_reply *req )
1192 fprintf( stderr, " info=%04x", req->info );
1193 fprintf( stderr, ", pid=%04x", req->pid );
1194 fprintf( stderr, ", phandle=%04x", req->phandle );
1195 fprintf( stderr, ", tid=%04x", req->tid );
1196 fprintf( stderr, ", thandle=%04x", req->thandle );
1199 static void dump_get_new_process_info_request( const struct get_new_process_info_request *req )
1201 fprintf( stderr, " info=%04x", req->info );
1204 static void dump_get_new_process_info_reply( const struct get_new_process_info_reply *req )
1206 fprintf( stderr, " success=%d", req->success );
1207 fprintf( stderr, ", exit_code=%d", req->exit_code );
1210 static void dump_new_thread_request( const struct new_thread_request *req )
1212 fprintf( stderr, " access=%08x", req->access );
1213 fprintf( stderr, ", attributes=%08x", req->attributes );
1214 fprintf( stderr, ", suspend=%d", req->suspend );
1215 fprintf( stderr, ", request_fd=%d", req->request_fd );
1218 static void dump_new_thread_reply( const struct new_thread_reply *req )
1220 fprintf( stderr, " tid=%04x", req->tid );
1221 fprintf( stderr, ", handle=%04x", req->handle );
1224 static void dump_get_startup_info_request( const struct get_startup_info_request *req )
1228 static void dump_get_startup_info_reply( const struct get_startup_info_reply *req )
1230 fprintf( stderr, " exe_file=%04x", req->exe_file );
1231 fprintf( stderr, ", info_size=%u", req->info_size );
1232 dump_varargs_startup_info( ", info=", min(cur_size,req->info_size) );
1233 dump_varargs_unicode_str( ", env=", cur_size );
1236 static void dump_init_process_done_request( const struct init_process_done_request *req )
1238 fprintf( stderr, " gui=%d", req->gui );
1239 dump_uint64( ", module=", &req->module );
1240 dump_uint64( ", ldt_copy=", &req->ldt_copy );
1241 dump_uint64( ", entry=", &req->entry );
1244 static void dump_init_thread_request( const struct init_thread_request *req )
1246 fprintf( stderr, " unix_pid=%d", req->unix_pid );
1247 fprintf( stderr, ", unix_tid=%d", req->unix_tid );
1248 fprintf( stderr, ", debug_level=%d", req->debug_level );
1249 dump_uint64( ", teb=", &req->teb );
1250 dump_uint64( ", entry=", &req->entry );
1251 fprintf( stderr, ", reply_fd=%d", req->reply_fd );
1252 fprintf( stderr, ", wait_fd=%d", req->wait_fd );
1253 dump_cpu_type( ", cpu=", &req->cpu );
1256 static void dump_init_thread_reply( const struct init_thread_reply *req )
1258 fprintf( stderr, " pid=%04x", req->pid );
1259 fprintf( stderr, ", tid=%04x", req->tid );
1260 dump_timeout( ", server_start=", &req->server_start );
1261 fprintf( stderr, ", info_size=%u", req->info_size );
1262 fprintf( stderr, ", version=%d", req->version );
1263 fprintf( stderr, ", all_cpus=%08x", req->all_cpus );
1266 static void dump_terminate_process_request( const struct terminate_process_request *req )
1268 fprintf( stderr, " handle=%04x", req->handle );
1269 fprintf( stderr, ", exit_code=%d", req->exit_code );
1272 static void dump_terminate_process_reply( const struct terminate_process_reply *req )
1274 fprintf( stderr, " self=%d", req->self );
1277 static void dump_terminate_thread_request( const struct terminate_thread_request *req )
1279 fprintf( stderr, " handle=%04x", req->handle );
1280 fprintf( stderr, ", exit_code=%d", req->exit_code );
1283 static void dump_terminate_thread_reply( const struct terminate_thread_reply *req )
1285 fprintf( stderr, " self=%d", req->self );
1286 fprintf( stderr, ", last=%d", req->last );
1289 static void dump_get_process_info_request( const struct get_process_info_request *req )
1291 fprintf( stderr, " handle=%04x", req->handle );
1294 static void dump_get_process_info_reply( const struct get_process_info_reply *req )
1296 fprintf( stderr, " pid=%04x", req->pid );
1297 fprintf( stderr, ", ppid=%04x", req->ppid );
1298 dump_uint64( ", affinity=", &req->affinity );
1299 dump_uint64( ", peb=", &req->peb );
1300 dump_timeout( ", start_time=", &req->start_time );
1301 dump_timeout( ", end_time=", &req->end_time );
1302 fprintf( stderr, ", exit_code=%d", req->exit_code );
1303 fprintf( stderr, ", priority=%d", req->priority );
1304 dump_cpu_type( ", cpu=", &req->cpu );
1305 fprintf( stderr, ", debugger_present=%d", req->debugger_present );
1306 fprintf( stderr, ", debug_children=%d", req->debug_children );
1309 static void dump_set_process_info_request( const struct set_process_info_request *req )
1311 fprintf( stderr, " handle=%04x", req->handle );
1312 fprintf( stderr, ", mask=%d", req->mask );
1313 fprintf( stderr, ", priority=%d", req->priority );
1314 dump_uint64( ", affinity=", &req->affinity );
1317 static void dump_get_thread_info_request( const struct get_thread_info_request *req )
1319 fprintf( stderr, " handle=%04x", req->handle );
1320 fprintf( stderr, ", tid_in=%04x", req->tid_in );
1323 static void dump_get_thread_info_reply( const struct get_thread_info_reply *req )
1325 fprintf( stderr, " pid=%04x", req->pid );
1326 fprintf( stderr, ", tid=%04x", req->tid );
1327 dump_uint64( ", teb=", &req->teb );
1328 dump_uint64( ", entry_point=", &req->entry_point );
1329 dump_uint64( ", affinity=", &req->affinity );
1330 fprintf( stderr, ", exit_code=%d", req->exit_code );
1331 fprintf( stderr, ", priority=%d", req->priority );
1332 fprintf( stderr, ", last=%d", req->last );
1335 static void dump_get_thread_times_request( const struct get_thread_times_request *req )
1337 fprintf( stderr, " handle=%04x", req->handle );
1340 static void dump_get_thread_times_reply( const struct get_thread_times_reply *req )
1342 dump_timeout( " creation_time=", &req->creation_time );
1343 dump_timeout( ", exit_time=", &req->exit_time );
1346 static void dump_set_thread_info_request( const struct set_thread_info_request *req )
1348 fprintf( stderr, " handle=%04x", req->handle );
1349 fprintf( stderr, ", mask=%d", req->mask );
1350 fprintf( stderr, ", priority=%d", req->priority );
1351 dump_uint64( ", affinity=", &req->affinity );
1352 dump_uint64( ", entry_point=", &req->entry_point );
1353 fprintf( stderr, ", token=%04x", req->token );
1356 static void dump_get_dll_info_request( const struct get_dll_info_request *req )
1358 fprintf( stderr, " handle=%04x", req->handle );
1359 dump_uint64( ", base_address=", &req->base_address );
1362 static void dump_get_dll_info_reply( const struct get_dll_info_reply *req )
1364 dump_uint64( " entry_point=", &req->entry_point );
1365 fprintf( stderr, ", size=%u", req->size );
1366 fprintf( stderr, ", filename_len=%u", req->filename_len );
1367 dump_varargs_unicode_str( ", filename=", cur_size );
1370 static void dump_suspend_thread_request( const struct suspend_thread_request *req )
1372 fprintf( stderr, " handle=%04x", req->handle );
1375 static void dump_suspend_thread_reply( const struct suspend_thread_reply *req )
1377 fprintf( stderr, " count=%d", req->count );
1380 static void dump_resume_thread_request( const struct resume_thread_request *req )
1382 fprintf( stderr, " handle=%04x", req->handle );
1385 static void dump_resume_thread_reply( const struct resume_thread_reply *req )
1387 fprintf( stderr, " count=%d", req->count );
1390 static void dump_load_dll_request( const struct load_dll_request *req )
1392 fprintf( stderr, " mapping=%04x", req->mapping );
1393 dump_uint64( ", base=", &req->base );
1394 dump_uint64( ", name=", &req->name );
1395 fprintf( stderr, ", size=%u", req->size );
1396 fprintf( stderr, ", dbg_offset=%d", req->dbg_offset );
1397 fprintf( stderr, ", dbg_size=%d", req->dbg_size );
1398 dump_varargs_unicode_str( ", filename=", cur_size );
1401 static void dump_unload_dll_request( const struct unload_dll_request *req )
1403 dump_uint64( " base=", &req->base );
1406 static void dump_queue_apc_request( const struct queue_apc_request *req )
1408 fprintf( stderr, " handle=%04x", req->handle );
1409 dump_apc_call( ", call=", &req->call );
1412 static void dump_queue_apc_reply( const struct queue_apc_reply *req )
1414 fprintf( stderr, " handle=%04x", req->handle );
1415 fprintf( stderr, ", self=%d", req->self );
1418 static void dump_get_apc_result_request( const struct get_apc_result_request *req )
1420 fprintf( stderr, " handle=%04x", req->handle );
1423 static void dump_get_apc_result_reply( const struct get_apc_result_reply *req )
1425 dump_apc_result( " result=", &req->result );
1428 static void dump_close_handle_request( const struct close_handle_request *req )
1430 fprintf( stderr, " handle=%04x", req->handle );
1433 static void dump_set_handle_info_request( const struct set_handle_info_request *req )
1435 fprintf( stderr, " handle=%04x", req->handle );
1436 fprintf( stderr, ", flags=%d", req->flags );
1437 fprintf( stderr, ", mask=%d", req->mask );
1440 static void dump_set_handle_info_reply( const struct set_handle_info_reply *req )
1442 fprintf( stderr, " old_flags=%d", req->old_flags );
1445 static void dump_dup_handle_request( const struct dup_handle_request *req )
1447 fprintf( stderr, " src_process=%04x", req->src_process );
1448 fprintf( stderr, ", src_handle=%04x", req->src_handle );
1449 fprintf( stderr, ", dst_process=%04x", req->dst_process );
1450 fprintf( stderr, ", access=%08x", req->access );
1451 fprintf( stderr, ", attributes=%08x", req->attributes );
1452 fprintf( stderr, ", options=%08x", req->options );
1455 static void dump_dup_handle_reply( const struct dup_handle_reply *req )
1457 fprintf( stderr, " handle=%04x", req->handle );
1458 fprintf( stderr, ", self=%d", req->self );
1459 fprintf( stderr, ", closed=%d", req->closed );
1462 static void dump_open_process_request( const struct open_process_request *req )
1464 fprintf( stderr, " pid=%04x", req->pid );
1465 fprintf( stderr, ", access=%08x", req->access );
1466 fprintf( stderr, ", attributes=%08x", req->attributes );
1469 static void dump_open_process_reply( const struct open_process_reply *req )
1471 fprintf( stderr, " handle=%04x", req->handle );
1474 static void dump_open_thread_request( const struct open_thread_request *req )
1476 fprintf( stderr, " tid=%04x", req->tid );
1477 fprintf( stderr, ", access=%08x", req->access );
1478 fprintf( stderr, ", attributes=%08x", req->attributes );
1481 static void dump_open_thread_reply( const struct open_thread_reply *req )
1483 fprintf( stderr, " handle=%04x", req->handle );
1486 static void dump_select_request( const struct select_request *req )
1488 fprintf( stderr, " flags=%d", req->flags );
1489 dump_uint64( ", cookie=", &req->cookie );
1490 dump_timeout( ", timeout=", &req->timeout );
1491 fprintf( stderr, ", prev_apc=%04x", req->prev_apc );
1492 dump_varargs_apc_result( ", result=", cur_size );
1493 dump_varargs_select_op( ", data=", cur_size );
1496 static void dump_select_reply( const struct select_reply *req )
1498 dump_timeout( " timeout=", &req->timeout );
1499 dump_apc_call( ", call=", &req->call );
1500 fprintf( stderr, ", apc_handle=%04x", req->apc_handle );
1503 static void dump_create_event_request( const struct create_event_request *req )
1505 fprintf( stderr, " access=%08x", req->access );
1506 fprintf( stderr, ", manual_reset=%d", req->manual_reset );
1507 fprintf( stderr, ", initial_state=%d", req->initial_state );
1508 dump_varargs_object_attributes( ", objattr=", cur_size );
1511 static void dump_create_event_reply( const struct create_event_reply *req )
1513 fprintf( stderr, " handle=%04x", req->handle );
1516 static void dump_event_op_request( const struct event_op_request *req )
1518 fprintf( stderr, " handle=%04x", req->handle );
1519 fprintf( stderr, ", op=%d", req->op );
1522 static void dump_query_event_request( const struct query_event_request *req )
1524 fprintf( stderr, " handle=%04x", req->handle );
1527 static void dump_query_event_reply( const struct query_event_reply *req )
1529 fprintf( stderr, " manual_reset=%d", req->manual_reset );
1530 fprintf( stderr, ", state=%d", req->state );
1533 static void dump_open_event_request( const struct open_event_request *req )
1535 fprintf( stderr, " access=%08x", req->access );
1536 fprintf( stderr, ", attributes=%08x", req->attributes );
1537 fprintf( stderr, ", rootdir=%04x", req->rootdir );
1538 dump_varargs_unicode_str( ", name=", cur_size );
1541 static void dump_open_event_reply( const struct open_event_reply *req )
1543 fprintf( stderr, " handle=%04x", req->handle );
1546 static void dump_create_keyed_event_request( const struct create_keyed_event_request *req )
1548 fprintf( stderr, " access=%08x", req->access );
1549 dump_varargs_object_attributes( ", objattr=", cur_size );
1552 static void dump_create_keyed_event_reply( const struct create_keyed_event_reply *req )
1554 fprintf( stderr, " handle=%04x", req->handle );
1557 static void dump_open_keyed_event_request( const struct open_keyed_event_request *req )
1559 fprintf( stderr, " access=%08x", req->access );
1560 fprintf( stderr, ", attributes=%08x", req->attributes );
1561 fprintf( stderr, ", rootdir=%04x", req->rootdir );
1562 dump_varargs_unicode_str( ", name=", cur_size );
1565 static void dump_open_keyed_event_reply( const struct open_keyed_event_reply *req )
1567 fprintf( stderr, " handle=%04x", req->handle );
1570 static void dump_create_mutex_request( const struct create_mutex_request *req )
1572 fprintf( stderr, " access=%08x", req->access );
1573 fprintf( stderr, ", owned=%d", req->owned );
1574 dump_varargs_object_attributes( ", objattr=", cur_size );
1577 static void dump_create_mutex_reply( const struct create_mutex_reply *req )
1579 fprintf( stderr, " handle=%04x", req->handle );
1582 static void dump_release_mutex_request( const struct release_mutex_request *req )
1584 fprintf( stderr, " handle=%04x", req->handle );
1587 static void dump_release_mutex_reply( const struct release_mutex_reply *req )
1589 fprintf( stderr, " prev_count=%08x", req->prev_count );
1592 static void dump_open_mutex_request( const struct open_mutex_request *req )
1594 fprintf( stderr, " access=%08x", req->access );
1595 fprintf( stderr, ", attributes=%08x", req->attributes );
1596 fprintf( stderr, ", rootdir=%04x", req->rootdir );
1597 dump_varargs_unicode_str( ", name=", cur_size );
1600 static void dump_open_mutex_reply( const struct open_mutex_reply *req )
1602 fprintf( stderr, " handle=%04x", req->handle );
1605 static void dump_query_mutex_request( const struct query_mutex_request *req )
1607 fprintf( stderr, " handle=%04x", req->handle );
1610 static void dump_query_mutex_reply( const struct query_mutex_reply *req )
1612 fprintf( stderr, " count=%08x", req->count );
1613 fprintf( stderr, ", owned=%d", req->owned );
1614 fprintf( stderr, ", abandoned=%d", req->abandoned );
1617 static void dump_create_semaphore_request( const struct create_semaphore_request *req )
1619 fprintf( stderr, " access=%08x", req->access );
1620 fprintf( stderr, ", initial=%08x", req->initial );
1621 fprintf( stderr, ", max=%08x", req->max );
1622 dump_varargs_object_attributes( ", objattr=", cur_size );
1625 static void dump_create_semaphore_reply( const struct create_semaphore_reply *req )
1627 fprintf( stderr, " handle=%04x", req->handle );
1630 static void dump_release_semaphore_request( const struct release_semaphore_request *req )
1632 fprintf( stderr, " handle=%04x", req->handle );
1633 fprintf( stderr, ", count=%08x", req->count );
1636 static void dump_release_semaphore_reply( const struct release_semaphore_reply *req )
1638 fprintf( stderr, " prev_count=%08x", req->prev_count );
1641 static void dump_query_semaphore_request( const struct query_semaphore_request *req )
1643 fprintf( stderr, " handle=%04x", req->handle );
1646 static void dump_query_semaphore_reply( const struct query_semaphore_reply *req )
1648 fprintf( stderr, " current=%08x", req->current );
1649 fprintf( stderr, ", max=%08x", req->max );
1652 static void dump_open_semaphore_request( const struct open_semaphore_request *req )
1654 fprintf( stderr, " access=%08x", req->access );
1655 fprintf( stderr, ", attributes=%08x", req->attributes );
1656 fprintf( stderr, ", rootdir=%04x", req->rootdir );
1657 dump_varargs_unicode_str( ", name=", cur_size );
1660 static void dump_open_semaphore_reply( const struct open_semaphore_reply *req )
1662 fprintf( stderr, " handle=%04x", req->handle );
1665 static void dump_create_file_request( const struct create_file_request *req )
1667 fprintf( stderr, " access=%08x", req->access );
1668 fprintf( stderr, ", sharing=%08x", req->sharing );
1669 fprintf( stderr, ", create=%d", req->create );
1670 fprintf( stderr, ", options=%08x", req->options );
1671 fprintf( stderr, ", attrs=%08x", req->attrs );
1672 dump_varargs_object_attributes( ", objattr=", cur_size );
1673 dump_varargs_string( ", filename=", cur_size );
1676 static void dump_create_file_reply( const struct create_file_reply *req )
1678 fprintf( stderr, " handle=%04x", req->handle );
1681 static void dump_open_file_object_request( const struct open_file_object_request *req )
1683 fprintf( stderr, " access=%08x", req->access );
1684 fprintf( stderr, ", attributes=%08x", req->attributes );
1685 fprintf( stderr, ", rootdir=%04x", req->rootdir );
1686 fprintf( stderr, ", sharing=%08x", req->sharing );
1687 fprintf( stderr, ", options=%08x", req->options );
1688 dump_varargs_unicode_str( ", filename=", cur_size );
1691 static void dump_open_file_object_reply( const struct open_file_object_reply *req )
1693 fprintf( stderr, " handle=%04x", req->handle );
1696 static void dump_alloc_file_handle_request( const struct alloc_file_handle_request *req )
1698 fprintf( stderr, " access=%08x", req->access );
1699 fprintf( stderr, ", attributes=%08x", req->attributes );
1700 fprintf( stderr, ", fd=%d", req->fd );
1703 static void dump_alloc_file_handle_reply( const struct alloc_file_handle_reply *req )
1705 fprintf( stderr, " handle=%04x", req->handle );
1708 static void dump_get_handle_unix_name_request( const struct get_handle_unix_name_request *req )
1710 fprintf( stderr, " handle=%04x", req->handle );
1713 static void dump_get_handle_unix_name_reply( const struct get_handle_unix_name_reply *req )
1715 fprintf( stderr, " name_len=%u", req->name_len );
1716 dump_varargs_string( ", name=", cur_size );
1719 static void dump_get_handle_fd_request( const struct get_handle_fd_request *req )
1721 fprintf( stderr, " handle=%04x", req->handle );
1724 static void dump_get_handle_fd_reply( const struct get_handle_fd_reply *req )
1726 fprintf( stderr, " type=%d", req->type );
1727 fprintf( stderr, ", cacheable=%d", req->cacheable );
1728 fprintf( stderr, ", access=%08x", req->access );
1729 fprintf( stderr, ", options=%08x", req->options );
1732 static void dump_get_directory_cache_entry_request( const struct get_directory_cache_entry_request *req )
1734 fprintf( stderr, " handle=%04x", req->handle );
1737 static void dump_get_directory_cache_entry_reply( const struct get_directory_cache_entry_reply *req )
1739 fprintf( stderr, " entry=%d", req->entry );
1740 dump_varargs_ints( ", free=", cur_size );
1743 static void dump_flush_request( const struct flush_request *req )
1745 fprintf( stderr, " blocking=%d", req->blocking );
1746 dump_async_data( ", async=", &req->async );
1749 static void dump_flush_reply( const struct flush_reply *req )
1751 fprintf( stderr, " event=%04x", req->event );
1754 static void dump_lock_file_request( const struct lock_file_request *req )
1756 fprintf( stderr, " handle=%04x", req->handle );
1757 dump_uint64( ", offset=", &req->offset );
1758 dump_uint64( ", count=", &req->count );
1759 fprintf( stderr, ", shared=%d", req->shared );
1760 fprintf( stderr, ", wait=%d", req->wait );
1763 static void dump_lock_file_reply( const struct lock_file_reply *req )
1765 fprintf( stderr, " handle=%04x", req->handle );
1766 fprintf( stderr, ", overlapped=%d", req->overlapped );
1769 static void dump_unlock_file_request( const struct unlock_file_request *req )
1771 fprintf( stderr, " handle=%04x", req->handle );
1772 dump_uint64( ", offset=", &req->offset );
1773 dump_uint64( ", count=", &req->count );
1776 static void dump_create_socket_request( const struct create_socket_request *req )
1778 fprintf( stderr, " access=%08x", req->access );
1779 fprintf( stderr, ", attributes=%08x", req->attributes );
1780 fprintf( stderr, ", family=%d", req->family );
1781 fprintf( stderr, ", type=%d", req->type );
1782 fprintf( stderr, ", protocol=%d", req->protocol );
1783 fprintf( stderr, ", flags=%08x", req->flags );
1786 static void dump_create_socket_reply( const struct create_socket_reply *req )
1788 fprintf( stderr, " handle=%04x", req->handle );
1791 static void dump_accept_socket_request( const struct accept_socket_request *req )
1793 fprintf( stderr, " lhandle=%04x", req->lhandle );
1794 fprintf( stderr, ", access=%08x", req->access );
1795 fprintf( stderr, ", attributes=%08x", req->attributes );
1798 static void dump_accept_socket_reply( const struct accept_socket_reply *req )
1800 fprintf( stderr, " handle=%04x", req->handle );
1803 static void dump_accept_into_socket_request( const struct accept_into_socket_request *req )
1805 fprintf( stderr, " lhandle=%04x", req->lhandle );
1806 fprintf( stderr, ", ahandle=%04x", req->ahandle );
1809 static void dump_set_socket_event_request( const struct set_socket_event_request *req )
1811 fprintf( stderr, " handle=%04x", req->handle );
1812 fprintf( stderr, ", mask=%08x", req->mask );
1813 fprintf( stderr, ", event=%04x", req->event );
1814 fprintf( stderr, ", window=%08x", req->window );
1815 fprintf( stderr, ", msg=%08x", req->msg );
1818 static void dump_get_socket_event_request( const struct get_socket_event_request *req )
1820 fprintf( stderr, " handle=%04x", req->handle );
1821 fprintf( stderr, ", service=%d", req->service );
1822 fprintf( stderr, ", c_event=%04x", req->c_event );
1825 static void dump_get_socket_event_reply( const struct get_socket_event_reply *req )
1827 fprintf( stderr, " mask=%08x", req->mask );
1828 fprintf( stderr, ", pmask=%08x", req->pmask );
1829 fprintf( stderr, ", state=%08x", req->state );
1830 dump_varargs_ints( ", errors=", cur_size );
1833 static void dump_get_socket_info_request( const struct get_socket_info_request *req )
1835 fprintf( stderr, " handle=%04x", req->handle );
1838 static void dump_get_socket_info_reply( const struct get_socket_info_reply *req )
1840 fprintf( stderr, " family=%d", req->family );
1841 fprintf( stderr, ", type=%d", req->type );
1842 fprintf( stderr, ", protocol=%d", req->protocol );
1845 static void dump_enable_socket_event_request( const struct enable_socket_event_request *req )
1847 fprintf( stderr, " handle=%04x", req->handle );
1848 fprintf( stderr, ", mask=%08x", req->mask );
1849 fprintf( stderr, ", sstate=%08x", req->sstate );
1850 fprintf( stderr, ", cstate=%08x", req->cstate );
1853 static void dump_set_socket_deferred_request( const struct set_socket_deferred_request *req )
1855 fprintf( stderr, " handle=%04x", req->handle );
1856 fprintf( stderr, ", deferred=%04x", req->deferred );
1859 static void dump_alloc_console_request( const struct alloc_console_request *req )
1861 fprintf( stderr, " access=%08x", req->access );
1862 fprintf( stderr, ", attributes=%08x", req->attributes );
1863 fprintf( stderr, ", pid=%04x", req->pid );
1864 fprintf( stderr, ", input_fd=%d", req->input_fd );
1867 static void dump_alloc_console_reply( const struct alloc_console_reply *req )
1869 fprintf( stderr, " handle_in=%04x", req->handle_in );
1870 fprintf( stderr, ", event=%04x", req->event );
1873 static void dump_free_console_request( const struct free_console_request *req )
1877 static void dump_get_console_renderer_events_request( const struct get_console_renderer_events_request *req )
1879 fprintf( stderr, " handle=%04x", req->handle );
1882 static void dump_get_console_renderer_events_reply( const struct get_console_renderer_events_reply *req )
1884 dump_varargs_bytes( " data=", cur_size );
1887 static void dump_open_console_request( const struct open_console_request *req )
1889 fprintf( stderr, " from=%04x", req->from );
1890 fprintf( stderr, ", access=%08x", req->access );
1891 fprintf( stderr, ", attributes=%08x", req->attributes );
1892 fprintf( stderr, ", share=%d", req->share );
1895 static void dump_open_console_reply( const struct open_console_reply *req )
1897 fprintf( stderr, " handle=%04x", req->handle );
1900 static void dump_get_console_wait_event_request( const struct get_console_wait_event_request *req )
1904 static void dump_get_console_wait_event_reply( const struct get_console_wait_event_reply *req )
1906 fprintf( stderr, " handle=%04x", req->handle );
1909 static void dump_get_console_mode_request( const struct get_console_mode_request *req )
1911 fprintf( stderr, " handle=%04x", req->handle );
1914 static void dump_get_console_mode_reply( const struct get_console_mode_reply *req )
1916 fprintf( stderr, " mode=%d", req->mode );
1919 static void dump_set_console_mode_request( const struct set_console_mode_request *req )
1921 fprintf( stderr, " handle=%04x", req->handle );
1922 fprintf( stderr, ", mode=%d", req->mode );
1925 static void dump_set_console_input_info_request( const struct set_console_input_info_request *req )
1927 fprintf( stderr, " handle=%04x", req->handle );
1928 fprintf( stderr, ", mask=%d", req->mask );
1929 fprintf( stderr, ", active_sb=%04x", req->active_sb );
1930 fprintf( stderr, ", history_mode=%d", req->history_mode );
1931 fprintf( stderr, ", history_size=%d", req->history_size );
1932 fprintf( stderr, ", edition_mode=%d", req->edition_mode );
1933 fprintf( stderr, ", input_cp=%d", req->input_cp );
1934 fprintf( stderr, ", output_cp=%d", req->output_cp );
1935 fprintf( stderr, ", win=%08x", req->win );
1936 dump_varargs_unicode_str( ", title=", cur_size );
1939 static void dump_get_console_input_info_request( const struct get_console_input_info_request *req )
1941 fprintf( stderr, " handle=%04x", req->handle );
1944 static void dump_get_console_input_info_reply( const struct get_console_input_info_reply *req )
1946 fprintf( stderr, " history_mode=%d", req->history_mode );
1947 fprintf( stderr, ", history_size=%d", req->history_size );
1948 fprintf( stderr, ", history_index=%d", req->history_index );
1949 fprintf( stderr, ", edition_mode=%d", req->edition_mode );
1950 fprintf( stderr, ", input_cp=%d", req->input_cp );
1951 fprintf( stderr, ", output_cp=%d", req->output_cp );
1952 fprintf( stderr, ", win=%08x", req->win );
1953 dump_varargs_unicode_str( ", title=", cur_size );
1956 static void dump_append_console_input_history_request( const struct append_console_input_history_request *req )
1958 fprintf( stderr, " handle=%04x", req->handle );
1959 dump_varargs_unicode_str( ", line=", cur_size );
1962 static void dump_get_console_input_history_request( const struct get_console_input_history_request *req )
1964 fprintf( stderr, " handle=%04x", req->handle );
1965 fprintf( stderr, ", index=%d", req->index );
1968 static void dump_get_console_input_history_reply( const struct get_console_input_history_reply *req )
1970 fprintf( stderr, " total=%d", req->total );
1971 dump_varargs_unicode_str( ", line=", cur_size );
1974 static void dump_create_console_output_request( const struct create_console_output_request *req )
1976 fprintf( stderr, " handle_in=%04x", req->handle_in );
1977 fprintf( stderr, ", access=%08x", req->access );
1978 fprintf( stderr, ", attributes=%08x", req->attributes );
1979 fprintf( stderr, ", share=%08x", req->share );
1980 fprintf( stderr, ", fd=%d", req->fd );
1983 static void dump_create_console_output_reply( const struct create_console_output_reply *req )
1985 fprintf( stderr, " handle_out=%04x", req->handle_out );
1988 static void dump_set_console_output_info_request( const struct set_console_output_info_request *req )
1990 fprintf( stderr, " handle=%04x", req->handle );
1991 fprintf( stderr, ", mask=%d", req->mask );
1992 fprintf( stderr, ", cursor_size=%d", req->cursor_size );
1993 fprintf( stderr, ", cursor_visible=%d", req->cursor_visible );
1994 fprintf( stderr, ", cursor_x=%d", req->cursor_x );
1995 fprintf( stderr, ", cursor_y=%d", req->cursor_y );
1996 fprintf( stderr, ", width=%d", req->width );
1997 fprintf( stderr, ", height=%d", req->height );
1998 fprintf( stderr, ", attr=%d", req->attr );
1999 fprintf( stderr, ", win_left=%d", req->win_left );
2000 fprintf( stderr, ", win_top=%d", req->win_top );
2001 fprintf( stderr, ", win_right=%d", req->win_right );
2002 fprintf( stderr, ", win_bottom=%d", req->win_bottom );
2003 fprintf( stderr, ", max_width=%d", req->max_width );
2004 fprintf( stderr, ", max_height=%d", req->max_height );
2005 fprintf( stderr, ", font_width=%d", req->font_width );
2006 fprintf( stderr, ", font_height=%d", req->font_height );
2009 static void dump_get_console_output_info_request( const struct get_console_output_info_request *req )
2011 fprintf( stderr, " handle=%04x", req->handle );
2014 static void dump_get_console_output_info_reply( const struct get_console_output_info_reply *req )
2016 fprintf( stderr, " cursor_size=%d", req->cursor_size );
2017 fprintf( stderr, ", cursor_visible=%d", req->cursor_visible );
2018 fprintf( stderr, ", cursor_x=%d", req->cursor_x );
2019 fprintf( stderr, ", cursor_y=%d", req->cursor_y );
2020 fprintf( stderr, ", width=%d", req->width );
2021 fprintf( stderr, ", height=%d", req->height );
2022 fprintf( stderr, ", attr=%d", req->attr );
2023 fprintf( stderr, ", win_left=%d", req->win_left );
2024 fprintf( stderr, ", win_top=%d", req->win_top );
2025 fprintf( stderr, ", win_right=%d", req->win_right );
2026 fprintf( stderr, ", win_bottom=%d", req->win_bottom );
2027 fprintf( stderr, ", max_width=%d", req->max_width );
2028 fprintf( stderr, ", max_height=%d", req->max_height );
2029 fprintf( stderr, ", font_width=%d", req->font_width );
2030 fprintf( stderr, ", font_height=%d", req->font_height );
2033 static void dump_write_console_input_request( const struct write_console_input_request *req )
2035 fprintf( stderr, " handle=%04x", req->handle );
2036 dump_varargs_input_records( ", rec=", cur_size );
2039 static void dump_write_console_input_reply( const struct write_console_input_reply *req )
2041 fprintf( stderr, " written=%d", req->written );
2044 static void dump_read_console_input_request( const struct read_console_input_request *req )
2046 fprintf( stderr, " handle=%04x", req->handle );
2047 fprintf( stderr, ", flush=%d", req->flush );
2050 static void dump_read_console_input_reply( const struct read_console_input_reply *req )
2052 fprintf( stderr, " read=%d", req->read );
2053 dump_varargs_input_records( ", rec=", cur_size );
2056 static void dump_write_console_output_request( const struct write_console_output_request *req )
2058 fprintf( stderr, " handle=%04x", req->handle );
2059 fprintf( stderr, ", x=%d", req->x );
2060 fprintf( stderr, ", y=%d", req->y );
2061 fprintf( stderr, ", mode=%d", req->mode );
2062 fprintf( stderr, ", wrap=%d", req->wrap );
2063 dump_varargs_bytes( ", data=", cur_size );
2066 static void dump_write_console_output_reply( const struct write_console_output_reply *req )
2068 fprintf( stderr, " written=%d", req->written );
2069 fprintf( stderr, ", width=%d", req->width );
2070 fprintf( stderr, ", height=%d", req->height );
2073 static void dump_fill_console_output_request( const struct fill_console_output_request *req )
2075 fprintf( stderr, " handle=%04x", req->handle );
2076 fprintf( stderr, ", x=%d", req->x );
2077 fprintf( stderr, ", y=%d", req->y );
2078 fprintf( stderr, ", mode=%d", req->mode );
2079 fprintf( stderr, ", count=%d", req->count );
2080 fprintf( stderr, ", wrap=%d", req->wrap );
2081 dump_char_info( ", data=", &req->data );
2084 static void dump_fill_console_output_reply( const struct fill_console_output_reply *req )
2086 fprintf( stderr, " written=%d", req->written );
2089 static void dump_read_console_output_request( const struct read_console_output_request *req )
2091 fprintf( stderr, " handle=%04x", req->handle );
2092 fprintf( stderr, ", x=%d", req->x );
2093 fprintf( stderr, ", y=%d", req->y );
2094 fprintf( stderr, ", mode=%d", req->mode );
2095 fprintf( stderr, ", wrap=%d", req->wrap );
2098 static void dump_read_console_output_reply( const struct read_console_output_reply *req )
2100 fprintf( stderr, " width=%d", req->width );
2101 fprintf( stderr, ", height=%d", req->height );
2102 dump_varargs_bytes( ", data=", cur_size );
2105 static void dump_move_console_output_request( const struct move_console_output_request *req )
2107 fprintf( stderr, " handle=%04x", req->handle );
2108 fprintf( stderr, ", x_src=%d", req->x_src );
2109 fprintf( stderr, ", y_src=%d", req->y_src );
2110 fprintf( stderr, ", x_dst=%d", req->x_dst );
2111 fprintf( stderr, ", y_dst=%d", req->y_dst );
2112 fprintf( stderr, ", w=%d", req->w );
2113 fprintf( stderr, ", h=%d", req->h );
2116 static void dump_send_console_signal_request( const struct send_console_signal_request *req )
2118 fprintf( stderr, " signal=%d", req->signal );
2119 fprintf( stderr, ", group_id=%04x", req->group_id );
2122 static void dump_read_directory_changes_request( const struct read_directory_changes_request *req )
2124 fprintf( stderr, " filter=%08x", req->filter );
2125 fprintf( stderr, ", subtree=%d", req->subtree );
2126 fprintf( stderr, ", want_data=%d", req->want_data );
2127 dump_async_data( ", async=", &req->async );
2130 static void dump_read_change_request( const struct read_change_request *req )
2132 fprintf( stderr, " handle=%04x", req->handle );
2135 static void dump_read_change_reply( const struct read_change_reply *req )
2137 dump_varargs_filesystem_event( " events=", cur_size );
2140 static void dump_create_mapping_request( const struct create_mapping_request *req )
2142 fprintf( stderr, " access=%08x", req->access );
2143 fprintf( stderr, ", protect=%08x", req->protect );
2144 dump_uint64( ", size=", &req->size );
2145 fprintf( stderr, ", file_handle=%04x", req->file_handle );
2146 dump_varargs_object_attributes( ", objattr=", cur_size );
2149 static void dump_create_mapping_reply( const struct create_mapping_reply *req )
2151 fprintf( stderr, " handle=%04x", req->handle );
2154 static void dump_open_mapping_request( const struct open_mapping_request *req )
2156 fprintf( stderr, " access=%08x", req->access );
2157 fprintf( stderr, ", attributes=%08x", req->attributes );
2158 fprintf( stderr, ", rootdir=%04x", req->rootdir );
2159 dump_varargs_unicode_str( ", name=", cur_size );
2162 static void dump_open_mapping_reply( const struct open_mapping_reply *req )
2164 fprintf( stderr, " handle=%04x", req->handle );
2167 static void dump_get_mapping_info_request( const struct get_mapping_info_request *req )
2169 fprintf( stderr, " handle=%04x", req->handle );
2170 fprintf( stderr, ", access=%08x", req->access );
2173 static void dump_get_mapping_info_reply( const struct get_mapping_info_reply *req )
2175 dump_uint64( " size=", &req->size );
2176 fprintf( stderr, ", protect=%d", req->protect );
2177 fprintf( stderr, ", header_size=%d", req->header_size );
2178 dump_uint64( ", base=", &req->base );
2179 fprintf( stderr, ", mapping=%04x", req->mapping );
2180 fprintf( stderr, ", shared_file=%04x", req->shared_file );
2183 static void dump_get_mapping_committed_range_request( const struct get_mapping_committed_range_request *req )
2185 fprintf( stderr, " handle=%04x", req->handle );
2186 dump_uint64( ", offset=", &req->offset );
2189 static void dump_get_mapping_committed_range_reply( const struct get_mapping_committed_range_reply *req )
2191 dump_uint64( " size=", &req->size );
2192 fprintf( stderr, ", committed=%d", req->committed );
2195 static void dump_add_mapping_committed_range_request( const struct add_mapping_committed_range_request *req )
2197 fprintf( stderr, " handle=%04x", req->handle );
2198 dump_uint64( ", offset=", &req->offset );
2199 dump_uint64( ", size=", &req->size );
2202 static void dump_create_snapshot_request( const struct create_snapshot_request *req )
2204 fprintf( stderr, " attributes=%08x", req->attributes );
2205 fprintf( stderr, ", flags=%08x", req->flags );
2208 static void dump_create_snapshot_reply( const struct create_snapshot_reply *req )
2210 fprintf( stderr, " handle=%04x", req->handle );
2213 static void dump_next_process_request( const struct next_process_request *req )
2215 fprintf( stderr, " handle=%04x", req->handle );
2216 fprintf( stderr, ", reset=%d", req->reset );
2219 static void dump_next_process_reply( const struct next_process_reply *req )
2221 fprintf( stderr, " count=%d", req->count );
2222 fprintf( stderr, ", pid=%04x", req->pid );
2223 fprintf( stderr, ", ppid=%04x", req->ppid );
2224 fprintf( stderr, ", threads=%d", req->threads );
2225 fprintf( stderr, ", priority=%d", req->priority );
2226 fprintf( stderr, ", handles=%d", req->handles );
2227 fprintf( stderr, ", unix_pid=%d", req->unix_pid );
2228 dump_varargs_unicode_str( ", filename=", cur_size );
2231 static void dump_next_thread_request( const struct next_thread_request *req )
2233 fprintf( stderr, " handle=%04x", req->handle );
2234 fprintf( stderr, ", reset=%d", req->reset );
2237 static void dump_next_thread_reply( const struct next_thread_reply *req )
2239 fprintf( stderr, " count=%d", req->count );
2240 fprintf( stderr, ", pid=%04x", req->pid );
2241 fprintf( stderr, ", tid=%04x", req->tid );
2242 fprintf( stderr, ", base_pri=%d", req->base_pri );
2243 fprintf( stderr, ", delta_pri=%d", req->delta_pri );
2246 static void dump_wait_debug_event_request( const struct wait_debug_event_request *req )
2248 fprintf( stderr, " get_handle=%d", req->get_handle );
2251 static void dump_wait_debug_event_reply( const struct wait_debug_event_reply *req )
2253 fprintf( stderr, " pid=%04x", req->pid );
2254 fprintf( stderr, ", tid=%04x", req->tid );
2255 fprintf( stderr, ", wait=%04x", req->wait );
2256 dump_varargs_debug_event( ", event=", cur_size );
2259 static void dump_queue_exception_event_request( const struct queue_exception_event_request *req )
2261 fprintf( stderr, " first=%d", req->first );
2262 fprintf( stderr, ", code=%08x", req->code );
2263 fprintf( stderr, ", flags=%08x", req->flags );
2264 dump_uint64( ", record=", &req->record );
2265 dump_uint64( ", address=", &req->address );
2266 fprintf( stderr, ", len=%u", req->len );
2267 dump_varargs_uints64( ", params=", min(cur_size,req->len) );
2268 dump_varargs_context( ", context=", cur_size );
2271 static void dump_queue_exception_event_reply( const struct queue_exception_event_reply *req )
2273 fprintf( stderr, " handle=%04x", req->handle );
2276 static void dump_get_exception_status_request( const struct get_exception_status_request *req )
2278 fprintf( stderr, " handle=%04x", req->handle );
2281 static void dump_get_exception_status_reply( const struct get_exception_status_reply *req )
2283 dump_varargs_context( " context=", cur_size );
2286 static void dump_continue_debug_event_request( const struct continue_debug_event_request *req )
2288 fprintf( stderr, " pid=%04x", req->pid );
2289 fprintf( stderr, ", tid=%04x", req->tid );
2290 fprintf( stderr, ", status=%d", req->status );
2293 static void dump_debug_process_request( const struct debug_process_request *req )
2295 fprintf( stderr, " pid=%04x", req->pid );
2296 fprintf( stderr, ", attach=%d", req->attach );
2299 static void dump_debug_break_request( const struct debug_break_request *req )
2301 fprintf( stderr, " handle=%04x", req->handle );
2304 static void dump_debug_break_reply( const struct debug_break_reply *req )
2306 fprintf( stderr, " self=%d", req->self );
2309 static void dump_set_debugger_kill_on_exit_request( const struct set_debugger_kill_on_exit_request *req )
2311 fprintf( stderr, " kill_on_exit=%d", req->kill_on_exit );
2314 static void dump_read_process_memory_request( const struct read_process_memory_request *req )
2316 fprintf( stderr, " handle=%04x", req->handle );
2317 dump_uint64( ", addr=", &req->addr );
2320 static void dump_read_process_memory_reply( const struct read_process_memory_reply *req )
2322 dump_varargs_bytes( " data=", cur_size );
2325 static void dump_write_process_memory_request( const struct write_process_memory_request *req )
2327 fprintf( stderr, " handle=%04x", req->handle );
2328 dump_uint64( ", addr=", &req->addr );
2329 dump_varargs_bytes( ", data=", cur_size );
2332 static void dump_create_key_request( const struct create_key_request *req )
2334 fprintf( stderr, " access=%08x", req->access );
2335 fprintf( stderr, ", options=%08x", req->options );
2336 dump_varargs_object_attributes( ", objattr=", cur_size );
2337 dump_varargs_unicode_str( ", class=", cur_size );
2340 static void dump_create_key_reply( const struct create_key_reply *req )
2342 fprintf( stderr, " hkey=%04x", req->hkey );
2343 fprintf( stderr, ", created=%d", req->created );
2346 static void dump_open_key_request( const struct open_key_request *req )
2348 fprintf( stderr, " parent=%04x", req->parent );
2349 fprintf( stderr, ", access=%08x", req->access );
2350 fprintf( stderr, ", attributes=%08x", req->attributes );
2351 dump_varargs_unicode_str( ", name=", cur_size );
2354 static void dump_open_key_reply( const struct open_key_reply *req )
2356 fprintf( stderr, " hkey=%04x", req->hkey );
2359 static void dump_delete_key_request( const struct delete_key_request *req )
2361 fprintf( stderr, " hkey=%04x", req->hkey );
2364 static void dump_flush_key_request( const struct flush_key_request *req )
2366 fprintf( stderr, " hkey=%04x", req->hkey );
2369 static void dump_enum_key_request( const struct enum_key_request *req )
2371 fprintf( stderr, " hkey=%04x", req->hkey );
2372 fprintf( stderr, ", index=%d", req->index );
2373 fprintf( stderr, ", info_class=%d", req->info_class );
2376 static void dump_enum_key_reply( const struct enum_key_reply *req )
2378 fprintf( stderr, " subkeys=%d", req->subkeys );
2379 fprintf( stderr, ", max_subkey=%d", req->max_subkey );
2380 fprintf( stderr, ", max_class=%d", req->max_class );
2381 fprintf( stderr, ", values=%d", req->values );
2382 fprintf( stderr, ", max_value=%d", req->max_value );
2383 fprintf( stderr, ", max_data=%d", req->max_data );
2384 dump_timeout( ", modif=", &req->modif );
2385 fprintf( stderr, ", total=%u", req->total );
2386 fprintf( stderr, ", namelen=%u", req->namelen );
2387 dump_varargs_unicode_str( ", name=", min(cur_size,req->namelen) );
2388 dump_varargs_unicode_str( ", class=", cur_size );
2391 static void dump_set_key_value_request( const struct set_key_value_request *req )
2393 fprintf( stderr, " hkey=%04x", req->hkey );
2394 fprintf( stderr, ", type=%d", req->type );
2395 fprintf( stderr, ", namelen=%u", req->namelen );
2396 dump_varargs_unicode_str( ", name=", min(cur_size,req->namelen) );
2397 dump_varargs_bytes( ", data=", cur_size );
2400 static void dump_get_key_value_request( const struct get_key_value_request *req )
2402 fprintf( stderr, " hkey=%04x", req->hkey );
2403 dump_varargs_unicode_str( ", name=", cur_size );
2406 static void dump_get_key_value_reply( const struct get_key_value_reply *req )
2408 fprintf( stderr, " type=%d", req->type );
2409 fprintf( stderr, ", total=%u", req->total );
2410 dump_varargs_bytes( ", data=", cur_size );
2413 static void dump_enum_key_value_request( const struct enum_key_value_request *req )
2415 fprintf( stderr, " hkey=%04x", req->hkey );
2416 fprintf( stderr, ", index=%d", req->index );
2417 fprintf( stderr, ", info_class=%d", req->info_class );
2420 static void dump_enum_key_value_reply( const struct enum_key_value_reply *req )
2422 fprintf( stderr, " type=%d", req->type );
2423 fprintf( stderr, ", total=%u", req->total );
2424 fprintf( stderr, ", namelen=%u", req->namelen );
2425 dump_varargs_unicode_str( ", name=", min(cur_size,req->namelen) );
2426 dump_varargs_bytes( ", data=", cur_size );
2429 static void dump_delete_key_value_request( const struct delete_key_value_request *req )
2431 fprintf( stderr, " hkey=%04x", req->hkey );
2432 dump_varargs_unicode_str( ", name=", cur_size );
2435 static void dump_load_registry_request( const struct load_registry_request *req )
2437 fprintf( stderr, " file=%04x", req->file );
2438 dump_varargs_object_attributes( ", objattr=", cur_size );
2441 static void dump_unload_registry_request( const struct unload_registry_request *req )
2443 fprintf( stderr, " hkey=%04x", req->hkey );
2446 static void dump_save_registry_request( const struct save_registry_request *req )
2448 fprintf( stderr, " hkey=%04x", req->hkey );
2449 fprintf( stderr, ", file=%04x", req->file );
2452 static void dump_set_registry_notification_request( const struct set_registry_notification_request *req )
2454 fprintf( stderr, " hkey=%04x", req->hkey );
2455 fprintf( stderr, ", event=%04x", req->event );
2456 fprintf( stderr, ", subtree=%d", req->subtree );
2457 fprintf( stderr, ", filter=%08x", req->filter );
2460 static void dump_create_timer_request( const struct create_timer_request *req )
2462 fprintf( stderr, " access=%08x", req->access );
2463 fprintf( stderr, ", manual=%d", req->manual );
2464 dump_varargs_object_attributes( ", objattr=", cur_size );
2467 static void dump_create_timer_reply( const struct create_timer_reply *req )
2469 fprintf( stderr, " handle=%04x", req->handle );
2472 static void dump_open_timer_request( const struct open_timer_request *req )
2474 fprintf( stderr, " access=%08x", req->access );
2475 fprintf( stderr, ", attributes=%08x", req->attributes );
2476 fprintf( stderr, ", rootdir=%04x", req->rootdir );
2477 dump_varargs_unicode_str( ", name=", cur_size );
2480 static void dump_open_timer_reply( const struct open_timer_reply *req )
2482 fprintf( stderr, " handle=%04x", req->handle );
2485 static void dump_set_timer_request( const struct set_timer_request *req )
2487 fprintf( stderr, " handle=%04x", req->handle );
2488 dump_timeout( ", expire=", &req->expire );
2489 dump_uint64( ", callback=", &req->callback );
2490 dump_uint64( ", arg=", &req->arg );
2491 fprintf( stderr, ", period=%d", req->period );
2494 static void dump_set_timer_reply( const struct set_timer_reply *req )
2496 fprintf( stderr, " signaled=%d", req->signaled );
2499 static void dump_cancel_timer_request( const struct cancel_timer_request *req )
2501 fprintf( stderr, " handle=%04x", req->handle );
2504 static void dump_cancel_timer_reply( const struct cancel_timer_reply *req )
2506 fprintf( stderr, " signaled=%d", req->signaled );
2509 static void dump_get_timer_info_request( const struct get_timer_info_request *req )
2511 fprintf( stderr, " handle=%04x", req->handle );
2514 static void dump_get_timer_info_reply( const struct get_timer_info_reply *req )
2516 dump_timeout( " when=", &req->when );
2517 fprintf( stderr, ", signaled=%d", req->signaled );
2520 static void dump_get_thread_context_request( const struct get_thread_context_request *req )
2522 fprintf( stderr, " handle=%04x", req->handle );
2523 fprintf( stderr, ", flags=%08x", req->flags );
2524 fprintf( stderr, ", suspend=%d", req->suspend );
2527 static void dump_get_thread_context_reply( const struct get_thread_context_reply *req )
2529 fprintf( stderr, " self=%d", req->self );
2530 dump_varargs_context( ", context=", cur_size );
2533 static void dump_set_thread_context_request( const struct set_thread_context_request *req )
2535 fprintf( stderr, " handle=%04x", req->handle );
2536 fprintf( stderr, ", suspend=%d", req->suspend );
2537 dump_varargs_context( ", context=", cur_size );
2540 static void dump_set_thread_context_reply( const struct set_thread_context_reply *req )
2542 fprintf( stderr, " self=%d", req->self );
2545 static void dump_get_selector_entry_request( const struct get_selector_entry_request *req )
2547 fprintf( stderr, " handle=%04x", req->handle );
2548 fprintf( stderr, ", entry=%d", req->entry );
2551 static void dump_get_selector_entry_reply( const struct get_selector_entry_reply *req )
2553 fprintf( stderr, " base=%08x", req->base );
2554 fprintf( stderr, ", limit=%08x", req->limit );
2555 fprintf( stderr, ", flags=%02x", req->flags );
2558 static void dump_add_atom_request( const struct add_atom_request *req )
2560 fprintf( stderr, " table=%04x", req->table );
2561 dump_varargs_unicode_str( ", name=", cur_size );
2564 static void dump_add_atom_reply( const struct add_atom_reply *req )
2566 fprintf( stderr, " atom=%04x", req->atom );
2569 static void dump_delete_atom_request( const struct delete_atom_request *req )
2571 fprintf( stderr, " table=%04x", req->table );
2572 fprintf( stderr, ", atom=%04x", req->atom );
2575 static void dump_find_atom_request( const struct find_atom_request *req )
2577 fprintf( stderr, " table=%04x", req->table );
2578 dump_varargs_unicode_str( ", name=", cur_size );
2581 static void dump_find_atom_reply( const struct find_atom_reply *req )
2583 fprintf( stderr, " atom=%04x", req->atom );
2586 static void dump_get_atom_information_request( const struct get_atom_information_request *req )
2588 fprintf( stderr, " table=%04x", req->table );
2589 fprintf( stderr, ", atom=%04x", req->atom );
2592 static void dump_get_atom_information_reply( const struct get_atom_information_reply *req )
2594 fprintf( stderr, " count=%d", req->count );
2595 fprintf( stderr, ", pinned=%d", req->pinned );
2596 fprintf( stderr, ", total=%u", req->total );
2597 dump_varargs_unicode_str( ", name=", cur_size );
2600 static void dump_set_atom_information_request( const struct set_atom_information_request *req )
2602 fprintf( stderr, " table=%04x", req->table );
2603 fprintf( stderr, ", atom=%04x", req->atom );
2604 fprintf( stderr, ", pinned=%d", req->pinned );
2607 static void dump_empty_atom_table_request( const struct empty_atom_table_request *req )
2609 fprintf( stderr, " table=%04x", req->table );
2610 fprintf( stderr, ", if_pinned=%d", req->if_pinned );
2613 static void dump_init_atom_table_request( const struct init_atom_table_request *req )
2615 fprintf( stderr, " entries=%d", req->entries );
2618 static void dump_init_atom_table_reply( const struct init_atom_table_reply *req )
2620 fprintf( stderr, " table=%04x", req->table );
2623 static void dump_get_msg_queue_request( const struct get_msg_queue_request *req )
2627 static void dump_get_msg_queue_reply( const struct get_msg_queue_reply *req )
2629 fprintf( stderr, " handle=%04x", req->handle );
2632 static void dump_set_queue_fd_request( const struct set_queue_fd_request *req )
2634 fprintf( stderr, " handle=%04x", req->handle );
2637 static void dump_set_queue_mask_request( const struct set_queue_mask_request *req )
2639 fprintf( stderr, " wake_mask=%08x", req->wake_mask );
2640 fprintf( stderr, ", changed_mask=%08x", req->changed_mask );
2641 fprintf( stderr, ", skip_wait=%d", req->skip_wait );
2644 static void dump_set_queue_mask_reply( const struct set_queue_mask_reply *req )
2646 fprintf( stderr, " wake_bits=%08x", req->wake_bits );
2647 fprintf( stderr, ", changed_bits=%08x", req->changed_bits );
2650 static void dump_get_queue_status_request( const struct get_queue_status_request *req )
2652 fprintf( stderr, " clear_bits=%08x", req->clear_bits );
2655 static void dump_get_queue_status_reply( const struct get_queue_status_reply *req )
2657 fprintf( stderr, " wake_bits=%08x", req->wake_bits );
2658 fprintf( stderr, ", changed_bits=%08x", req->changed_bits );
2661 static void dump_get_process_idle_event_request( const struct get_process_idle_event_request *req )
2663 fprintf( stderr, " handle=%04x", req->handle );
2666 static void dump_get_process_idle_event_reply( const struct get_process_idle_event_reply *req )
2668 fprintf( stderr, " event=%04x", req->event );
2671 static void dump_send_message_request( const struct send_message_request *req )
2673 fprintf( stderr, " id=%04x", req->id );
2674 fprintf( stderr, ", type=%d", req->type );
2675 fprintf( stderr, ", flags=%d", req->flags );
2676 fprintf( stderr, ", win=%08x", req->win );
2677 fprintf( stderr, ", msg=%08x", req->msg );
2678 dump_uint64( ", wparam=", &req->wparam );
2679 dump_uint64( ", lparam=", &req->lparam );
2680 dump_timeout( ", timeout=", &req->timeout );
2681 dump_varargs_message_data( ", data=", cur_size );
2684 static void dump_post_quit_message_request( const struct post_quit_message_request *req )
2686 fprintf( stderr, " exit_code=%d", req->exit_code );
2689 static void dump_send_hardware_message_request( const struct send_hardware_message_request *req )
2691 fprintf( stderr, " win=%08x", req->win );
2692 dump_hw_input( ", input=", &req->input );
2693 fprintf( stderr, ", flags=%08x", req->flags );
2696 static void dump_send_hardware_message_reply( const struct send_hardware_message_reply *req )
2698 fprintf( stderr, " wait=%d", req->wait );
2699 fprintf( stderr, ", prev_x=%d", req->prev_x );
2700 fprintf( stderr, ", prev_y=%d", req->prev_y );
2701 fprintf( stderr, ", new_x=%d", req->new_x );
2702 fprintf( stderr, ", new_y=%d", req->new_y );
2703 dump_varargs_bytes( ", keystate=", cur_size );
2706 static void dump_get_message_request( const struct get_message_request *req )
2708 fprintf( stderr, " flags=%08x", req->flags );
2709 fprintf( stderr, ", get_win=%08x", req->get_win );
2710 fprintf( stderr, ", get_first=%08x", req->get_first );
2711 fprintf( stderr, ", get_last=%08x", req->get_last );
2712 fprintf( stderr, ", hw_id=%08x", req->hw_id );
2713 fprintf( stderr, ", wake_mask=%08x", req->wake_mask );
2714 fprintf( stderr, ", changed_mask=%08x", req->changed_mask );
2717 static void dump_get_message_reply( const struct get_message_reply *req )
2719 fprintf( stderr, " win=%08x", req->win );
2720 fprintf( stderr, ", msg=%08x", req->msg );
2721 dump_uint64( ", wparam=", &req->wparam );
2722 dump_uint64( ", lparam=", &req->lparam );
2723 fprintf( stderr, ", type=%d", req->type );
2724 fprintf( stderr, ", x=%d", req->x );
2725 fprintf( stderr, ", y=%d", req->y );
2726 fprintf( stderr, ", time=%08x", req->time );
2727 fprintf( stderr, ", active_hooks=%08x", req->active_hooks );
2728 fprintf( stderr, ", total=%u", req->total );
2729 dump_varargs_message_data( ", data=", cur_size );
2732 static void dump_reply_message_request( const struct reply_message_request *req )
2734 fprintf( stderr, " remove=%d", req->remove );
2735 dump_uint64( ", result=", &req->result );
2736 dump_varargs_bytes( ", data=", cur_size );
2739 static void dump_accept_hardware_message_request( const struct accept_hardware_message_request *req )
2741 fprintf( stderr, " hw_id=%08x", req->hw_id );
2742 fprintf( stderr, ", remove=%d", req->remove );
2745 static void dump_get_message_reply_request( const struct get_message_reply_request *req )
2747 fprintf( stderr, " cancel=%d", req->cancel );
2750 static void dump_get_message_reply_reply( const struct get_message_reply_reply *req )
2752 dump_uint64( " result=", &req->result );
2753 dump_varargs_bytes( ", data=", cur_size );
2756 static void dump_set_win_timer_request( const struct set_win_timer_request *req )
2758 fprintf( stderr, " win=%08x", req->win );
2759 fprintf( stderr, ", msg=%08x", req->msg );
2760 fprintf( stderr, ", rate=%08x", req->rate );
2761 dump_uint64( ", id=", &req->id );
2762 dump_uint64( ", lparam=", &req->lparam );
2765 static void dump_set_win_timer_reply( const struct set_win_timer_reply *req )
2767 dump_uint64( " id=", &req->id );
2770 static void dump_kill_win_timer_request( const struct kill_win_timer_request *req )
2772 fprintf( stderr, " win=%08x", req->win );
2773 dump_uint64( ", id=", &req->id );
2774 fprintf( stderr, ", msg=%08x", req->msg );
2777 static void dump_is_window_hung_request( const struct is_window_hung_request *req )
2779 fprintf( stderr, " win=%08x", req->win );
2782 static void dump_is_window_hung_reply( const struct is_window_hung_reply *req )
2784 fprintf( stderr, " is_hung=%d", req->is_hung );
2787 static void dump_get_serial_info_request( const struct get_serial_info_request *req )
2789 fprintf( stderr, " handle=%04x", req->handle );
2790 fprintf( stderr, ", flags=%d", req->flags );
2793 static void dump_get_serial_info_reply( const struct get_serial_info_reply *req )
2795 fprintf( stderr, " readinterval=%08x", req->readinterval );
2796 fprintf( stderr, ", readconst=%08x", req->readconst );
2797 fprintf( stderr, ", readmult=%08x", req->readmult );
2798 fprintf( stderr, ", writeconst=%08x", req->writeconst );
2799 fprintf( stderr, ", writemult=%08x", req->writemult );
2800 fprintf( stderr, ", eventmask=%08x", req->eventmask );
2801 fprintf( stderr, ", cookie=%08x", req->cookie );
2802 fprintf( stderr, ", pending_write=%08x", req->pending_write );
2805 static void dump_set_serial_info_request( const struct set_serial_info_request *req )
2807 fprintf( stderr, " handle=%04x", req->handle );
2808 fprintf( stderr, ", flags=%d", req->flags );
2809 fprintf( stderr, ", readinterval=%08x", req->readinterval );
2810 fprintf( stderr, ", readconst=%08x", req->readconst );
2811 fprintf( stderr, ", readmult=%08x", req->readmult );
2812 fprintf( stderr, ", writeconst=%08x", req->writeconst );
2813 fprintf( stderr, ", writemult=%08x", req->writemult );
2814 fprintf( stderr, ", eventmask=%08x", req->eventmask );
2817 static void dump_register_async_request( const struct register_async_request *req )
2819 fprintf( stderr, " type=%d", req->type );
2820 dump_async_data( ", async=", &req->async );
2821 fprintf( stderr, ", count=%d", req->count );
2824 static void dump_cancel_async_request( const struct cancel_async_request *req )
2826 fprintf( stderr, " handle=%04x", req->handle );
2827 dump_uint64( ", iosb=", &req->iosb );
2828 fprintf( stderr, ", only_thread=%d", req->only_thread );
2831 static void dump_read_request( const struct read_request *req )
2833 fprintf( stderr, " blocking=%d", req->blocking );
2834 dump_async_data( ", async=", &req->async );
2835 dump_uint64( ", pos=", &req->pos );
2838 static void dump_read_reply( const struct read_reply *req )
2840 fprintf( stderr, " wait=%04x", req->wait );
2841 fprintf( stderr, ", options=%08x", req->options );
2842 dump_varargs_bytes( ", data=", cur_size );
2845 static void dump_write_request( const struct write_request *req )
2847 fprintf( stderr, " blocking=%d", req->blocking );
2848 dump_async_data( ", async=", &req->async );
2849 dump_uint64( ", pos=", &req->pos );
2850 dump_varargs_bytes( ", data=", cur_size );
2853 static void dump_write_reply( const struct write_reply *req )
2855 fprintf( stderr, " wait=%04x", req->wait );
2856 fprintf( stderr, ", options=%08x", req->options );
2857 fprintf( stderr, ", size=%u", req->size );
2860 static void dump_ioctl_request( const struct ioctl_request *req )
2862 dump_ioctl_code( " code=", &req->code );
2863 dump_async_data( ", async=", &req->async );
2864 fprintf( stderr, ", blocking=%d", req->blocking );
2865 dump_varargs_bytes( ", in_data=", cur_size );
2868 static void dump_ioctl_reply( const struct ioctl_reply *req )
2870 fprintf( stderr, " wait=%04x", req->wait );
2871 fprintf( stderr, ", options=%08x", req->options );
2872 dump_varargs_bytes( ", out_data=", cur_size );
2875 static void dump_set_irp_result_request( const struct set_irp_result_request *req )
2877 fprintf( stderr, " handle=%04x", req->handle );
2878 fprintf( stderr, ", status=%08x", req->status );
2879 fprintf( stderr, ", size=%u", req->size );
2880 dump_uint64( ", file_ptr=", &req->file_ptr );
2881 dump_varargs_bytes( ", data=", cur_size );
2884 static void dump_get_irp_result_request( const struct get_irp_result_request *req )
2886 fprintf( stderr, " handle=%04x", req->handle );
2887 dump_uint64( ", user_arg=", &req->user_arg );
2890 static void dump_get_irp_result_reply( const struct get_irp_result_reply *req )
2892 fprintf( stderr, " size=%u", req->size );
2893 dump_varargs_bytes( ", out_data=", cur_size );
2896 static void dump_create_named_pipe_request( const struct create_named_pipe_request *req )
2898 fprintf( stderr, " access=%08x", req->access );
2899 fprintf( stderr, ", options=%08x", req->options );
2900 fprintf( stderr, ", sharing=%08x", req->sharing );
2901 fprintf( stderr, ", maxinstances=%08x", req->maxinstances );
2902 fprintf( stderr, ", outsize=%08x", req->outsize );
2903 fprintf( stderr, ", insize=%08x", req->insize );
2904 dump_timeout( ", timeout=", &req->timeout );
2905 fprintf( stderr, ", flags=%08x", req->flags );
2906 dump_varargs_object_attributes( ", objattr=", cur_size );
2909 static void dump_create_named_pipe_reply( const struct create_named_pipe_reply *req )
2911 fprintf( stderr, " handle=%04x", req->handle );
2914 static void dump_get_named_pipe_info_request( const struct get_named_pipe_info_request *req )
2916 fprintf( stderr, " handle=%04x", req->handle );
2919 static void dump_get_named_pipe_info_reply( const struct get_named_pipe_info_reply *req )
2921 fprintf( stderr, " flags=%08x", req->flags );
2922 fprintf( stderr, ", sharing=%08x", req->sharing );
2923 fprintf( stderr, ", maxinstances=%08x", req->maxinstances );
2924 fprintf( stderr, ", instances=%08x", req->instances );
2925 fprintf( stderr, ", outsize=%08x", req->outsize );
2926 fprintf( stderr, ", insize=%08x", req->insize );
2929 static void dump_set_named_pipe_info_request( const struct set_named_pipe_info_request *req )
2931 fprintf( stderr, " handle=%04x", req->handle );
2932 fprintf( stderr, ", flags=%08x", req->flags );
2935 static void dump_create_window_request( const struct create_window_request *req )
2937 fprintf( stderr, " parent=%08x", req->parent );
2938 fprintf( stderr, ", owner=%08x", req->owner );
2939 fprintf( stderr, ", atom=%04x", req->atom );
2940 dump_uint64( ", instance=", &req->instance );
2941 dump_varargs_unicode_str( ", class=", cur_size );
2944 static void dump_create_window_reply( const struct create_window_reply *req )
2946 fprintf( stderr, " handle=%08x", req->handle );
2947 fprintf( stderr, ", parent=%08x", req->parent );
2948 fprintf( stderr, ", owner=%08x", req->owner );
2949 fprintf( stderr, ", extra=%d", req->extra );
2950 dump_uint64( ", class_ptr=", &req->class_ptr );
2953 static void dump_destroy_window_request( const struct destroy_window_request *req )
2955 fprintf( stderr, " handle=%08x", req->handle );
2958 static void dump_get_desktop_window_request( const struct get_desktop_window_request *req )
2960 fprintf( stderr, " force=%d", req->force );
2963 static void dump_get_desktop_window_reply( const struct get_desktop_window_reply *req )
2965 fprintf( stderr, " top_window=%08x", req->top_window );
2966 fprintf( stderr, ", msg_window=%08x", req->msg_window );
2969 static void dump_set_window_owner_request( const struct set_window_owner_request *req )
2971 fprintf( stderr, " handle=%08x", req->handle );
2972 fprintf( stderr, ", owner=%08x", req->owner );
2975 static void dump_set_window_owner_reply( const struct set_window_owner_reply *req )
2977 fprintf( stderr, " full_owner=%08x", req->full_owner );
2978 fprintf( stderr, ", prev_owner=%08x", req->prev_owner );
2981 static void dump_get_window_info_request( const struct get_window_info_request *req )
2983 fprintf( stderr, " handle=%08x", req->handle );
2986 static void dump_get_window_info_reply( const struct get_window_info_reply *req )
2988 fprintf( stderr, " full_handle=%08x", req->full_handle );
2989 fprintf( stderr, ", last_active=%08x", req->last_active );
2990 fprintf( stderr, ", pid=%04x", req->pid );
2991 fprintf( stderr, ", tid=%04x", req->tid );
2992 fprintf( stderr, ", atom=%04x", req->atom );
2993 fprintf( stderr, ", is_unicode=%d", req->is_unicode );
2996 static void dump_set_window_info_request( const struct set_window_info_request *req )
2998 fprintf( stderr, " flags=%04x", req->flags );
2999 fprintf( stderr, ", is_unicode=%d", req->is_unicode );
3000 fprintf( stderr, ", handle=%08x", req->handle );
3001 fprintf( stderr, ", style=%08x", req->style );
3002 fprintf( stderr, ", ex_style=%08x", req->ex_style );
3003 fprintf( stderr, ", id=%08x", req->id );
3004 dump_uint64( ", instance=", &req->instance );
3005 dump_uint64( ", user_data=", &req->user_data );
3006 fprintf( stderr, ", extra_offset=%d", req->extra_offset );
3007 fprintf( stderr, ", extra_size=%u", req->extra_size );
3008 dump_uint64( ", extra_value=", &req->extra_value );
3011 static void dump_set_window_info_reply( const struct set_window_info_reply *req )
3013 fprintf( stderr, " old_style=%08x", req->old_style );
3014 fprintf( stderr, ", old_ex_style=%08x", req->old_ex_style );
3015 dump_uint64( ", old_instance=", &req->old_instance );
3016 dump_uint64( ", old_user_data=", &req->old_user_data );
3017 dump_uint64( ", old_extra_value=", &req->old_extra_value );
3018 fprintf( stderr, ", old_id=%08x", req->old_id );
3021 static void dump_set_parent_request( const struct set_parent_request *req )
3023 fprintf( stderr, " handle=%08x", req->handle );
3024 fprintf( stderr, ", parent=%08x", req->parent );
3027 static void dump_set_parent_reply( const struct set_parent_reply *req )
3029 fprintf( stderr, " old_parent=%08x", req->old_parent );
3030 fprintf( stderr, ", full_parent=%08x", req->full_parent );
3033 static void dump_get_window_parents_request( const struct get_window_parents_request *req )
3035 fprintf( stderr, " handle=%08x", req->handle );
3038 static void dump_get_window_parents_reply( const struct get_window_parents_reply *req )
3040 fprintf( stderr, " count=%d", req->count );
3041 dump_varargs_user_handles( ", parents=", cur_size );
3044 static void dump_get_window_children_request( const struct get_window_children_request *req )
3046 fprintf( stderr, " desktop=%04x", req->desktop );
3047 fprintf( stderr, ", parent=%08x", req->parent );
3048 fprintf( stderr, ", atom=%04x", req->atom );
3049 fprintf( stderr, ", tid=%04x", req->tid );
3050 dump_varargs_unicode_str( ", class=", cur_size );
3053 static void dump_get_window_children_reply( const struct get_window_children_reply *req )
3055 fprintf( stderr, " count=%d", req->count );
3056 dump_varargs_user_handles( ", children=", cur_size );
3059 static void dump_get_window_children_from_point_request( const struct get_window_children_from_point_request *req )
3061 fprintf( stderr, " parent=%08x", req->parent );
3062 fprintf( stderr, ", x=%d", req->x );
3063 fprintf( stderr, ", y=%d", req->y );
3066 static void dump_get_window_children_from_point_reply( const struct get_window_children_from_point_reply *req )
3068 fprintf( stderr, " count=%d", req->count );
3069 dump_varargs_user_handles( ", children=", cur_size );
3072 static void dump_get_window_tree_request( const struct get_window_tree_request *req )
3074 fprintf( stderr, " handle=%08x", req->handle );
3077 static void dump_get_window_tree_reply( const struct get_window_tree_reply *req )
3079 fprintf( stderr, " parent=%08x", req->parent );
3080 fprintf( stderr, ", owner=%08x", req->owner );
3081 fprintf( stderr, ", next_sibling=%08x", req->next_sibling );
3082 fprintf( stderr, ", prev_sibling=%08x", req->prev_sibling );
3083 fprintf( stderr, ", first_sibling=%08x", req->first_sibling );
3084 fprintf( stderr, ", last_sibling=%08x", req->last_sibling );
3085 fprintf( stderr, ", first_child=%08x", req->first_child );
3086 fprintf( stderr, ", last_child=%08x", req->last_child );
3089 static void dump_set_window_pos_request( const struct set_window_pos_request *req )
3091 fprintf( stderr, " swp_flags=%04x", req->swp_flags );
3092 fprintf( stderr, ", paint_flags=%04x", req->paint_flags );
3093 fprintf( stderr, ", handle=%08x", req->handle );
3094 fprintf( stderr, ", previous=%08x", req->previous );
3095 dump_rectangle( ", window=", &req->window );
3096 dump_rectangle( ", client=", &req->client );
3097 dump_varargs_rectangles( ", valid=", cur_size );
3100 static void dump_set_window_pos_reply( const struct set_window_pos_reply *req )
3102 fprintf( stderr, " new_style=%08x", req->new_style );
3103 fprintf( stderr, ", new_ex_style=%08x", req->new_ex_style );
3104 fprintf( stderr, ", surface_win=%08x", req->surface_win );
3107 static void dump_get_window_rectangles_request( const struct get_window_rectangles_request *req )
3109 fprintf( stderr, " handle=%08x", req->handle );
3110 fprintf( stderr, ", relative=%d", req->relative );
3113 static void dump_get_window_rectangles_reply( const struct get_window_rectangles_reply *req )
3115 dump_rectangle( " window=", &req->window );
3116 dump_rectangle( ", visible=", &req->visible );
3117 dump_rectangle( ", client=", &req->client );
3120 static void dump_get_window_text_request( const struct get_window_text_request *req )
3122 fprintf( stderr, " handle=%08x", req->handle );
3125 static void dump_get_window_text_reply( const struct get_window_text_reply *req )
3127 dump_varargs_unicode_str( " text=", cur_size );
3130 static void dump_set_window_text_request( const struct set_window_text_request *req )
3132 fprintf( stderr, " handle=%08x", req->handle );
3133 dump_varargs_unicode_str( ", text=", cur_size );
3136 static void dump_get_windows_offset_request( const struct get_windows_offset_request *req )
3138 fprintf( stderr, " from=%08x", req->from );
3139 fprintf( stderr, ", to=%08x", req->to );
3142 static void dump_get_windows_offset_reply( const struct get_windows_offset_reply *req )
3144 fprintf( stderr, " x=%d", req->x );
3145 fprintf( stderr, ", y=%d", req->y );
3146 fprintf( stderr, ", mirror=%d", req->mirror );
3149 static void dump_get_visible_region_request( const struct get_visible_region_request *req )
3151 fprintf( stderr, " window=%08x", req->window );
3152 fprintf( stderr, ", flags=%08x", req->flags );
3155 static void dump_get_visible_region_reply( const struct get_visible_region_reply *req )
3157 fprintf( stderr, " top_win=%08x", req->top_win );
3158 dump_rectangle( ", top_rect=", &req->top_rect );
3159 dump_rectangle( ", win_rect=", &req->win_rect );
3160 fprintf( stderr, ", paint_flags=%08x", req->paint_flags );
3161 fprintf( stderr, ", total_size=%u", req->total_size );
3162 dump_varargs_rectangles( ", region=", cur_size );
3165 static void dump_get_surface_region_request( const struct get_surface_region_request *req )
3167 fprintf( stderr, " window=%08x", req->window );
3170 static void dump_get_surface_region_reply( const struct get_surface_region_reply *req )
3172 dump_rectangle( " visible_rect=", &req->visible_rect );
3173 fprintf( stderr, ", total_size=%u", req->total_size );
3174 dump_varargs_rectangles( ", region=", cur_size );
3177 static void dump_get_window_region_request( const struct get_window_region_request *req )
3179 fprintf( stderr, " window=%08x", req->window );
3182 static void dump_get_window_region_reply( const struct get_window_region_reply *req )
3184 fprintf( stderr, " total_size=%u", req->total_size );
3185 dump_varargs_rectangles( ", region=", cur_size );
3188 static void dump_set_window_region_request( const struct set_window_region_request *req )
3190 fprintf( stderr, " window=%08x", req->window );
3191 fprintf( stderr, ", redraw=%d", req->redraw );
3192 dump_varargs_rectangles( ", region=", cur_size );
3195 static void dump_get_update_region_request( const struct get_update_region_request *req )
3197 fprintf( stderr, " window=%08x", req->window );
3198 fprintf( stderr, ", from_child=%08x", req->from_child );
3199 fprintf( stderr, ", flags=%08x", req->flags );
3202 static void dump_get_update_region_reply( const struct get_update_region_reply *req )
3204 fprintf( stderr, " child=%08x", req->child );
3205 fprintf( stderr, ", flags=%08x", req->flags );
3206 fprintf( stderr, ", total_size=%u", req->total_size );
3207 dump_varargs_rectangles( ", region=", cur_size );
3210 static void dump_update_window_zorder_request( const struct update_window_zorder_request *req )
3212 fprintf( stderr, " window=%08x", req->window );
3213 dump_rectangle( ", rect=", &req->rect );
3216 static void dump_redraw_window_request( const struct redraw_window_request *req )
3218 fprintf( stderr, " window=%08x", req->window );
3219 fprintf( stderr, ", flags=%08x", req->flags );
3220 dump_varargs_rectangles( ", region=", cur_size );
3223 static void dump_set_window_property_request( const struct set_window_property_request *req )
3225 fprintf( stderr, " window=%08x", req->window );
3226 dump_uint64( ", data=", &req->data );
3227 fprintf( stderr, ", atom=%04x", req->atom );
3228 dump_varargs_unicode_str( ", name=", cur_size );
3231 static void dump_remove_window_property_request( const struct remove_window_property_request *req )
3233 fprintf( stderr, " window=%08x", req->window );
3234 fprintf( stderr, ", atom=%04x", req->atom );
3235 dump_varargs_unicode_str( ", name=", cur_size );
3238 static void dump_remove_window_property_reply( const struct remove_window_property_reply *req )
3240 dump_uint64( " data=", &req->data );
3243 static void dump_get_window_property_request( const struct get_window_property_request *req )
3245 fprintf( stderr, " window=%08x", req->window );
3246 fprintf( stderr, ", atom=%04x", req->atom );
3247 dump_varargs_unicode_str( ", name=", cur_size );
3250 static void dump_get_window_property_reply( const struct get_window_property_reply *req )
3252 dump_uint64( " data=", &req->data );
3255 static void dump_get_window_properties_request( const struct get_window_properties_request *req )
3257 fprintf( stderr, " window=%08x", req->window );
3260 static void dump_get_window_properties_reply( const struct get_window_properties_reply *req )
3262 fprintf( stderr, " total=%d", req->total );
3263 dump_varargs_properties( ", props=", cur_size );
3266 static void dump_create_winstation_request( const struct create_winstation_request *req )
3268 fprintf( stderr, " flags=%08x", req->flags );
3269 fprintf( stderr, ", access=%08x", req->access );
3270 fprintf( stderr, ", attributes=%08x", req->attributes );
3271 fprintf( stderr, ", rootdir=%04x", req->rootdir );
3272 dump_varargs_unicode_str( ", name=", cur_size );
3275 static void dump_create_winstation_reply( const struct create_winstation_reply *req )
3277 fprintf( stderr, " handle=%04x", req->handle );
3280 static void dump_open_winstation_request( const struct open_winstation_request *req )
3282 fprintf( stderr, " access=%08x", req->access );
3283 fprintf( stderr, ", attributes=%08x", req->attributes );
3284 fprintf( stderr, ", rootdir=%04x", req->rootdir );
3285 dump_varargs_unicode_str( ", name=", cur_size );
3288 static void dump_open_winstation_reply( const struct open_winstation_reply *req )
3290 fprintf( stderr, " handle=%04x", req->handle );
3293 static void dump_close_winstation_request( const struct close_winstation_request *req )
3295 fprintf( stderr, " handle=%04x", req->handle );
3298 static void dump_get_process_winstation_request( const struct get_process_winstation_request *req )
3302 static void dump_get_process_winstation_reply( const struct get_process_winstation_reply *req )
3304 fprintf( stderr, " handle=%04x", req->handle );
3307 static void dump_set_process_winstation_request( const struct set_process_winstation_request *req )
3309 fprintf( stderr, " handle=%04x", req->handle );
3312 static void dump_enum_winstation_request( const struct enum_winstation_request *req )
3314 fprintf( stderr, " index=%08x", req->index );
3317 static void dump_enum_winstation_reply( const struct enum_winstation_reply *req )
3319 fprintf( stderr, " next=%08x", req->next );
3320 dump_varargs_unicode_str( ", name=", cur_size );
3323 static void dump_create_desktop_request( const struct create_desktop_request *req )
3325 fprintf( stderr, " flags=%08x", req->flags );
3326 fprintf( stderr, ", access=%08x", req->access );
3327 fprintf( stderr, ", attributes=%08x", req->attributes );
3328 dump_varargs_unicode_str( ", name=", cur_size );
3331 static void dump_create_desktop_reply( const struct create_desktop_reply *req )
3333 fprintf( stderr, " handle=%04x", req->handle );
3336 static void dump_open_desktop_request( const struct open_desktop_request *req )
3338 fprintf( stderr, " winsta=%04x", req->winsta );
3339 fprintf( stderr, ", flags=%08x", req->flags );
3340 fprintf( stderr, ", access=%08x", req->access );
3341 fprintf( stderr, ", attributes=%08x", req->attributes );
3342 dump_varargs_unicode_str( ", name=", cur_size );
3345 static void dump_open_desktop_reply( const struct open_desktop_reply *req )
3347 fprintf( stderr, " handle=%04x", req->handle );
3350 static void dump_open_input_desktop_request( const struct open_input_desktop_request *req )
3352 fprintf( stderr, " flags=%08x", req->flags );
3353 fprintf( stderr, ", access=%08x", req->access );
3354 fprintf( stderr, ", attributes=%08x", req->attributes );
3357 static void dump_open_input_desktop_reply( const struct open_input_desktop_reply *req )
3359 fprintf( stderr, " handle=%04x", req->handle );
3362 static void dump_close_desktop_request( const struct close_desktop_request *req )
3364 fprintf( stderr, " handle=%04x", req->handle );
3367 static void dump_get_thread_desktop_request( const struct get_thread_desktop_request *req )
3369 fprintf( stderr, " tid=%04x", req->tid );
3372 static void dump_get_thread_desktop_reply( const struct get_thread_desktop_reply *req )
3374 fprintf( stderr, " handle=%04x", req->handle );
3377 static void dump_set_thread_desktop_request( const struct set_thread_desktop_request *req )
3379 fprintf( stderr, " handle=%04x", req->handle );
3382 static void dump_enum_desktop_request( const struct enum_desktop_request *req )
3384 fprintf( stderr, " winstation=%04x", req->winstation );
3385 fprintf( stderr, ", index=%08x", req->index );
3388 static void dump_enum_desktop_reply( const struct enum_desktop_reply *req )
3390 fprintf( stderr, " next=%08x", req->next );
3391 dump_varargs_unicode_str( ", name=", cur_size );
3394 static void dump_set_user_object_info_request( const struct set_user_object_info_request *req )
3396 fprintf( stderr, " handle=%04x", req->handle );
3397 fprintf( stderr, ", flags=%08x", req->flags );
3398 fprintf( stderr, ", obj_flags=%08x", req->obj_flags );
3401 static void dump_set_user_object_info_reply( const struct set_user_object_info_reply *req )
3403 fprintf( stderr, " is_desktop=%d", req->is_desktop );
3404 fprintf( stderr, ", old_obj_flags=%08x", req->old_obj_flags );
3405 dump_varargs_unicode_str( ", name=", cur_size );
3408 static void dump_register_hotkey_request( const struct register_hotkey_request *req )
3410 fprintf( stderr, " window=%08x", req->window );
3411 fprintf( stderr, ", id=%d", req->id );
3412 fprintf( stderr, ", flags=%08x", req->flags );
3413 fprintf( stderr, ", vkey=%08x", req->vkey );
3416 static void dump_register_hotkey_reply( const struct register_hotkey_reply *req )
3418 fprintf( stderr, " replaced=%d", req->replaced );
3419 fprintf( stderr, ", flags=%08x", req->flags );
3420 fprintf( stderr, ", vkey=%08x", req->vkey );
3423 static void dump_unregister_hotkey_request( const struct unregister_hotkey_request *req )
3425 fprintf( stderr, " window=%08x", req->window );
3426 fprintf( stderr, ", id=%d", req->id );
3429 static void dump_unregister_hotkey_reply( const struct unregister_hotkey_reply *req )
3431 fprintf( stderr, " flags=%08x", req->flags );
3432 fprintf( stderr, ", vkey=%08x", req->vkey );
3435 static void dump_attach_thread_input_request( const struct attach_thread_input_request *req )
3437 fprintf( stderr, " tid_from=%04x", req->tid_from );
3438 fprintf( stderr, ", tid_to=%04x", req->tid_to );
3439 fprintf( stderr, ", attach=%d", req->attach );
3442 static void dump_get_thread_input_request( const struct get_thread_input_request *req )
3444 fprintf( stderr, " tid=%04x", req->tid );
3447 static void dump_get_thread_input_reply( const struct get_thread_input_reply *req )
3449 fprintf( stderr, " focus=%08x", req->focus );
3450 fprintf( stderr, ", capture=%08x", req->capture );
3451 fprintf( stderr, ", active=%08x", req->active );
3452 fprintf( stderr, ", foreground=%08x", req->foreground );
3453 fprintf( stderr, ", menu_owner=%08x", req->menu_owner );
3454 fprintf( stderr, ", move_size=%08x", req->move_size );
3455 fprintf( stderr, ", caret=%08x", req->caret );
3456 fprintf( stderr, ", cursor=%08x", req->cursor );
3457 fprintf( stderr, ", show_count=%d", req->show_count );
3458 dump_rectangle( ", rect=", &req->rect );
3461 static void dump_get_last_input_time_request( const struct get_last_input_time_request *req )
3465 static void dump_get_last_input_time_reply( const struct get_last_input_time_reply *req )
3467 fprintf( stderr, " time=%08x", req->time );
3470 static void dump_get_key_state_request( const struct get_key_state_request *req )
3472 fprintf( stderr, " tid=%04x", req->tid );
3473 fprintf( stderr, ", key=%d", req->key );
3476 static void dump_get_key_state_reply( const struct get_key_state_reply *req )
3478 fprintf( stderr, " state=%02x", req->state );
3479 dump_varargs_bytes( ", keystate=", cur_size );
3482 static void dump_set_key_state_request( const struct set_key_state_request *req )
3484 fprintf( stderr, " tid=%04x", req->tid );
3485 fprintf( stderr, ", async=%d", req->async );
3486 dump_varargs_bytes( ", keystate=", cur_size );
3489 static void dump_set_foreground_window_request( const struct set_foreground_window_request *req )
3491 fprintf( stderr, " handle=%08x", req->handle );
3494 static void dump_set_foreground_window_reply( const struct set_foreground_window_reply *req )
3496 fprintf( stderr, " previous=%08x", req->previous );
3497 fprintf( stderr, ", send_msg_old=%d", req->send_msg_old );
3498 fprintf( stderr, ", send_msg_new=%d", req->send_msg_new );
3501 static void dump_set_focus_window_request( const struct set_focus_window_request *req )
3503 fprintf( stderr, " handle=%08x", req->handle );
3506 static void dump_set_focus_window_reply( const struct set_focus_window_reply *req )
3508 fprintf( stderr, " previous=%08x", req->previous );
3511 static void dump_set_active_window_request( const struct set_active_window_request *req )
3513 fprintf( stderr, " handle=%08x", req->handle );
3516 static void dump_set_active_window_reply( const struct set_active_window_reply *req )
3518 fprintf( stderr, " previous=%08x", req->previous );
3521 static void dump_set_capture_window_request( const struct set_capture_window_request *req )
3523 fprintf( stderr, " handle=%08x", req->handle );
3524 fprintf( stderr, ", flags=%08x", req->flags );
3527 static void dump_set_capture_window_reply( const struct set_capture_window_reply *req )
3529 fprintf( stderr, " previous=%08x", req->previous );
3530 fprintf( stderr, ", full_handle=%08x", req->full_handle );
3533 static void dump_set_caret_window_request( const struct set_caret_window_request *req )
3535 fprintf( stderr, " handle=%08x", req->handle );
3536 fprintf( stderr, ", width=%d", req->width );
3537 fprintf( stderr, ", height=%d", req->height );
3540 static void dump_set_caret_window_reply( const struct set_caret_window_reply *req )
3542 fprintf( stderr, " previous=%08x", req->previous );
3543 dump_rectangle( ", old_rect=", &req->old_rect );
3544 fprintf( stderr, ", old_hide=%d", req->old_hide );
3545 fprintf( stderr, ", old_state=%d", req->old_state );
3548 static void dump_set_caret_info_request( const struct set_caret_info_request *req )
3550 fprintf( stderr, " flags=%08x", req->flags );
3551 fprintf( stderr, ", handle=%08x", req->handle );
3552 fprintf( stderr, ", x=%d", req->x );
3553 fprintf( stderr, ", y=%d", req->y );
3554 fprintf( stderr, ", hide=%d", req->hide );
3555 fprintf( stderr, ", state=%d", req->state );
3558 static void dump_set_caret_info_reply( const struct set_caret_info_reply *req )
3560 fprintf( stderr, " full_handle=%08x", req->full_handle );
3561 dump_rectangle( ", old_rect=", &req->old_rect );
3562 fprintf( stderr, ", old_hide=%d", req->old_hide );
3563 fprintf( stderr, ", old_state=%d", req->old_state );
3566 static void dump_set_hook_request( const struct set_hook_request *req )
3568 fprintf( stderr, " id=%d", req->id );
3569 fprintf( stderr, ", pid=%04x", req->pid );
3570 fprintf( stderr, ", tid=%04x", req->tid );
3571 fprintf( stderr, ", event_min=%d", req->event_min );
3572 fprintf( stderr, ", event_max=%d", req->event_max );
3573 dump_uint64( ", proc=", &req->proc );
3574 fprintf( stderr, ", flags=%d", req->flags );
3575 fprintf( stderr, ", unicode=%d", req->unicode );
3576 dump_varargs_unicode_str( ", module=", cur_size );
3579 static void dump_set_hook_reply( const struct set_hook_reply *req )
3581 fprintf( stderr, " handle=%08x", req->handle );
3582 fprintf( stderr, ", active_hooks=%08x", req->active_hooks );
3585 static void dump_remove_hook_request( const struct remove_hook_request *req )
3587 fprintf( stderr, " handle=%08x", req->handle );
3588 dump_uint64( ", proc=", &req->proc );
3589 fprintf( stderr, ", id=%d", req->id );
3592 static void dump_remove_hook_reply( const struct remove_hook_reply *req )
3594 fprintf( stderr, " active_hooks=%08x", req->active_hooks );
3597 static void dump_start_hook_chain_request( const struct start_hook_chain_request *req )
3599 fprintf( stderr, " id=%d", req->id );
3600 fprintf( stderr, ", event=%d", req->event );
3601 fprintf( stderr, ", window=%08x", req->window );
3602 fprintf( stderr, ", object_id=%d", req->object_id );
3603 fprintf( stderr, ", child_id=%d", req->child_id );
3606 static void dump_start_hook_chain_reply( const struct start_hook_chain_reply *req )
3608 fprintf( stderr, " handle=%08x", req->handle );
3609 fprintf( stderr, ", pid=%04x", req->pid );
3610 fprintf( stderr, ", tid=%04x", req->tid );
3611 fprintf( stderr, ", unicode=%d", req->unicode );
3612 dump_uint64( ", proc=", &req->proc );
3613 fprintf( stderr, ", active_hooks=%08x", req->active_hooks );
3614 dump_varargs_unicode_str( ", module=", cur_size );
3617 static void dump_finish_hook_chain_request( const struct finish_hook_chain_request *req )
3619 fprintf( stderr, " id=%d", req->id );
3622 static void dump_get_hook_info_request( const struct get_hook_info_request *req )
3624 fprintf( stderr, " handle=%08x", req->handle );
3625 fprintf( stderr, ", get_next=%d", req->get_next );
3626 fprintf( stderr, ", event=%d", req->event );
3627 fprintf( stderr, ", window=%08x", req->window );
3628 fprintf( stderr, ", object_id=%d", req->object_id );
3629 fprintf( stderr, ", child_id=%d", req->child_id );
3632 static void dump_get_hook_info_reply( const struct get_hook_info_reply *req )
3634 fprintf( stderr, " handle=%08x", req->handle );
3635 fprintf( stderr, ", id=%d", req->id );
3636 fprintf( stderr, ", pid=%04x", req->pid );
3637 fprintf( stderr, ", tid=%04x", req->tid );
3638 dump_uint64( ", proc=", &req->proc );
3639 fprintf( stderr, ", unicode=%d", req->unicode );
3640 dump_varargs_unicode_str( ", module=", cur_size );
3643 static void dump_create_class_request( const struct create_class_request *req )
3645 fprintf( stderr, " local=%d", req->local );
3646 fprintf( stderr, ", atom=%04x", req->atom );
3647 fprintf( stderr, ", style=%08x", req->style );
3648 dump_uint64( ", instance=", &req->instance );
3649 fprintf( stderr, ", extra=%d", req->extra );
3650 fprintf( stderr, ", win_extra=%d", req->win_extra );
3651 dump_uint64( ", client_ptr=", &req->client_ptr );
3652 dump_varargs_unicode_str( ", name=", cur_size );
3655 static void dump_create_class_reply( const struct create_class_reply *req )
3657 fprintf( stderr, " atom=%04x", req->atom );
3660 static void dump_destroy_class_request( const struct destroy_class_request *req )
3662 fprintf( stderr, " atom=%04x", req->atom );
3663 dump_uint64( ", instance=", &req->instance );
3664 dump_varargs_unicode_str( ", name=", cur_size );
3667 static void dump_destroy_class_reply( const struct destroy_class_reply *req )
3669 dump_uint64( " client_ptr=", &req->client_ptr );
3672 static void dump_set_class_info_request( const struct set_class_info_request *req )
3674 fprintf( stderr, " window=%08x", req->window );
3675 fprintf( stderr, ", flags=%08x", req->flags );
3676 fprintf( stderr, ", atom=%04x", req->atom );
3677 fprintf( stderr, ", style=%08x", req->style );
3678 fprintf( stderr, ", win_extra=%d", req->win_extra );
3679 dump_uint64( ", instance=", &req->instance );
3680 fprintf( stderr, ", extra_offset=%d", req->extra_offset );
3681 fprintf( stderr, ", extra_size=%u", req->extra_size );
3682 dump_uint64( ", extra_value=", &req->extra_value );
3685 static void dump_set_class_info_reply( const struct set_class_info_reply *req )
3687 fprintf( stderr, " old_atom=%04x", req->old_atom );
3688 fprintf( stderr, ", old_style=%08x", req->old_style );
3689 fprintf( stderr, ", old_extra=%d", req->old_extra );
3690 fprintf( stderr, ", old_win_extra=%d", req->old_win_extra );
3691 dump_uint64( ", old_instance=", &req->old_instance );
3692 dump_uint64( ", old_extra_value=", &req->old_extra_value );
3695 static void dump_set_clipboard_info_request( const struct set_clipboard_info_request *req )
3697 fprintf( stderr, " flags=%08x", req->flags );
3698 fprintf( stderr, ", clipboard=%08x", req->clipboard );
3699 fprintf( stderr, ", owner=%08x", req->owner );
3700 fprintf( stderr, ", viewer=%08x", req->viewer );
3701 fprintf( stderr, ", seqno=%08x", req->seqno );
3704 static void dump_set_clipboard_info_reply( const struct set_clipboard_info_reply *req )
3706 fprintf( stderr, " flags=%08x", req->flags );
3707 fprintf( stderr, ", old_clipboard=%08x", req->old_clipboard );
3708 fprintf( stderr, ", old_owner=%08x", req->old_owner );
3709 fprintf( stderr, ", old_viewer=%08x", req->old_viewer );
3710 fprintf( stderr, ", seqno=%08x", req->seqno );
3713 static void dump_empty_clipboard_request( const struct empty_clipboard_request *req )
3717 static void dump_open_token_request( const struct open_token_request *req )
3719 fprintf( stderr, " handle=%04x", req->handle );
3720 fprintf( stderr, ", access=%08x", req->access );
3721 fprintf( stderr, ", attributes=%08x", req->attributes );
3722 fprintf( stderr, ", flags=%08x", req->flags );
3725 static void dump_open_token_reply( const struct open_token_reply *req )
3727 fprintf( stderr, " token=%04x", req->token );
3730 static void dump_set_global_windows_request( const struct set_global_windows_request *req )
3732 fprintf( stderr, " flags=%08x", req->flags );
3733 fprintf( stderr, ", shell_window=%08x", req->shell_window );
3734 fprintf( stderr, ", shell_listview=%08x", req->shell_listview );
3735 fprintf( stderr, ", progman_window=%08x", req->progman_window );
3736 fprintf( stderr, ", taskman_window=%08x", req->taskman_window );
3739 static void dump_set_global_windows_reply( const struct set_global_windows_reply *req )
3741 fprintf( stderr, " old_shell_window=%08x", req->old_shell_window );
3742 fprintf( stderr, ", old_shell_listview=%08x", req->old_shell_listview );
3743 fprintf( stderr, ", old_progman_window=%08x", req->old_progman_window );
3744 fprintf( stderr, ", old_taskman_window=%08x", req->old_taskman_window );
3747 static void dump_adjust_token_privileges_request( const struct adjust_token_privileges_request *req )
3749 fprintf( stderr, " handle=%04x", req->handle );
3750 fprintf( stderr, ", disable_all=%d", req->disable_all );
3751 fprintf( stderr, ", get_modified_state=%d", req->get_modified_state );
3752 dump_varargs_LUID_AND_ATTRIBUTES( ", privileges=", cur_size );
3755 static void dump_adjust_token_privileges_reply( const struct adjust_token_privileges_reply *req )
3757 fprintf( stderr, " len=%08x", req->len );
3758 dump_varargs_LUID_AND_ATTRIBUTES( ", privileges=", cur_size );
3761 static void dump_get_token_privileges_request( const struct get_token_privileges_request *req )
3763 fprintf( stderr, " handle=%04x", req->handle );
3766 static void dump_get_token_privileges_reply( const struct get_token_privileges_reply *req )
3768 fprintf( stderr, " len=%08x", req->len );
3769 dump_varargs_LUID_AND_ATTRIBUTES( ", privileges=", cur_size );
3772 static void dump_check_token_privileges_request( const struct check_token_privileges_request *req )
3774 fprintf( stderr, " handle=%04x", req->handle );
3775 fprintf( stderr, ", all_required=%d", req->all_required );
3776 dump_varargs_LUID_AND_ATTRIBUTES( ", privileges=", cur_size );
3779 static void dump_check_token_privileges_reply( const struct check_token_privileges_reply *req )
3781 fprintf( stderr, " has_privileges=%d", req->has_privileges );
3782 dump_varargs_LUID_AND_ATTRIBUTES( ", privileges=", cur_size );
3785 static void dump_duplicate_token_request( const struct duplicate_token_request *req )
3787 fprintf( stderr, " handle=%04x", req->handle );
3788 fprintf( stderr, ", access=%08x", req->access );
3789 fprintf( stderr, ", attributes=%08x", req->attributes );
3790 fprintf( stderr, ", primary=%d", req->primary );
3791 fprintf( stderr, ", impersonation_level=%d", req->impersonation_level );
3794 static void dump_duplicate_token_reply( const struct duplicate_token_reply *req )
3796 fprintf( stderr, " new_handle=%04x", req->new_handle );
3799 static void dump_access_check_request( const struct access_check_request *req )
3801 fprintf( stderr, " handle=%04x", req->handle );
3802 fprintf( stderr, ", desired_access=%08x", req->desired_access );
3803 fprintf( stderr, ", mapping_read=%08x", req->mapping_read );
3804 fprintf( stderr, ", mapping_write=%08x", req->mapping_write );
3805 fprintf( stderr, ", mapping_execute=%08x", req->mapping_execute );
3806 fprintf( stderr, ", mapping_all=%08x", req->mapping_all );
3807 dump_varargs_security_descriptor( ", sd=", cur_size );
3810 static void dump_access_check_reply( const struct access_check_reply *req )
3812 fprintf( stderr, " access_granted=%08x", req->access_granted );
3813 fprintf( stderr, ", access_status=%08x", req->access_status );
3814 fprintf( stderr, ", privileges_len=%08x", req->privileges_len );
3815 dump_varargs_LUID_AND_ATTRIBUTES( ", privileges=", cur_size );
3818 static void dump_get_token_sid_request( const struct get_token_sid_request *req )
3820 fprintf( stderr, " handle=%04x", req->handle );
3821 fprintf( stderr, ", which_sid=%08x", req->which_sid );
3824 static void dump_get_token_sid_reply( const struct get_token_sid_reply *req )
3826 fprintf( stderr, " sid_len=%u", req->sid_len );
3827 dump_varargs_SID( ", sid=", cur_size );
3830 static void dump_get_token_groups_request( const struct get_token_groups_request *req )
3832 fprintf( stderr, " handle=%04x", req->handle );
3835 static void dump_get_token_groups_reply( const struct get_token_groups_reply *req )
3837 fprintf( stderr, " user_len=%u", req->user_len );
3838 dump_varargs_token_groups( ", user=", cur_size );
3841 static void dump_get_token_default_dacl_request( const struct get_token_default_dacl_request *req )
3843 fprintf( stderr, " handle=%04x", req->handle );
3846 static void dump_get_token_default_dacl_reply( const struct get_token_default_dacl_reply *req )
3848 fprintf( stderr, " acl_len=%u", req->acl_len );
3849 dump_varargs_ACL( ", acl=", cur_size );
3852 static void dump_set_token_default_dacl_request( const struct set_token_default_dacl_request *req )
3854 fprintf( stderr, " handle=%04x", req->handle );
3855 dump_varargs_ACL( ", acl=", cur_size );
3858 static void dump_set_security_object_request( const struct set_security_object_request *req )
3860 fprintf( stderr, " handle=%04x", req->handle );
3861 fprintf( stderr, ", security_info=%08x", req->security_info );
3862 dump_varargs_security_descriptor( ", sd=", cur_size );
3865 static void dump_get_security_object_request( const struct get_security_object_request *req )
3867 fprintf( stderr, " handle=%04x", req->handle );
3868 fprintf( stderr, ", security_info=%08x", req->security_info );
3871 static void dump_get_security_object_reply( const struct get_security_object_reply *req )
3873 fprintf( stderr, " sd_len=%08x", req->sd_len );
3874 dump_varargs_security_descriptor( ", sd=", cur_size );
3877 static void dump_get_system_handles_request( const struct get_system_handles_request *req )
3881 static void dump_get_system_handles_reply( const struct get_system_handles_reply *req )
3883 fprintf( stderr, " count=%08x", req->count );
3884 dump_varargs_handle_infos( ", data=", cur_size );
3887 static void dump_create_mailslot_request( const struct create_mailslot_request *req )
3889 fprintf( stderr, " access=%08x", req->access );
3890 dump_timeout( ", read_timeout=", &req->read_timeout );
3891 fprintf( stderr, ", max_msgsize=%08x", req->max_msgsize );
3892 dump_varargs_object_attributes( ", objattr=", cur_size );
3895 static void dump_create_mailslot_reply( const struct create_mailslot_reply *req )
3897 fprintf( stderr, " handle=%04x", req->handle );
3900 static void dump_set_mailslot_info_request( const struct set_mailslot_info_request *req )
3902 fprintf( stderr, " handle=%04x", req->handle );
3903 dump_timeout( ", read_timeout=", &req->read_timeout );
3904 fprintf( stderr, ", flags=%08x", req->flags );
3907 static void dump_set_mailslot_info_reply( const struct set_mailslot_info_reply *req )
3909 dump_timeout( " read_timeout=", &req->read_timeout );
3910 fprintf( stderr, ", max_msgsize=%08x", req->max_msgsize );
3913 static void dump_create_directory_request( const struct create_directory_request *req )
3915 fprintf( stderr, " access=%08x", req->access );
3916 dump_varargs_object_attributes( ", objattr=", cur_size );
3919 static void dump_create_directory_reply( const struct create_directory_reply *req )
3921 fprintf( stderr, " handle=%04x", req->handle );
3924 static void dump_open_directory_request( const struct open_directory_request *req )
3926 fprintf( stderr, " access=%08x", req->access );
3927 fprintf( stderr, ", attributes=%08x", req->attributes );
3928 fprintf( stderr, ", rootdir=%04x", req->rootdir );
3929 dump_varargs_unicode_str( ", directory_name=", cur_size );
3932 static void dump_open_directory_reply( const struct open_directory_reply *req )
3934 fprintf( stderr, " handle=%04x", req->handle );
3937 static void dump_get_directory_entry_request( const struct get_directory_entry_request *req )
3939 fprintf( stderr, " handle=%04x", req->handle );
3940 fprintf( stderr, ", index=%08x", req->index );
3943 static void dump_get_directory_entry_reply( const struct get_directory_entry_reply *req )
3945 fprintf( stderr, " name_len=%u", req->name_len );
3946 dump_varargs_unicode_str( ", name=", min(cur_size,req->name_len) );
3947 dump_varargs_unicode_str( ", type=", cur_size );
3950 static void dump_create_symlink_request( const struct create_symlink_request *req )
3952 fprintf( stderr, " access=%08x", req->access );
3953 dump_varargs_object_attributes( ", objattr=", cur_size );
3954 dump_varargs_unicode_str( ", target_name=", cur_size );
3957 static void dump_create_symlink_reply( const struct create_symlink_reply *req )
3959 fprintf( stderr, " handle=%04x", req->handle );
3962 static void dump_open_symlink_request( const struct open_symlink_request *req )
3964 fprintf( stderr, " access=%08x", req->access );
3965 fprintf( stderr, ", attributes=%08x", req->attributes );
3966 fprintf( stderr, ", rootdir=%04x", req->rootdir );
3967 dump_varargs_unicode_str( ", name=", cur_size );
3970 static void dump_open_symlink_reply( const struct open_symlink_reply *req )
3972 fprintf( stderr, " handle=%04x", req->handle );
3975 static void dump_query_symlink_request( const struct query_symlink_request *req )
3977 fprintf( stderr, " handle=%04x", req->handle );
3980 static void dump_query_symlink_reply( const struct query_symlink_reply *req )
3982 fprintf( stderr, " total=%u", req->total );
3983 dump_varargs_unicode_str( ", target_name=", cur_size );
3986 static void dump_get_object_info_request( const struct get_object_info_request *req )
3988 fprintf( stderr, " handle=%04x", req->handle );
3991 static void dump_get_object_info_reply( const struct get_object_info_reply *req )
3993 fprintf( stderr, " access=%08x", req->access );
3994 fprintf( stderr, ", ref_count=%08x", req->ref_count );
3995 fprintf( stderr, ", handle_count=%08x", req->handle_count );
3996 fprintf( stderr, ", total=%u", req->total );
3997 dump_varargs_unicode_str( ", name=", cur_size );
4000 static void dump_get_object_type_request( const struct get_object_type_request *req )
4002 fprintf( stderr, " handle=%04x", req->handle );
4005 static void dump_get_object_type_reply( const struct get_object_type_reply *req )
4007 fprintf( stderr, " total=%u", req->total );
4008 dump_varargs_unicode_str( ", type=", cur_size );
4011 static void dump_unlink_object_request( const struct unlink_object_request *req )
4013 fprintf( stderr, " handle=%04x", req->handle );
4016 static void dump_get_token_impersonation_level_request( const struct get_token_impersonation_level_request *req )
4018 fprintf( stderr, " handle=%04x", req->handle );
4021 static void dump_get_token_impersonation_level_reply( const struct get_token_impersonation_level_reply *req )
4023 fprintf( stderr, " impersonation_level=%d", req->impersonation_level );
4026 static void dump_allocate_locally_unique_id_request( const struct allocate_locally_unique_id_request *req )
4030 static void dump_allocate_locally_unique_id_reply( const struct allocate_locally_unique_id_reply *req )
4032 dump_luid( " luid=", &req->luid );
4035 static void dump_create_device_manager_request( const struct create_device_manager_request *req )
4037 fprintf( stderr, " access=%08x", req->access );
4038 fprintf( stderr, ", attributes=%08x", req->attributes );
4041 static void dump_create_device_manager_reply( const struct create_device_manager_reply *req )
4043 fprintf( stderr, " handle=%04x", req->handle );
4046 static void dump_create_device_request( const struct create_device_request *req )
4048 fprintf( stderr, " access=%08x", req->access );
4049 fprintf( stderr, ", attributes=%08x", req->attributes );
4050 fprintf( stderr, ", rootdir=%04x", req->rootdir );
4051 dump_uint64( ", user_ptr=", &req->user_ptr );
4052 fprintf( stderr, ", manager=%04x", req->manager );
4053 dump_varargs_unicode_str( ", name=", cur_size );
4056 static void dump_create_device_reply( const struct create_device_reply *req )
4058 fprintf( stderr, " handle=%04x", req->handle );
4061 static void dump_delete_device_request( const struct delete_device_request *req )
4063 fprintf( stderr, " handle=%04x", req->handle );
4066 static void dump_get_next_device_request_request( const struct get_next_device_request_request *req )
4068 fprintf( stderr, " manager=%04x", req->manager );
4069 fprintf( stderr, ", prev=%04x", req->prev );
4070 fprintf( stderr, ", status=%08x", req->status );
4073 static void dump_get_next_device_request_reply( const struct get_next_device_request_reply *req )
4075 dump_irp_params( " params=", &req->params );
4076 fprintf( stderr, ", next=%04x", req->next );
4077 fprintf( stderr, ", client_pid=%04x", req->client_pid );
4078 fprintf( stderr, ", client_tid=%04x", req->client_tid );
4079 fprintf( stderr, ", in_size=%u", req->in_size );
4080 fprintf( stderr, ", out_size=%u", req->out_size );
4081 dump_varargs_bytes( ", next_data=", cur_size );
4084 static void dump_make_process_system_request( const struct make_process_system_request *req )
4088 static void dump_make_process_system_reply( const struct make_process_system_reply *req )
4090 fprintf( stderr, " event=%04x", req->event );
4093 static void dump_get_token_statistics_request( const struct get_token_statistics_request *req )
4095 fprintf( stderr, " handle=%04x", req->handle );
4098 static void dump_get_token_statistics_reply( const struct get_token_statistics_reply *req )
4100 dump_luid( " token_id=", &req->token_id );
4101 dump_luid( ", modified_id=", &req->modified_id );
4102 fprintf( stderr, ", primary=%d", req->primary );
4103 fprintf( stderr, ", impersonation_level=%d", req->impersonation_level );
4104 fprintf( stderr, ", group_count=%d", req->group_count );
4105 fprintf( stderr, ", privilege_count=%d", req->privilege_count );
4108 static void dump_create_completion_request( const struct create_completion_request *req )
4110 fprintf( stderr, " access=%08x", req->access );
4111 fprintf( stderr, ", concurrent=%08x", req->concurrent );
4112 dump_varargs_object_attributes( ", objattr=", cur_size );
4115 static void dump_create_completion_reply( const struct create_completion_reply *req )
4117 fprintf( stderr, " handle=%04x", req->handle );
4120 static void dump_open_completion_request( const struct open_completion_request *req )
4122 fprintf( stderr, " access=%08x", req->access );
4123 fprintf( stderr, ", attributes=%08x", req->attributes );
4124 fprintf( stderr, ", rootdir=%04x", req->rootdir );
4125 dump_varargs_unicode_str( ", filename=", cur_size );
4128 static void dump_open_completion_reply( const struct open_completion_reply *req )
4130 fprintf( stderr, " handle=%04x", req->handle );
4133 static void dump_add_completion_request( const struct add_completion_request *req )
4135 fprintf( stderr, " handle=%04x", req->handle );
4136 dump_uint64( ", ckey=", &req->ckey );
4137 dump_uint64( ", cvalue=", &req->cvalue );
4138 dump_uint64( ", information=", &req->information );
4139 fprintf( stderr, ", status=%08x", req->status );
4142 static void dump_remove_completion_request( const struct remove_completion_request *req )
4144 fprintf( stderr, " handle=%04x", req->handle );
4147 static void dump_remove_completion_reply( const struct remove_completion_reply *req )
4149 dump_uint64( " ckey=", &req->ckey );
4150 dump_uint64( ", cvalue=", &req->cvalue );
4151 dump_uint64( ", information=", &req->information );
4152 fprintf( stderr, ", status=%08x", req->status );
4155 static void dump_query_completion_request( const struct query_completion_request *req )
4157 fprintf( stderr, " handle=%04x", req->handle );
4160 static void dump_query_completion_reply( const struct query_completion_reply *req )
4162 fprintf( stderr, " depth=%08x", req->depth );
4165 static void dump_set_completion_info_request( const struct set_completion_info_request *req )
4167 fprintf( stderr, " handle=%04x", req->handle );
4168 dump_uint64( ", ckey=", &req->ckey );
4169 fprintf( stderr, ", chandle=%04x", req->chandle );
4172 static void dump_add_fd_completion_request( const struct add_fd_completion_request *req )
4174 fprintf( stderr, " handle=%04x", req->handle );
4175 dump_uint64( ", cvalue=", &req->cvalue );
4176 dump_uint64( ", information=", &req->information );
4177 fprintf( stderr, ", status=%08x", req->status );
4180 static void dump_set_fd_disp_info_request( const struct set_fd_disp_info_request *req )
4182 fprintf( stderr, " handle=%04x", req->handle );
4183 fprintf( stderr, ", unlink=%d", req->unlink );
4186 static void dump_set_fd_name_info_request( const struct set_fd_name_info_request *req )
4188 fprintf( stderr, " handle=%04x", req->handle );
4189 fprintf( stderr, ", rootdir=%04x", req->rootdir );
4190 fprintf( stderr, ", link=%d", req->link );
4191 dump_varargs_string( ", filename=", cur_size );
4194 static void dump_get_window_layered_info_request( const struct get_window_layered_info_request *req )
4196 fprintf( stderr, " handle=%08x", req->handle );
4199 static void dump_get_window_layered_info_reply( const struct get_window_layered_info_reply *req )
4201 fprintf( stderr, " color_key=%08x", req->color_key );
4202 fprintf( stderr, ", alpha=%08x", req->alpha );
4203 fprintf( stderr, ", flags=%08x", req->flags );
4206 static void dump_set_window_layered_info_request( const struct set_window_layered_info_request *req )
4208 fprintf( stderr, " handle=%08x", req->handle );
4209 fprintf( stderr, ", color_key=%08x", req->color_key );
4210 fprintf( stderr, ", alpha=%08x", req->alpha );
4211 fprintf( stderr, ", flags=%08x", req->flags );
4214 static void dump_alloc_user_handle_request( const struct alloc_user_handle_request *req )
4218 static void dump_alloc_user_handle_reply( const struct alloc_user_handle_reply *req )
4220 fprintf( stderr, " handle=%08x", req->handle );
4223 static void dump_free_user_handle_request( const struct free_user_handle_request *req )
4225 fprintf( stderr, " handle=%08x", req->handle );
4228 static void dump_set_cursor_request( const struct set_cursor_request *req )
4230 fprintf( stderr, " flags=%08x", req->flags );
4231 fprintf( stderr, ", handle=%08x", req->handle );
4232 fprintf( stderr, ", show_count=%d", req->show_count );
4233 fprintf( stderr, ", x=%d", req->x );
4234 fprintf( stderr, ", y=%d", req->y );
4235 dump_rectangle( ", clip=", &req->clip );
4236 fprintf( stderr, ", clip_msg=%08x", req->clip_msg );
4239 static void dump_set_cursor_reply( const struct set_cursor_reply *req )
4241 fprintf( stderr, " prev_handle=%08x", req->prev_handle );
4242 fprintf( stderr, ", prev_count=%d", req->prev_count );
4243 fprintf( stderr, ", prev_x=%d", req->prev_x );
4244 fprintf( stderr, ", prev_y=%d", req->prev_y );
4245 fprintf( stderr, ", new_x=%d", req->new_x );
4246 fprintf( stderr, ", new_y=%d", req->new_y );
4247 dump_rectangle( ", new_clip=", &req->new_clip );
4248 fprintf( stderr, ", last_change=%08x", req->last_change );
4251 static void dump_update_rawinput_devices_request( const struct update_rawinput_devices_request *req )
4253 dump_varargs_rawinput_devices( " devices=", cur_size );
4256 static void dump_get_suspend_context_request( const struct get_suspend_context_request *req )
4260 static void dump_get_suspend_context_reply( const struct get_suspend_context_reply *req )
4262 dump_varargs_context( " context=", cur_size );
4265 static void dump_set_suspend_context_request( const struct set_suspend_context_request *req )
4267 dump_varargs_context( " context=", cur_size );
4270 static void dump_create_job_request( const struct create_job_request *req )
4272 fprintf( stderr, " access=%08x", req->access );
4273 dump_varargs_object_attributes( ", objattr=", cur_size );
4276 static void dump_create_job_reply( const struct create_job_reply *req )
4278 fprintf( stderr, " handle=%04x", req->handle );
4281 static void dump_open_job_request( const struct open_job_request *req )
4283 fprintf( stderr, " access=%08x", req->access );
4284 fprintf( stderr, ", attributes=%08x", req->attributes );
4285 fprintf( stderr, ", rootdir=%04x", req->rootdir );
4286 dump_varargs_unicode_str( ", name=", cur_size );
4289 static void dump_open_job_reply( const struct open_job_reply *req )
4291 fprintf( stderr, " handle=%04x", req->handle );
4294 static void dump_assign_job_request( const struct assign_job_request *req )
4296 fprintf( stderr, " job=%04x", req->job );
4297 fprintf( stderr, ", process=%04x", req->process );
4300 static void dump_process_in_job_request( const struct process_in_job_request *req )
4302 fprintf( stderr, " job=%04x", req->job );
4303 fprintf( stderr, ", process=%04x", req->process );
4306 static void dump_set_job_limits_request( const struct set_job_limits_request *req )
4308 fprintf( stderr, " handle=%04x", req->handle );
4309 fprintf( stderr, ", limit_flags=%08x", req->limit_flags );
4312 static void dump_set_job_completion_port_request( const struct set_job_completion_port_request *req )
4314 fprintf( stderr, " job=%04x", req->job );
4315 fprintf( stderr, ", port=%04x", req->port );
4316 dump_uint64( ", key=", &req->key );
4319 static void dump_terminate_job_request( const struct terminate_job_request *req )
4321 fprintf( stderr, " handle=%04x", req->handle );
4322 fprintf( stderr, ", status=%d", req->status );
4325 static const dump_func req_dumpers[REQ_NB_REQUESTS] = {
4326 (dump_func)dump_new_process_request,
4327 (dump_func)dump_get_new_process_info_request,
4328 (dump_func)dump_new_thread_request,
4329 (dump_func)dump_get_startup_info_request,
4330 (dump_func)dump_init_process_done_request,
4331 (dump_func)dump_init_thread_request,
4332 (dump_func)dump_terminate_process_request,
4333 (dump_func)dump_terminate_thread_request,
4334 (dump_func)dump_get_process_info_request,
4335 (dump_func)dump_set_process_info_request,
4336 (dump_func)dump_get_thread_info_request,
4337 (dump_func)dump_get_thread_times_request,
4338 (dump_func)dump_set_thread_info_request,
4339 (dump_func)dump_get_dll_info_request,
4340 (dump_func)dump_suspend_thread_request,
4341 (dump_func)dump_resume_thread_request,
4342 (dump_func)dump_load_dll_request,
4343 (dump_func)dump_unload_dll_request,
4344 (dump_func)dump_queue_apc_request,
4345 (dump_func)dump_get_apc_result_request,
4346 (dump_func)dump_close_handle_request,
4347 (dump_func)dump_set_handle_info_request,
4348 (dump_func)dump_dup_handle_request,
4349 (dump_func)dump_open_process_request,
4350 (dump_func)dump_open_thread_request,
4351 (dump_func)dump_select_request,
4352 (dump_func)dump_create_event_request,
4353 (dump_func)dump_event_op_request,
4354 (dump_func)dump_query_event_request,
4355 (dump_func)dump_open_event_request,
4356 (dump_func)dump_create_keyed_event_request,
4357 (dump_func)dump_open_keyed_event_request,
4358 (dump_func)dump_create_mutex_request,
4359 (dump_func)dump_release_mutex_request,
4360 (dump_func)dump_open_mutex_request,
4361 (dump_func)dump_query_mutex_request,
4362 (dump_func)dump_create_semaphore_request,
4363 (dump_func)dump_release_semaphore_request,
4364 (dump_func)dump_query_semaphore_request,
4365 (dump_func)dump_open_semaphore_request,
4366 (dump_func)dump_create_file_request,
4367 (dump_func)dump_open_file_object_request,
4368 (dump_func)dump_alloc_file_handle_request,
4369 (dump_func)dump_get_handle_unix_name_request,
4370 (dump_func)dump_get_handle_fd_request,
4371 (dump_func)dump_get_directory_cache_entry_request,
4372 (dump_func)dump_flush_request,
4373 (dump_func)dump_lock_file_request,
4374 (dump_func)dump_unlock_file_request,
4375 (dump_func)dump_create_socket_request,
4376 (dump_func)dump_accept_socket_request,
4377 (dump_func)dump_accept_into_socket_request,
4378 (dump_func)dump_set_socket_event_request,
4379 (dump_func)dump_get_socket_event_request,
4380 (dump_func)dump_get_socket_info_request,
4381 (dump_func)dump_enable_socket_event_request,
4382 (dump_func)dump_set_socket_deferred_request,
4383 (dump_func)dump_alloc_console_request,
4384 (dump_func)dump_free_console_request,
4385 (dump_func)dump_get_console_renderer_events_request,
4386 (dump_func)dump_open_console_request,
4387 (dump_func)dump_get_console_wait_event_request,
4388 (dump_func)dump_get_console_mode_request,
4389 (dump_func)dump_set_console_mode_request,
4390 (dump_func)dump_set_console_input_info_request,
4391 (dump_func)dump_get_console_input_info_request,
4392 (dump_func)dump_append_console_input_history_request,
4393 (dump_func)dump_get_console_input_history_request,
4394 (dump_func)dump_create_console_output_request,
4395 (dump_func)dump_set_console_output_info_request,
4396 (dump_func)dump_get_console_output_info_request,
4397 (dump_func)dump_write_console_input_request,
4398 (dump_func)dump_read_console_input_request,
4399 (dump_func)dump_write_console_output_request,
4400 (dump_func)dump_fill_console_output_request,
4401 (dump_func)dump_read_console_output_request,
4402 (dump_func)dump_move_console_output_request,
4403 (dump_func)dump_send_console_signal_request,
4404 (dump_func)dump_read_directory_changes_request,
4405 (dump_func)dump_read_change_request,
4406 (dump_func)dump_create_mapping_request,
4407 (dump_func)dump_open_mapping_request,
4408 (dump_func)dump_get_mapping_info_request,
4409 (dump_func)dump_get_mapping_committed_range_request,
4410 (dump_func)dump_add_mapping_committed_range_request,
4411 (dump_func)dump_create_snapshot_request,
4412 (dump_func)dump_next_process_request,
4413 (dump_func)dump_next_thread_request,
4414 (dump_func)dump_wait_debug_event_request,
4415 (dump_func)dump_queue_exception_event_request,
4416 (dump_func)dump_get_exception_status_request,
4417 (dump_func)dump_continue_debug_event_request,
4418 (dump_func)dump_debug_process_request,
4419 (dump_func)dump_debug_break_request,
4420 (dump_func)dump_set_debugger_kill_on_exit_request,
4421 (dump_func)dump_read_process_memory_request,
4422 (dump_func)dump_write_process_memory_request,
4423 (dump_func)dump_create_key_request,
4424 (dump_func)dump_open_key_request,
4425 (dump_func)dump_delete_key_request,
4426 (dump_func)dump_flush_key_request,
4427 (dump_func)dump_enum_key_request,
4428 (dump_func)dump_set_key_value_request,
4429 (dump_func)dump_get_key_value_request,
4430 (dump_func)dump_enum_key_value_request,
4431 (dump_func)dump_delete_key_value_request,
4432 (dump_func)dump_load_registry_request,
4433 (dump_func)dump_unload_registry_request,
4434 (dump_func)dump_save_registry_request,
4435 (dump_func)dump_set_registry_notification_request,
4436 (dump_func)dump_create_timer_request,
4437 (dump_func)dump_open_timer_request,
4438 (dump_func)dump_set_timer_request,
4439 (dump_func)dump_cancel_timer_request,
4440 (dump_func)dump_get_timer_info_request,
4441 (dump_func)dump_get_thread_context_request,
4442 (dump_func)dump_set_thread_context_request,
4443 (dump_func)dump_get_selector_entry_request,
4444 (dump_func)dump_add_atom_request,
4445 (dump_func)dump_delete_atom_request,
4446 (dump_func)dump_find_atom_request,
4447 (dump_func)dump_get_atom_information_request,
4448 (dump_func)dump_set_atom_information_request,
4449 (dump_func)dump_empty_atom_table_request,
4450 (dump_func)dump_init_atom_table_request,
4451 (dump_func)dump_get_msg_queue_request,
4452 (dump_func)dump_set_queue_fd_request,
4453 (dump_func)dump_set_queue_mask_request,
4454 (dump_func)dump_get_queue_status_request,
4455 (dump_func)dump_get_process_idle_event_request,
4456 (dump_func)dump_send_message_request,
4457 (dump_func)dump_post_quit_message_request,
4458 (dump_func)dump_send_hardware_message_request,
4459 (dump_func)dump_get_message_request,
4460 (dump_func)dump_reply_message_request,
4461 (dump_func)dump_accept_hardware_message_request,
4462 (dump_func)dump_get_message_reply_request,
4463 (dump_func)dump_set_win_timer_request,
4464 (dump_func)dump_kill_win_timer_request,
4465 (dump_func)dump_is_window_hung_request,
4466 (dump_func)dump_get_serial_info_request,
4467 (dump_func)dump_set_serial_info_request,
4468 (dump_func)dump_register_async_request,
4469 (dump_func)dump_cancel_async_request,
4470 (dump_func)dump_read_request,
4471 (dump_func)dump_write_request,
4472 (dump_func)dump_ioctl_request,
4473 (dump_func)dump_set_irp_result_request,
4474 (dump_func)dump_get_irp_result_request,
4475 (dump_func)dump_create_named_pipe_request,
4476 (dump_func)dump_get_named_pipe_info_request,
4477 (dump_func)dump_set_named_pipe_info_request,
4478 (dump_func)dump_create_window_request,
4479 (dump_func)dump_destroy_window_request,
4480 (dump_func)dump_get_desktop_window_request,
4481 (dump_func)dump_set_window_owner_request,
4482 (dump_func)dump_get_window_info_request,
4483 (dump_func)dump_set_window_info_request,
4484 (dump_func)dump_set_parent_request,
4485 (dump_func)dump_get_window_parents_request,
4486 (dump_func)dump_get_window_children_request,
4487 (dump_func)dump_get_window_children_from_point_request,
4488 (dump_func)dump_get_window_tree_request,
4489 (dump_func)dump_set_window_pos_request,
4490 (dump_func)dump_get_window_rectangles_request,
4491 (dump_func)dump_get_window_text_request,
4492 (dump_func)dump_set_window_text_request,
4493 (dump_func)dump_get_windows_offset_request,
4494 (dump_func)dump_get_visible_region_request,
4495 (dump_func)dump_get_surface_region_request,
4496 (dump_func)dump_get_window_region_request,
4497 (dump_func)dump_set_window_region_request,
4498 (dump_func)dump_get_update_region_request,
4499 (dump_func)dump_update_window_zorder_request,
4500 (dump_func)dump_redraw_window_request,
4501 (dump_func)dump_set_window_property_request,
4502 (dump_func)dump_remove_window_property_request,
4503 (dump_func)dump_get_window_property_request,
4504 (dump_func)dump_get_window_properties_request,
4505 (dump_func)dump_create_winstation_request,
4506 (dump_func)dump_open_winstation_request,
4507 (dump_func)dump_close_winstation_request,
4508 (dump_func)dump_get_process_winstation_request,
4509 (dump_func)dump_set_process_winstation_request,
4510 (dump_func)dump_enum_winstation_request,
4511 (dump_func)dump_create_desktop_request,
4512 (dump_func)dump_open_desktop_request,
4513 (dump_func)dump_open_input_desktop_request,
4514 (dump_func)dump_close_desktop_request,
4515 (dump_func)dump_get_thread_desktop_request,
4516 (dump_func)dump_set_thread_desktop_request,
4517 (dump_func)dump_enum_desktop_request,
4518 (dump_func)dump_set_user_object_info_request,
4519 (dump_func)dump_register_hotkey_request,
4520 (dump_func)dump_unregister_hotkey_request,
4521 (dump_func)dump_attach_thread_input_request,
4522 (dump_func)dump_get_thread_input_request,
4523 (dump_func)dump_get_last_input_time_request,
4524 (dump_func)dump_get_key_state_request,
4525 (dump_func)dump_set_key_state_request,
4526 (dump_func)dump_set_foreground_window_request,
4527 (dump_func)dump_set_focus_window_request,
4528 (dump_func)dump_set_active_window_request,
4529 (dump_func)dump_set_capture_window_request,
4530 (dump_func)dump_set_caret_window_request,
4531 (dump_func)dump_set_caret_info_request,
4532 (dump_func)dump_set_hook_request,
4533 (dump_func)dump_remove_hook_request,
4534 (dump_func)dump_start_hook_chain_request,
4535 (dump_func)dump_finish_hook_chain_request,
4536 (dump_func)dump_get_hook_info_request,
4537 (dump_func)dump_create_class_request,
4538 (dump_func)dump_destroy_class_request,
4539 (dump_func)dump_set_class_info_request,
4540 (dump_func)dump_set_clipboard_info_request,
4541 (dump_func)dump_empty_clipboard_request,
4542 (dump_func)dump_open_token_request,
4543 (dump_func)dump_set_global_windows_request,
4544 (dump_func)dump_adjust_token_privileges_request,
4545 (dump_func)dump_get_token_privileges_request,
4546 (dump_func)dump_check_token_privileges_request,
4547 (dump_func)dump_duplicate_token_request,
4548 (dump_func)dump_access_check_request,
4549 (dump_func)dump_get_token_sid_request,
4550 (dump_func)dump_get_token_groups_request,
4551 (dump_func)dump_get_token_default_dacl_request,
4552 (dump_func)dump_set_token_default_dacl_request,
4553 (dump_func)dump_set_security_object_request,
4554 (dump_func)dump_get_security_object_request,
4555 (dump_func)dump_get_system_handles_request,
4556 (dump_func)dump_create_mailslot_request,
4557 (dump_func)dump_set_mailslot_info_request,
4558 (dump_func)dump_create_directory_request,
4559 (dump_func)dump_open_directory_request,
4560 (dump_func)dump_get_directory_entry_request,
4561 (dump_func)dump_create_symlink_request,
4562 (dump_func)dump_open_symlink_request,
4563 (dump_func)dump_query_symlink_request,
4564 (dump_func)dump_get_object_info_request,
4565 (dump_func)dump_get_object_type_request,
4566 (dump_func)dump_unlink_object_request,
4567 (dump_func)dump_get_token_impersonation_level_request,
4568 (dump_func)dump_allocate_locally_unique_id_request,
4569 (dump_func)dump_create_device_manager_request,
4570 (dump_func)dump_create_device_request,
4571 (dump_func)dump_delete_device_request,
4572 (dump_func)dump_get_next_device_request_request,
4573 (dump_func)dump_make_process_system_request,
4574 (dump_func)dump_get_token_statistics_request,
4575 (dump_func)dump_create_completion_request,
4576 (dump_func)dump_open_completion_request,
4577 (dump_func)dump_add_completion_request,
4578 (dump_func)dump_remove_completion_request,
4579 (dump_func)dump_query_completion_request,
4580 (dump_func)dump_set_completion_info_request,
4581 (dump_func)dump_add_fd_completion_request,
4582 (dump_func)dump_set_fd_disp_info_request,
4583 (dump_func)dump_set_fd_name_info_request,
4584 (dump_func)dump_get_window_layered_info_request,
4585 (dump_func)dump_set_window_layered_info_request,
4586 (dump_func)dump_alloc_user_handle_request,
4587 (dump_func)dump_free_user_handle_request,
4588 (dump_func)dump_set_cursor_request,
4589 (dump_func)dump_update_rawinput_devices_request,
4590 (dump_func)dump_get_suspend_context_request,
4591 (dump_func)dump_set_suspend_context_request,
4592 (dump_func)dump_create_job_request,
4593 (dump_func)dump_open_job_request,
4594 (dump_func)dump_assign_job_request,
4595 (dump_func)dump_process_in_job_request,
4596 (dump_func)dump_set_job_limits_request,
4597 (dump_func)dump_set_job_completion_port_request,
4598 (dump_func)dump_terminate_job_request,
4601 static const dump_func reply_dumpers[REQ_NB_REQUESTS] = {
4602 (dump_func)dump_new_process_reply,
4603 (dump_func)dump_get_new_process_info_reply,
4604 (dump_func)dump_new_thread_reply,
4605 (dump_func)dump_get_startup_info_reply,
4606 NULL,
4607 (dump_func)dump_init_thread_reply,
4608 (dump_func)dump_terminate_process_reply,
4609 (dump_func)dump_terminate_thread_reply,
4610 (dump_func)dump_get_process_info_reply,
4611 NULL,
4612 (dump_func)dump_get_thread_info_reply,
4613 (dump_func)dump_get_thread_times_reply,
4614 NULL,
4615 (dump_func)dump_get_dll_info_reply,
4616 (dump_func)dump_suspend_thread_reply,
4617 (dump_func)dump_resume_thread_reply,
4618 NULL,
4619 NULL,
4620 (dump_func)dump_queue_apc_reply,
4621 (dump_func)dump_get_apc_result_reply,
4622 NULL,
4623 (dump_func)dump_set_handle_info_reply,
4624 (dump_func)dump_dup_handle_reply,
4625 (dump_func)dump_open_process_reply,
4626 (dump_func)dump_open_thread_reply,
4627 (dump_func)dump_select_reply,
4628 (dump_func)dump_create_event_reply,
4629 NULL,
4630 (dump_func)dump_query_event_reply,
4631 (dump_func)dump_open_event_reply,
4632 (dump_func)dump_create_keyed_event_reply,
4633 (dump_func)dump_open_keyed_event_reply,
4634 (dump_func)dump_create_mutex_reply,
4635 (dump_func)dump_release_mutex_reply,
4636 (dump_func)dump_open_mutex_reply,
4637 (dump_func)dump_query_mutex_reply,
4638 (dump_func)dump_create_semaphore_reply,
4639 (dump_func)dump_release_semaphore_reply,
4640 (dump_func)dump_query_semaphore_reply,
4641 (dump_func)dump_open_semaphore_reply,
4642 (dump_func)dump_create_file_reply,
4643 (dump_func)dump_open_file_object_reply,
4644 (dump_func)dump_alloc_file_handle_reply,
4645 (dump_func)dump_get_handle_unix_name_reply,
4646 (dump_func)dump_get_handle_fd_reply,
4647 (dump_func)dump_get_directory_cache_entry_reply,
4648 (dump_func)dump_flush_reply,
4649 (dump_func)dump_lock_file_reply,
4650 NULL,
4651 (dump_func)dump_create_socket_reply,
4652 (dump_func)dump_accept_socket_reply,
4653 NULL,
4654 NULL,
4655 (dump_func)dump_get_socket_event_reply,
4656 (dump_func)dump_get_socket_info_reply,
4657 NULL,
4658 NULL,
4659 (dump_func)dump_alloc_console_reply,
4660 NULL,
4661 (dump_func)dump_get_console_renderer_events_reply,
4662 (dump_func)dump_open_console_reply,
4663 (dump_func)dump_get_console_wait_event_reply,
4664 (dump_func)dump_get_console_mode_reply,
4665 NULL,
4666 NULL,
4667 (dump_func)dump_get_console_input_info_reply,
4668 NULL,
4669 (dump_func)dump_get_console_input_history_reply,
4670 (dump_func)dump_create_console_output_reply,
4671 NULL,
4672 (dump_func)dump_get_console_output_info_reply,
4673 (dump_func)dump_write_console_input_reply,
4674 (dump_func)dump_read_console_input_reply,
4675 (dump_func)dump_write_console_output_reply,
4676 (dump_func)dump_fill_console_output_reply,
4677 (dump_func)dump_read_console_output_reply,
4678 NULL,
4679 NULL,
4680 NULL,
4681 (dump_func)dump_read_change_reply,
4682 (dump_func)dump_create_mapping_reply,
4683 (dump_func)dump_open_mapping_reply,
4684 (dump_func)dump_get_mapping_info_reply,
4685 (dump_func)dump_get_mapping_committed_range_reply,
4686 NULL,
4687 (dump_func)dump_create_snapshot_reply,
4688 (dump_func)dump_next_process_reply,
4689 (dump_func)dump_next_thread_reply,
4690 (dump_func)dump_wait_debug_event_reply,
4691 (dump_func)dump_queue_exception_event_reply,
4692 (dump_func)dump_get_exception_status_reply,
4693 NULL,
4694 NULL,
4695 (dump_func)dump_debug_break_reply,
4696 NULL,
4697 (dump_func)dump_read_process_memory_reply,
4698 NULL,
4699 (dump_func)dump_create_key_reply,
4700 (dump_func)dump_open_key_reply,
4701 NULL,
4702 NULL,
4703 (dump_func)dump_enum_key_reply,
4704 NULL,
4705 (dump_func)dump_get_key_value_reply,
4706 (dump_func)dump_enum_key_value_reply,
4707 NULL,
4708 NULL,
4709 NULL,
4710 NULL,
4711 NULL,
4712 (dump_func)dump_create_timer_reply,
4713 (dump_func)dump_open_timer_reply,
4714 (dump_func)dump_set_timer_reply,
4715 (dump_func)dump_cancel_timer_reply,
4716 (dump_func)dump_get_timer_info_reply,
4717 (dump_func)dump_get_thread_context_reply,
4718 (dump_func)dump_set_thread_context_reply,
4719 (dump_func)dump_get_selector_entry_reply,
4720 (dump_func)dump_add_atom_reply,
4721 NULL,
4722 (dump_func)dump_find_atom_reply,
4723 (dump_func)dump_get_atom_information_reply,
4724 NULL,
4725 NULL,
4726 (dump_func)dump_init_atom_table_reply,
4727 (dump_func)dump_get_msg_queue_reply,
4728 NULL,
4729 (dump_func)dump_set_queue_mask_reply,
4730 (dump_func)dump_get_queue_status_reply,
4731 (dump_func)dump_get_process_idle_event_reply,
4732 NULL,
4733 NULL,
4734 (dump_func)dump_send_hardware_message_reply,
4735 (dump_func)dump_get_message_reply,
4736 NULL,
4737 NULL,
4738 (dump_func)dump_get_message_reply_reply,
4739 (dump_func)dump_set_win_timer_reply,
4740 NULL,
4741 (dump_func)dump_is_window_hung_reply,
4742 (dump_func)dump_get_serial_info_reply,
4743 NULL,
4744 NULL,
4745 NULL,
4746 (dump_func)dump_read_reply,
4747 (dump_func)dump_write_reply,
4748 (dump_func)dump_ioctl_reply,
4749 NULL,
4750 (dump_func)dump_get_irp_result_reply,
4751 (dump_func)dump_create_named_pipe_reply,
4752 (dump_func)dump_get_named_pipe_info_reply,
4753 NULL,
4754 (dump_func)dump_create_window_reply,
4755 NULL,
4756 (dump_func)dump_get_desktop_window_reply,
4757 (dump_func)dump_set_window_owner_reply,
4758 (dump_func)dump_get_window_info_reply,
4759 (dump_func)dump_set_window_info_reply,
4760 (dump_func)dump_set_parent_reply,
4761 (dump_func)dump_get_window_parents_reply,
4762 (dump_func)dump_get_window_children_reply,
4763 (dump_func)dump_get_window_children_from_point_reply,
4764 (dump_func)dump_get_window_tree_reply,
4765 (dump_func)dump_set_window_pos_reply,
4766 (dump_func)dump_get_window_rectangles_reply,
4767 (dump_func)dump_get_window_text_reply,
4768 NULL,
4769 (dump_func)dump_get_windows_offset_reply,
4770 (dump_func)dump_get_visible_region_reply,
4771 (dump_func)dump_get_surface_region_reply,
4772 (dump_func)dump_get_window_region_reply,
4773 NULL,
4774 (dump_func)dump_get_update_region_reply,
4775 NULL,
4776 NULL,
4777 NULL,
4778 (dump_func)dump_remove_window_property_reply,
4779 (dump_func)dump_get_window_property_reply,
4780 (dump_func)dump_get_window_properties_reply,
4781 (dump_func)dump_create_winstation_reply,
4782 (dump_func)dump_open_winstation_reply,
4783 NULL,
4784 (dump_func)dump_get_process_winstation_reply,
4785 NULL,
4786 (dump_func)dump_enum_winstation_reply,
4787 (dump_func)dump_create_desktop_reply,
4788 (dump_func)dump_open_desktop_reply,
4789 (dump_func)dump_open_input_desktop_reply,
4790 NULL,
4791 (dump_func)dump_get_thread_desktop_reply,
4792 NULL,
4793 (dump_func)dump_enum_desktop_reply,
4794 (dump_func)dump_set_user_object_info_reply,
4795 (dump_func)dump_register_hotkey_reply,
4796 (dump_func)dump_unregister_hotkey_reply,
4797 NULL,
4798 (dump_func)dump_get_thread_input_reply,
4799 (dump_func)dump_get_last_input_time_reply,
4800 (dump_func)dump_get_key_state_reply,
4801 NULL,
4802 (dump_func)dump_set_foreground_window_reply,
4803 (dump_func)dump_set_focus_window_reply,
4804 (dump_func)dump_set_active_window_reply,
4805 (dump_func)dump_set_capture_window_reply,
4806 (dump_func)dump_set_caret_window_reply,
4807 (dump_func)dump_set_caret_info_reply,
4808 (dump_func)dump_set_hook_reply,
4809 (dump_func)dump_remove_hook_reply,
4810 (dump_func)dump_start_hook_chain_reply,
4811 NULL,
4812 (dump_func)dump_get_hook_info_reply,
4813 (dump_func)dump_create_class_reply,
4814 (dump_func)dump_destroy_class_reply,
4815 (dump_func)dump_set_class_info_reply,
4816 (dump_func)dump_set_clipboard_info_reply,
4817 NULL,
4818 (dump_func)dump_open_token_reply,
4819 (dump_func)dump_set_global_windows_reply,
4820 (dump_func)dump_adjust_token_privileges_reply,
4821 (dump_func)dump_get_token_privileges_reply,
4822 (dump_func)dump_check_token_privileges_reply,
4823 (dump_func)dump_duplicate_token_reply,
4824 (dump_func)dump_access_check_reply,
4825 (dump_func)dump_get_token_sid_reply,
4826 (dump_func)dump_get_token_groups_reply,
4827 (dump_func)dump_get_token_default_dacl_reply,
4828 NULL,
4829 NULL,
4830 (dump_func)dump_get_security_object_reply,
4831 (dump_func)dump_get_system_handles_reply,
4832 (dump_func)dump_create_mailslot_reply,
4833 (dump_func)dump_set_mailslot_info_reply,
4834 (dump_func)dump_create_directory_reply,
4835 (dump_func)dump_open_directory_reply,
4836 (dump_func)dump_get_directory_entry_reply,
4837 (dump_func)dump_create_symlink_reply,
4838 (dump_func)dump_open_symlink_reply,
4839 (dump_func)dump_query_symlink_reply,
4840 (dump_func)dump_get_object_info_reply,
4841 (dump_func)dump_get_object_type_reply,
4842 NULL,
4843 (dump_func)dump_get_token_impersonation_level_reply,
4844 (dump_func)dump_allocate_locally_unique_id_reply,
4845 (dump_func)dump_create_device_manager_reply,
4846 (dump_func)dump_create_device_reply,
4847 NULL,
4848 (dump_func)dump_get_next_device_request_reply,
4849 (dump_func)dump_make_process_system_reply,
4850 (dump_func)dump_get_token_statistics_reply,
4851 (dump_func)dump_create_completion_reply,
4852 (dump_func)dump_open_completion_reply,
4853 NULL,
4854 (dump_func)dump_remove_completion_reply,
4855 (dump_func)dump_query_completion_reply,
4856 NULL,
4857 NULL,
4858 NULL,
4859 NULL,
4860 (dump_func)dump_get_window_layered_info_reply,
4861 NULL,
4862 (dump_func)dump_alloc_user_handle_reply,
4863 NULL,
4864 (dump_func)dump_set_cursor_reply,
4865 NULL,
4866 (dump_func)dump_get_suspend_context_reply,
4867 NULL,
4868 (dump_func)dump_create_job_reply,
4869 (dump_func)dump_open_job_reply,
4870 NULL,
4871 NULL,
4872 NULL,
4873 NULL,
4874 NULL,
4877 static const char * const req_names[REQ_NB_REQUESTS] = {
4878 "new_process",
4879 "get_new_process_info",
4880 "new_thread",
4881 "get_startup_info",
4882 "init_process_done",
4883 "init_thread",
4884 "terminate_process",
4885 "terminate_thread",
4886 "get_process_info",
4887 "set_process_info",
4888 "get_thread_info",
4889 "get_thread_times",
4890 "set_thread_info",
4891 "get_dll_info",
4892 "suspend_thread",
4893 "resume_thread",
4894 "load_dll",
4895 "unload_dll",
4896 "queue_apc",
4897 "get_apc_result",
4898 "close_handle",
4899 "set_handle_info",
4900 "dup_handle",
4901 "open_process",
4902 "open_thread",
4903 "select",
4904 "create_event",
4905 "event_op",
4906 "query_event",
4907 "open_event",
4908 "create_keyed_event",
4909 "open_keyed_event",
4910 "create_mutex",
4911 "release_mutex",
4912 "open_mutex",
4913 "query_mutex",
4914 "create_semaphore",
4915 "release_semaphore",
4916 "query_semaphore",
4917 "open_semaphore",
4918 "create_file",
4919 "open_file_object",
4920 "alloc_file_handle",
4921 "get_handle_unix_name",
4922 "get_handle_fd",
4923 "get_directory_cache_entry",
4924 "flush",
4925 "lock_file",
4926 "unlock_file",
4927 "create_socket",
4928 "accept_socket",
4929 "accept_into_socket",
4930 "set_socket_event",
4931 "get_socket_event",
4932 "get_socket_info",
4933 "enable_socket_event",
4934 "set_socket_deferred",
4935 "alloc_console",
4936 "free_console",
4937 "get_console_renderer_events",
4938 "open_console",
4939 "get_console_wait_event",
4940 "get_console_mode",
4941 "set_console_mode",
4942 "set_console_input_info",
4943 "get_console_input_info",
4944 "append_console_input_history",
4945 "get_console_input_history",
4946 "create_console_output",
4947 "set_console_output_info",
4948 "get_console_output_info",
4949 "write_console_input",
4950 "read_console_input",
4951 "write_console_output",
4952 "fill_console_output",
4953 "read_console_output",
4954 "move_console_output",
4955 "send_console_signal",
4956 "read_directory_changes",
4957 "read_change",
4958 "create_mapping",
4959 "open_mapping",
4960 "get_mapping_info",
4961 "get_mapping_committed_range",
4962 "add_mapping_committed_range",
4963 "create_snapshot",
4964 "next_process",
4965 "next_thread",
4966 "wait_debug_event",
4967 "queue_exception_event",
4968 "get_exception_status",
4969 "continue_debug_event",
4970 "debug_process",
4971 "debug_break",
4972 "set_debugger_kill_on_exit",
4973 "read_process_memory",
4974 "write_process_memory",
4975 "create_key",
4976 "open_key",
4977 "delete_key",
4978 "flush_key",
4979 "enum_key",
4980 "set_key_value",
4981 "get_key_value",
4982 "enum_key_value",
4983 "delete_key_value",
4984 "load_registry",
4985 "unload_registry",
4986 "save_registry",
4987 "set_registry_notification",
4988 "create_timer",
4989 "open_timer",
4990 "set_timer",
4991 "cancel_timer",
4992 "get_timer_info",
4993 "get_thread_context",
4994 "set_thread_context",
4995 "get_selector_entry",
4996 "add_atom",
4997 "delete_atom",
4998 "find_atom",
4999 "get_atom_information",
5000 "set_atom_information",
5001 "empty_atom_table",
5002 "init_atom_table",
5003 "get_msg_queue",
5004 "set_queue_fd",
5005 "set_queue_mask",
5006 "get_queue_status",
5007 "get_process_idle_event",
5008 "send_message",
5009 "post_quit_message",
5010 "send_hardware_message",
5011 "get_message",
5012 "reply_message",
5013 "accept_hardware_message",
5014 "get_message_reply",
5015 "set_win_timer",
5016 "kill_win_timer",
5017 "is_window_hung",
5018 "get_serial_info",
5019 "set_serial_info",
5020 "register_async",
5021 "cancel_async",
5022 "read",
5023 "write",
5024 "ioctl",
5025 "set_irp_result",
5026 "get_irp_result",
5027 "create_named_pipe",
5028 "get_named_pipe_info",
5029 "set_named_pipe_info",
5030 "create_window",
5031 "destroy_window",
5032 "get_desktop_window",
5033 "set_window_owner",
5034 "get_window_info",
5035 "set_window_info",
5036 "set_parent",
5037 "get_window_parents",
5038 "get_window_children",
5039 "get_window_children_from_point",
5040 "get_window_tree",
5041 "set_window_pos",
5042 "get_window_rectangles",
5043 "get_window_text",
5044 "set_window_text",
5045 "get_windows_offset",
5046 "get_visible_region",
5047 "get_surface_region",
5048 "get_window_region",
5049 "set_window_region",
5050 "get_update_region",
5051 "update_window_zorder",
5052 "redraw_window",
5053 "set_window_property",
5054 "remove_window_property",
5055 "get_window_property",
5056 "get_window_properties",
5057 "create_winstation",
5058 "open_winstation",
5059 "close_winstation",
5060 "get_process_winstation",
5061 "set_process_winstation",
5062 "enum_winstation",
5063 "create_desktop",
5064 "open_desktop",
5065 "open_input_desktop",
5066 "close_desktop",
5067 "get_thread_desktop",
5068 "set_thread_desktop",
5069 "enum_desktop",
5070 "set_user_object_info",
5071 "register_hotkey",
5072 "unregister_hotkey",
5073 "attach_thread_input",
5074 "get_thread_input",
5075 "get_last_input_time",
5076 "get_key_state",
5077 "set_key_state",
5078 "set_foreground_window",
5079 "set_focus_window",
5080 "set_active_window",
5081 "set_capture_window",
5082 "set_caret_window",
5083 "set_caret_info",
5084 "set_hook",
5085 "remove_hook",
5086 "start_hook_chain",
5087 "finish_hook_chain",
5088 "get_hook_info",
5089 "create_class",
5090 "destroy_class",
5091 "set_class_info",
5092 "set_clipboard_info",
5093 "empty_clipboard",
5094 "open_token",
5095 "set_global_windows",
5096 "adjust_token_privileges",
5097 "get_token_privileges",
5098 "check_token_privileges",
5099 "duplicate_token",
5100 "access_check",
5101 "get_token_sid",
5102 "get_token_groups",
5103 "get_token_default_dacl",
5104 "set_token_default_dacl",
5105 "set_security_object",
5106 "get_security_object",
5107 "get_system_handles",
5108 "create_mailslot",
5109 "set_mailslot_info",
5110 "create_directory",
5111 "open_directory",
5112 "get_directory_entry",
5113 "create_symlink",
5114 "open_symlink",
5115 "query_symlink",
5116 "get_object_info",
5117 "get_object_type",
5118 "unlink_object",
5119 "get_token_impersonation_level",
5120 "allocate_locally_unique_id",
5121 "create_device_manager",
5122 "create_device",
5123 "delete_device",
5124 "get_next_device_request",
5125 "make_process_system",
5126 "get_token_statistics",
5127 "create_completion",
5128 "open_completion",
5129 "add_completion",
5130 "remove_completion",
5131 "query_completion",
5132 "set_completion_info",
5133 "add_fd_completion",
5134 "set_fd_disp_info",
5135 "set_fd_name_info",
5136 "get_window_layered_info",
5137 "set_window_layered_info",
5138 "alloc_user_handle",
5139 "free_user_handle",
5140 "set_cursor",
5141 "update_rawinput_devices",
5142 "get_suspend_context",
5143 "set_suspend_context",
5144 "create_job",
5145 "open_job",
5146 "assign_job",
5147 "process_in_job",
5148 "set_job_limits",
5149 "set_job_completion_port",
5150 "terminate_job",
5153 static const struct
5155 const char *name;
5156 unsigned int value;
5157 } status_names[] =
5159 { "ABANDONED_WAIT_0", STATUS_ABANDONED_WAIT_0 },
5160 { "ACCESS_DENIED", STATUS_ACCESS_DENIED },
5161 { "ACCESS_VIOLATION", STATUS_ACCESS_VIOLATION },
5162 { "ADDRESS_ALREADY_ASSOCIATED", STATUS_ADDRESS_ALREADY_ASSOCIATED },
5163 { "ALERTED", STATUS_ALERTED },
5164 { "ALIAS_EXISTS", STATUS_ALIAS_EXISTS },
5165 { "BAD_DEVICE_TYPE", STATUS_BAD_DEVICE_TYPE },
5166 { "BAD_IMPERSONATION_LEVEL", STATUS_BAD_IMPERSONATION_LEVEL },
5167 { "BREAKPOINT", STATUS_BREAKPOINT },
5168 { "BUFFER_OVERFLOW", STATUS_BUFFER_OVERFLOW },
5169 { "BUFFER_TOO_SMALL", STATUS_BUFFER_TOO_SMALL },
5170 { "CANCELLED", STATUS_CANCELLED },
5171 { "CANNOT_DELETE", STATUS_CANNOT_DELETE },
5172 { "CANT_OPEN_ANONYMOUS", STATUS_CANT_OPEN_ANONYMOUS },
5173 { "CANT_WAIT", STATUS_CANT_WAIT },
5174 { "CHILD_MUST_BE_VOLATILE", STATUS_CHILD_MUST_BE_VOLATILE },
5175 { "CONNECTION_ABORTED", STATUS_CONNECTION_ABORTED },
5176 { "CONNECTION_DISCONNECTED", STATUS_CONNECTION_DISCONNECTED },
5177 { "CONNECTION_REFUSED", STATUS_CONNECTION_REFUSED },
5178 { "CONNECTION_RESET", STATUS_CONNECTION_RESET },
5179 { "DEBUGGER_INACTIVE", STATUS_DEBUGGER_INACTIVE },
5180 { "DEVICE_BUSY", STATUS_DEVICE_BUSY },
5181 { "DIRECTORY_NOT_EMPTY", STATUS_DIRECTORY_NOT_EMPTY },
5182 { "DISK_FULL", STATUS_DISK_FULL },
5183 { "DLL_NOT_FOUND", STATUS_DLL_NOT_FOUND },
5184 { "ERROR_CLASS_ALREADY_EXISTS", 0xc0010000 | ERROR_CLASS_ALREADY_EXISTS },
5185 { "ERROR_CLASS_DOES_NOT_EXIST", 0xc0010000 | ERROR_CLASS_DOES_NOT_EXIST },
5186 { "ERROR_CLASS_HAS_WINDOWS", 0xc0010000 | ERROR_CLASS_HAS_WINDOWS },
5187 { "ERROR_CLIPBOARD_NOT_OPEN", 0xc0010000 | ERROR_CLIPBOARD_NOT_OPEN },
5188 { "ERROR_HOTKEY_ALREADY_REGISTERED", 0xc0010000 | ERROR_HOTKEY_ALREADY_REGISTERED },
5189 { "ERROR_HOTKEY_NOT_REGISTERED", 0xc0010000 | ERROR_HOTKEY_NOT_REGISTERED },
5190 { "ERROR_INVALID_CURSOR_HANDLE", 0xc0010000 | ERROR_INVALID_CURSOR_HANDLE },
5191 { "ERROR_INVALID_INDEX", 0xc0010000 | ERROR_INVALID_INDEX },
5192 { "ERROR_INVALID_WINDOW_HANDLE", 0xc0010000 | ERROR_INVALID_WINDOW_HANDLE },
5193 { "ERROR_NO_MORE_USER_HANDLES", 0xc0010000 | ERROR_NO_MORE_USER_HANDLES },
5194 { "ERROR_WINDOW_OF_OTHER_THREAD", 0xc0010000 | ERROR_WINDOW_OF_OTHER_THREAD },
5195 { "FILE_DELETED", STATUS_FILE_DELETED },
5196 { "FILE_IS_A_DIRECTORY", STATUS_FILE_IS_A_DIRECTORY },
5197 { "FILE_LOCK_CONFLICT", STATUS_FILE_LOCK_CONFLICT },
5198 { "GENERIC_NOT_MAPPED", STATUS_GENERIC_NOT_MAPPED },
5199 { "HANDLES_CLOSED", STATUS_HANDLES_CLOSED },
5200 { "HANDLE_NOT_CLOSABLE", STATUS_HANDLE_NOT_CLOSABLE },
5201 { "HOST_UNREACHABLE", STATUS_HOST_UNREACHABLE },
5202 { "ILLEGAL_FUNCTION", STATUS_ILLEGAL_FUNCTION },
5203 { "INSTANCE_NOT_AVAILABLE", STATUS_INSTANCE_NOT_AVAILABLE },
5204 { "INSUFFICIENT_RESOURCES", STATUS_INSUFFICIENT_RESOURCES },
5205 { "INVALID_CID", STATUS_INVALID_CID },
5206 { "INVALID_DEVICE_REQUEST", STATUS_INVALID_DEVICE_REQUEST },
5207 { "INVALID_FILE_FOR_SECTION", STATUS_INVALID_FILE_FOR_SECTION },
5208 { "INVALID_HANDLE", STATUS_INVALID_HANDLE },
5209 { "INVALID_IMAGE_FORMAT", STATUS_INVALID_IMAGE_FORMAT },
5210 { "INVALID_IMAGE_NE_FORMAT", STATUS_INVALID_IMAGE_NE_FORMAT },
5211 { "INVALID_IMAGE_NOT_MZ", STATUS_INVALID_IMAGE_NOT_MZ },
5212 { "INVALID_IMAGE_PROTECT", STATUS_INVALID_IMAGE_PROTECT },
5213 { "INVALID_IMAGE_WIN_64", STATUS_INVALID_IMAGE_WIN_64 },
5214 { "INVALID_PARAMETER", STATUS_INVALID_PARAMETER },
5215 { "INVALID_SECURITY_DESCR", STATUS_INVALID_SECURITY_DESCR },
5216 { "IO_TIMEOUT", STATUS_IO_TIMEOUT },
5217 { "KEY_DELETED", STATUS_KEY_DELETED },
5218 { "MAPPED_FILE_SIZE_ZERO", STATUS_MAPPED_FILE_SIZE_ZERO },
5219 { "MORE_PROCESSING_REQUIRED", STATUS_MORE_PROCESSING_REQUIRED },
5220 { "MUTANT_NOT_OWNED", STATUS_MUTANT_NOT_OWNED },
5221 { "NAME_TOO_LONG", STATUS_NAME_TOO_LONG },
5222 { "NETWORK_BUSY", STATUS_NETWORK_BUSY },
5223 { "NETWORK_UNREACHABLE", STATUS_NETWORK_UNREACHABLE },
5224 { "NOT_ALL_ASSIGNED", STATUS_NOT_ALL_ASSIGNED },
5225 { "NOT_A_DIRECTORY", STATUS_NOT_A_DIRECTORY },
5226 { "NOT_FOUND", STATUS_NOT_FOUND },
5227 { "NOT_IMPLEMENTED", STATUS_NOT_IMPLEMENTED },
5228 { "NOT_REGISTRY_FILE", STATUS_NOT_REGISTRY_FILE },
5229 { "NOT_SUPPORTED", STATUS_NOT_SUPPORTED },
5230 { "NO_DATA_DETECTED", STATUS_NO_DATA_DETECTED },
5231 { "NO_IMPERSONATION_TOKEN", STATUS_NO_IMPERSONATION_TOKEN },
5232 { "NO_MEMORY", STATUS_NO_MEMORY },
5233 { "NO_MORE_ENTRIES", STATUS_NO_MORE_ENTRIES },
5234 { "NO_MORE_FILES", STATUS_NO_MORE_FILES },
5235 { "NO_SUCH_DEVICE", STATUS_NO_SUCH_DEVICE },
5236 { "NO_SUCH_FILE", STATUS_NO_SUCH_FILE },
5237 { "NO_TOKEN", STATUS_NO_TOKEN },
5238 { "OBJECT_NAME_COLLISION", STATUS_OBJECT_NAME_COLLISION },
5239 { "OBJECT_NAME_EXISTS", STATUS_OBJECT_NAME_EXISTS },
5240 { "OBJECT_NAME_INVALID", STATUS_OBJECT_NAME_INVALID },
5241 { "OBJECT_NAME_NOT_FOUND", STATUS_OBJECT_NAME_NOT_FOUND },
5242 { "OBJECT_PATH_INVALID", STATUS_OBJECT_PATH_INVALID },
5243 { "OBJECT_PATH_NOT_FOUND", STATUS_OBJECT_PATH_NOT_FOUND },
5244 { "OBJECT_PATH_SYNTAX_BAD", STATUS_OBJECT_PATH_SYNTAX_BAD },
5245 { "OBJECT_TYPE_MISMATCH", STATUS_OBJECT_TYPE_MISMATCH },
5246 { "PENDING", STATUS_PENDING },
5247 { "PIPE_BUSY", STATUS_PIPE_BUSY },
5248 { "PIPE_CONNECTED", STATUS_PIPE_CONNECTED },
5249 { "PIPE_DISCONNECTED", STATUS_PIPE_DISCONNECTED },
5250 { "PIPE_LISTENING", STATUS_PIPE_LISTENING },
5251 { "PIPE_NOT_AVAILABLE", STATUS_PIPE_NOT_AVAILABLE },
5252 { "PRIVILEGE_NOT_HELD", STATUS_PRIVILEGE_NOT_HELD },
5253 { "PROCESS_IN_JOB", STATUS_PROCESS_IN_JOB },
5254 { "PROCESS_IS_TERMINATING", STATUS_PROCESS_IS_TERMINATING },
5255 { "SECTION_TOO_BIG", STATUS_SECTION_TOO_BIG },
5256 { "SEMAPHORE_LIMIT_EXCEEDED", STATUS_SEMAPHORE_LIMIT_EXCEEDED },
5257 { "SHARING_VIOLATION", STATUS_SHARING_VIOLATION },
5258 { "SHUTDOWN_IN_PROGRESS", STATUS_SHUTDOWN_IN_PROGRESS },
5259 { "SUSPEND_COUNT_EXCEEDED", STATUS_SUSPEND_COUNT_EXCEEDED },
5260 { "THREAD_IS_TERMINATING", STATUS_THREAD_IS_TERMINATING },
5261 { "TIMEOUT", STATUS_TIMEOUT },
5262 { "TOO_MANY_OPENED_FILES", STATUS_TOO_MANY_OPENED_FILES },
5263 { "UNSUCCESSFUL", STATUS_UNSUCCESSFUL },
5264 { "USER_APC", STATUS_USER_APC },
5265 { "USER_MAPPED_FILE", STATUS_USER_MAPPED_FILE },
5266 { "VOLUME_DISMOUNTED", STATUS_VOLUME_DISMOUNTED },
5267 { "WAS_LOCKED", STATUS_WAS_LOCKED },
5268 { NULL, 0 }
5271 /* ### make_requests end ### */
5272 /* Everything above this line is generated automatically by tools/make_requests */
5274 static const char *get_status_name( unsigned int status )
5276 int i;
5277 static char buffer[10];
5279 if (status)
5281 for (i = 0; status_names[i].name; i++)
5282 if (status_names[i].value == status) return status_names[i].name;
5284 sprintf( buffer, "%x", status );
5285 return buffer;
5288 void trace_request(void)
5290 enum request req = current->req.request_header.req;
5291 if (req < REQ_NB_REQUESTS)
5293 fprintf( stderr, "%04x: %s(", current->id, req_names[req] );
5294 if (req_dumpers[req])
5296 cur_data = get_req_data();
5297 cur_size = get_req_data_size();
5298 req_dumpers[req]( &current->req );
5300 fprintf( stderr, " )\n" );
5302 else fprintf( stderr, "%04x: %d(?)\n", current->id, req );
5305 void trace_reply( enum request req, const union generic_reply *reply )
5307 if (req < REQ_NB_REQUESTS)
5309 fprintf( stderr, "%04x: %s() = %s",
5310 current->id, req_names[req], get_status_name(current->error) );
5311 if (reply_dumpers[req])
5313 fprintf( stderr, " {" );
5314 cur_data = current->reply_data;
5315 cur_size = reply->reply_header.reply_size;
5316 reply_dumpers[req]( reply );
5317 fprintf( stderr, " }" );
5319 fputc( '\n', stderr );
5321 else fprintf( stderr, "%04x: %d() = %s\n",
5322 current->id, req, get_status_name(current->error) );