d2d1: Make d2d_geometry_sink_vtbl static const.
[wine.git] / server / trace.c
blob3eb8583db9bc4b076e92cad1e48eeb52baa3d0f8
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 >= sizeof(struct object_attributes))
1079 const WCHAR *str;
1080 fprintf( stderr, "rootdir=%04x", objattr->rootdir );
1081 if (objattr->sd_len > size - sizeof(*objattr) ||
1082 objattr->name_len > size - sizeof(*objattr) - objattr->sd_len)
1083 return;
1084 dump_inline_security_descriptor( ",sd=", (const struct security_descriptor *)(objattr + 1), objattr->sd_len );
1085 str = (const WCHAR *)objattr + (sizeof(*objattr) + objattr->sd_len) / sizeof(WCHAR);
1086 fprintf( stderr, ",name=L\"" );
1087 dump_strW( str, objattr->name_len / sizeof(WCHAR), stderr, "\"\"" );
1088 fputc( '\"', stderr );
1089 remove_data( ((sizeof(*objattr) + objattr->sd_len) / sizeof(WCHAR)) * sizeof(WCHAR) +
1090 objattr->name_len );
1092 fputc( '}', stderr );
1095 static void dump_varargs_filesystem_event( const char *prefix, data_size_t size )
1097 static const char * const actions[] = {
1098 NULL,
1099 "ADDED",
1100 "REMOVED",
1101 "MODIFIED",
1102 "RENAMED_OLD_NAME",
1103 "RENAMED_NEW_NAME",
1104 "ADDED_STREAM",
1105 "REMOVED_STREAM",
1106 "MODIFIED_STREAM"
1109 fprintf( stderr,"%s{", prefix );
1110 while (size)
1112 const struct filesystem_event *event = cur_data;
1113 data_size_t len = (offsetof( struct filesystem_event, name[event->len] ) + sizeof(int)-1)
1114 / sizeof(int) * sizeof(int);
1115 if (size < len) break;
1116 if (event->action < sizeof(actions)/sizeof(actions[0]) && actions[event->action])
1117 fprintf( stderr, "{action=%s", actions[event->action] );
1118 else
1119 fprintf( stderr, "{action=%u", event->action );
1120 fprintf( stderr, ",name=\"%.*s\"}", event->len, event->name );
1121 size -= len;
1122 remove_data( len );
1123 if (size)fputc( ',', stderr );
1125 fputc( '}', stderr );
1128 static void dump_varargs_rawinput_devices(const char *prefix, data_size_t size )
1130 const struct rawinput_device *device;
1132 fprintf( stderr, "%s{", prefix );
1133 while (size >= sizeof(*device))
1135 device = cur_data;
1136 fprintf( stderr, "{usage_page=%04x,usage=%04x,flags=%08x,target=%08x}",
1137 device->usage_page, device->usage, device->flags, device->target );
1138 size -= sizeof(*device);
1139 remove_data( sizeof(*device) );
1140 if (size) fputc( ',', stderr );
1142 fputc( '}', stderr );
1145 typedef void (*dump_func)( const void *req );
1147 /* Everything below this line is generated automatically by tools/make_requests */
1148 /* ### make_requests begin ### */
1150 static void dump_new_process_request( const struct new_process_request *req )
1152 fprintf( stderr, " inherit_all=%d", req->inherit_all );
1153 fprintf( stderr, ", create_flags=%08x", req->create_flags );
1154 fprintf( stderr, ", socket_fd=%d", req->socket_fd );
1155 fprintf( stderr, ", exe_file=%04x", req->exe_file );
1156 fprintf( stderr, ", process_access=%08x", req->process_access );
1157 fprintf( stderr, ", process_attr=%08x", req->process_attr );
1158 fprintf( stderr, ", thread_access=%08x", req->thread_access );
1159 fprintf( stderr, ", thread_attr=%08x", req->thread_attr );
1160 dump_cpu_type( ", cpu=", &req->cpu );
1161 fprintf( stderr, ", info_size=%u", req->info_size );
1162 dump_varargs_startup_info( ", info=", min(cur_size,req->info_size) );
1163 dump_varargs_unicode_str( ", env=", cur_size );
1166 static void dump_new_process_reply( const struct new_process_reply *req )
1168 fprintf( stderr, " info=%04x", req->info );
1169 fprintf( stderr, ", pid=%04x", req->pid );
1170 fprintf( stderr, ", phandle=%04x", req->phandle );
1171 fprintf( stderr, ", tid=%04x", req->tid );
1172 fprintf( stderr, ", thandle=%04x", req->thandle );
1175 static void dump_get_new_process_info_request( const struct get_new_process_info_request *req )
1177 fprintf( stderr, " info=%04x", req->info );
1180 static void dump_get_new_process_info_reply( const struct get_new_process_info_reply *req )
1182 fprintf( stderr, " success=%d", req->success );
1183 fprintf( stderr, ", exit_code=%d", req->exit_code );
1186 static void dump_new_thread_request( const struct new_thread_request *req )
1188 fprintf( stderr, " access=%08x", req->access );
1189 fprintf( stderr, ", attributes=%08x", req->attributes );
1190 fprintf( stderr, ", suspend=%d", req->suspend );
1191 fprintf( stderr, ", request_fd=%d", req->request_fd );
1194 static void dump_new_thread_reply( const struct new_thread_reply *req )
1196 fprintf( stderr, " tid=%04x", req->tid );
1197 fprintf( stderr, ", handle=%04x", req->handle );
1200 static void dump_get_startup_info_request( const struct get_startup_info_request *req )
1204 static void dump_get_startup_info_reply( const struct get_startup_info_reply *req )
1206 fprintf( stderr, " exe_file=%04x", req->exe_file );
1207 fprintf( stderr, ", info_size=%u", req->info_size );
1208 dump_varargs_startup_info( ", info=", min(cur_size,req->info_size) );
1209 dump_varargs_unicode_str( ", env=", cur_size );
1212 static void dump_init_process_done_request( const struct init_process_done_request *req )
1214 fprintf( stderr, " gui=%d", req->gui );
1215 dump_uint64( ", module=", &req->module );
1216 dump_uint64( ", ldt_copy=", &req->ldt_copy );
1217 dump_uint64( ", entry=", &req->entry );
1220 static void dump_init_thread_request( const struct init_thread_request *req )
1222 fprintf( stderr, " unix_pid=%d", req->unix_pid );
1223 fprintf( stderr, ", unix_tid=%d", req->unix_tid );
1224 fprintf( stderr, ", debug_level=%d", req->debug_level );
1225 dump_uint64( ", teb=", &req->teb );
1226 dump_uint64( ", entry=", &req->entry );
1227 fprintf( stderr, ", reply_fd=%d", req->reply_fd );
1228 fprintf( stderr, ", wait_fd=%d", req->wait_fd );
1229 dump_cpu_type( ", cpu=", &req->cpu );
1232 static void dump_init_thread_reply( const struct init_thread_reply *req )
1234 fprintf( stderr, " pid=%04x", req->pid );
1235 fprintf( stderr, ", tid=%04x", req->tid );
1236 dump_timeout( ", server_start=", &req->server_start );
1237 fprintf( stderr, ", info_size=%u", req->info_size );
1238 fprintf( stderr, ", version=%d", req->version );
1239 fprintf( stderr, ", all_cpus=%08x", req->all_cpus );
1242 static void dump_terminate_process_request( const struct terminate_process_request *req )
1244 fprintf( stderr, " handle=%04x", req->handle );
1245 fprintf( stderr, ", exit_code=%d", req->exit_code );
1248 static void dump_terminate_process_reply( const struct terminate_process_reply *req )
1250 fprintf( stderr, " self=%d", req->self );
1253 static void dump_terminate_thread_request( const struct terminate_thread_request *req )
1255 fprintf( stderr, " handle=%04x", req->handle );
1256 fprintf( stderr, ", exit_code=%d", req->exit_code );
1259 static void dump_terminate_thread_reply( const struct terminate_thread_reply *req )
1261 fprintf( stderr, " self=%d", req->self );
1262 fprintf( stderr, ", last=%d", req->last );
1265 static void dump_get_process_info_request( const struct get_process_info_request *req )
1267 fprintf( stderr, " handle=%04x", req->handle );
1270 static void dump_get_process_info_reply( const struct get_process_info_reply *req )
1272 fprintf( stderr, " pid=%04x", req->pid );
1273 fprintf( stderr, ", ppid=%04x", req->ppid );
1274 dump_uint64( ", affinity=", &req->affinity );
1275 dump_uint64( ", peb=", &req->peb );
1276 dump_timeout( ", start_time=", &req->start_time );
1277 dump_timeout( ", end_time=", &req->end_time );
1278 fprintf( stderr, ", exit_code=%d", req->exit_code );
1279 fprintf( stderr, ", priority=%d", req->priority );
1280 dump_cpu_type( ", cpu=", &req->cpu );
1281 fprintf( stderr, ", debugger_present=%d", req->debugger_present );
1284 static void dump_set_process_info_request( const struct set_process_info_request *req )
1286 fprintf( stderr, " handle=%04x", req->handle );
1287 fprintf( stderr, ", mask=%d", req->mask );
1288 fprintf( stderr, ", priority=%d", req->priority );
1289 dump_uint64( ", affinity=", &req->affinity );
1292 static void dump_get_thread_info_request( const struct get_thread_info_request *req )
1294 fprintf( stderr, " handle=%04x", req->handle );
1295 fprintf( stderr, ", tid_in=%04x", req->tid_in );
1298 static void dump_get_thread_info_reply( const struct get_thread_info_reply *req )
1300 fprintf( stderr, " pid=%04x", req->pid );
1301 fprintf( stderr, ", tid=%04x", req->tid );
1302 dump_uint64( ", teb=", &req->teb );
1303 dump_uint64( ", entry_point=", &req->entry_point );
1304 dump_uint64( ", affinity=", &req->affinity );
1305 fprintf( stderr, ", exit_code=%d", req->exit_code );
1306 fprintf( stderr, ", priority=%d", req->priority );
1307 fprintf( stderr, ", last=%d", req->last );
1310 static void dump_get_thread_times_request( const struct get_thread_times_request *req )
1312 fprintf( stderr, " handle=%04x", req->handle );
1315 static void dump_get_thread_times_reply( const struct get_thread_times_reply *req )
1317 dump_timeout( " creation_time=", &req->creation_time );
1318 dump_timeout( ", exit_time=", &req->exit_time );
1321 static void dump_set_thread_info_request( const struct set_thread_info_request *req )
1323 fprintf( stderr, " handle=%04x", req->handle );
1324 fprintf( stderr, ", mask=%d", req->mask );
1325 fprintf( stderr, ", priority=%d", req->priority );
1326 dump_uint64( ", affinity=", &req->affinity );
1327 dump_uint64( ", entry_point=", &req->entry_point );
1328 fprintf( stderr, ", token=%04x", req->token );
1331 static void dump_get_dll_info_request( const struct get_dll_info_request *req )
1333 fprintf( stderr, " handle=%04x", req->handle );
1334 dump_uint64( ", base_address=", &req->base_address );
1337 static void dump_get_dll_info_reply( const struct get_dll_info_reply *req )
1339 dump_uint64( " entry_point=", &req->entry_point );
1340 fprintf( stderr, ", size=%u", req->size );
1341 fprintf( stderr, ", filename_len=%u", req->filename_len );
1342 dump_varargs_unicode_str( ", filename=", cur_size );
1345 static void dump_suspend_thread_request( const struct suspend_thread_request *req )
1347 fprintf( stderr, " handle=%04x", req->handle );
1350 static void dump_suspend_thread_reply( const struct suspend_thread_reply *req )
1352 fprintf( stderr, " count=%d", req->count );
1355 static void dump_resume_thread_request( const struct resume_thread_request *req )
1357 fprintf( stderr, " handle=%04x", req->handle );
1360 static void dump_resume_thread_reply( const struct resume_thread_reply *req )
1362 fprintf( stderr, " count=%d", req->count );
1365 static void dump_load_dll_request( const struct load_dll_request *req )
1367 fprintf( stderr, " mapping=%04x", req->mapping );
1368 dump_uint64( ", base=", &req->base );
1369 dump_uint64( ", name=", &req->name );
1370 fprintf( stderr, ", size=%u", req->size );
1371 fprintf( stderr, ", dbg_offset=%d", req->dbg_offset );
1372 fprintf( stderr, ", dbg_size=%d", req->dbg_size );
1373 dump_varargs_unicode_str( ", filename=", cur_size );
1376 static void dump_unload_dll_request( const struct unload_dll_request *req )
1378 dump_uint64( " base=", &req->base );
1381 static void dump_queue_apc_request( const struct queue_apc_request *req )
1383 fprintf( stderr, " handle=%04x", req->handle );
1384 dump_apc_call( ", call=", &req->call );
1387 static void dump_queue_apc_reply( const struct queue_apc_reply *req )
1389 fprintf( stderr, " handle=%04x", req->handle );
1390 fprintf( stderr, ", self=%d", req->self );
1393 static void dump_get_apc_result_request( const struct get_apc_result_request *req )
1395 fprintf( stderr, " handle=%04x", req->handle );
1398 static void dump_get_apc_result_reply( const struct get_apc_result_reply *req )
1400 dump_apc_result( " result=", &req->result );
1403 static void dump_close_handle_request( const struct close_handle_request *req )
1405 fprintf( stderr, " handle=%04x", req->handle );
1408 static void dump_set_handle_info_request( const struct set_handle_info_request *req )
1410 fprintf( stderr, " handle=%04x", req->handle );
1411 fprintf( stderr, ", flags=%d", req->flags );
1412 fprintf( stderr, ", mask=%d", req->mask );
1415 static void dump_set_handle_info_reply( const struct set_handle_info_reply *req )
1417 fprintf( stderr, " old_flags=%d", req->old_flags );
1420 static void dump_dup_handle_request( const struct dup_handle_request *req )
1422 fprintf( stderr, " src_process=%04x", req->src_process );
1423 fprintf( stderr, ", src_handle=%04x", req->src_handle );
1424 fprintf( stderr, ", dst_process=%04x", req->dst_process );
1425 fprintf( stderr, ", access=%08x", req->access );
1426 fprintf( stderr, ", attributes=%08x", req->attributes );
1427 fprintf( stderr, ", options=%08x", req->options );
1430 static void dump_dup_handle_reply( const struct dup_handle_reply *req )
1432 fprintf( stderr, " handle=%04x", req->handle );
1433 fprintf( stderr, ", self=%d", req->self );
1434 fprintf( stderr, ", closed=%d", req->closed );
1437 static void dump_open_process_request( const struct open_process_request *req )
1439 fprintf( stderr, " pid=%04x", req->pid );
1440 fprintf( stderr, ", access=%08x", req->access );
1441 fprintf( stderr, ", attributes=%08x", req->attributes );
1444 static void dump_open_process_reply( const struct open_process_reply *req )
1446 fprintf( stderr, " handle=%04x", req->handle );
1449 static void dump_open_thread_request( const struct open_thread_request *req )
1451 fprintf( stderr, " tid=%04x", req->tid );
1452 fprintf( stderr, ", access=%08x", req->access );
1453 fprintf( stderr, ", attributes=%08x", req->attributes );
1456 static void dump_open_thread_reply( const struct open_thread_reply *req )
1458 fprintf( stderr, " handle=%04x", req->handle );
1461 static void dump_select_request( const struct select_request *req )
1463 fprintf( stderr, " flags=%d", req->flags );
1464 dump_uint64( ", cookie=", &req->cookie );
1465 dump_timeout( ", timeout=", &req->timeout );
1466 fprintf( stderr, ", prev_apc=%04x", req->prev_apc );
1467 dump_varargs_apc_result( ", result=", cur_size );
1468 dump_varargs_select_op( ", data=", cur_size );
1471 static void dump_select_reply( const struct select_reply *req )
1473 dump_timeout( " timeout=", &req->timeout );
1474 dump_apc_call( ", call=", &req->call );
1475 fprintf( stderr, ", apc_handle=%04x", req->apc_handle );
1478 static void dump_create_event_request( const struct create_event_request *req )
1480 fprintf( stderr, " access=%08x", req->access );
1481 fprintf( stderr, ", attributes=%08x", req->attributes );
1482 fprintf( stderr, ", manual_reset=%d", req->manual_reset );
1483 fprintf( stderr, ", initial_state=%d", req->initial_state );
1484 dump_varargs_object_attributes( ", objattr=", cur_size );
1487 static void dump_create_event_reply( const struct create_event_reply *req )
1489 fprintf( stderr, " handle=%04x", req->handle );
1492 static void dump_event_op_request( const struct event_op_request *req )
1494 fprintf( stderr, " handle=%04x", req->handle );
1495 fprintf( stderr, ", op=%d", req->op );
1498 static void dump_query_event_request( const struct query_event_request *req )
1500 fprintf( stderr, " handle=%04x", req->handle );
1503 static void dump_query_event_reply( const struct query_event_reply *req )
1505 fprintf( stderr, " manual_reset=%d", req->manual_reset );
1506 fprintf( stderr, ", state=%d", req->state );
1509 static void dump_open_event_request( const struct open_event_request *req )
1511 fprintf( stderr, " access=%08x", req->access );
1512 fprintf( stderr, ", attributes=%08x", req->attributes );
1513 fprintf( stderr, ", rootdir=%04x", req->rootdir );
1514 dump_varargs_unicode_str( ", name=", cur_size );
1517 static void dump_open_event_reply( const struct open_event_reply *req )
1519 fprintf( stderr, " handle=%04x", req->handle );
1522 static void dump_create_keyed_event_request( const struct create_keyed_event_request *req )
1524 fprintf( stderr, " access=%08x", req->access );
1525 fprintf( stderr, ", attributes=%08x", req->attributes );
1526 dump_varargs_object_attributes( ", objattr=", cur_size );
1529 static void dump_create_keyed_event_reply( const struct create_keyed_event_reply *req )
1531 fprintf( stderr, " handle=%04x", req->handle );
1534 static void dump_open_keyed_event_request( const struct open_keyed_event_request *req )
1536 fprintf( stderr, " access=%08x", req->access );
1537 fprintf( stderr, ", attributes=%08x", req->attributes );
1538 fprintf( stderr, ", rootdir=%04x", req->rootdir );
1539 dump_varargs_unicode_str( ", name=", cur_size );
1542 static void dump_open_keyed_event_reply( const struct open_keyed_event_reply *req )
1544 fprintf( stderr, " handle=%04x", req->handle );
1547 static void dump_create_mutex_request( const struct create_mutex_request *req )
1549 fprintf( stderr, " access=%08x", req->access );
1550 fprintf( stderr, ", attributes=%08x", req->attributes );
1551 fprintf( stderr, ", owned=%d", req->owned );
1552 dump_varargs_object_attributes( ", objattr=", cur_size );
1555 static void dump_create_mutex_reply( const struct create_mutex_reply *req )
1557 fprintf( stderr, " handle=%04x", req->handle );
1560 static void dump_release_mutex_request( const struct release_mutex_request *req )
1562 fprintf( stderr, " handle=%04x", req->handle );
1565 static void dump_release_mutex_reply( const struct release_mutex_reply *req )
1567 fprintf( stderr, " prev_count=%08x", req->prev_count );
1570 static void dump_open_mutex_request( const struct open_mutex_request *req )
1572 fprintf( stderr, " access=%08x", req->access );
1573 fprintf( stderr, ", attributes=%08x", req->attributes );
1574 fprintf( stderr, ", rootdir=%04x", req->rootdir );
1575 dump_varargs_unicode_str( ", name=", cur_size );
1578 static void dump_open_mutex_reply( const struct open_mutex_reply *req )
1580 fprintf( stderr, " handle=%04x", req->handle );
1583 static void dump_create_semaphore_request( const struct create_semaphore_request *req )
1585 fprintf( stderr, " access=%08x", req->access );
1586 fprintf( stderr, ", attributes=%08x", req->attributes );
1587 fprintf( stderr, ", initial=%08x", req->initial );
1588 fprintf( stderr, ", max=%08x", req->max );
1589 dump_varargs_object_attributes( ", objattr=", cur_size );
1592 static void dump_create_semaphore_reply( const struct create_semaphore_reply *req )
1594 fprintf( stderr, " handle=%04x", req->handle );
1597 static void dump_release_semaphore_request( const struct release_semaphore_request *req )
1599 fprintf( stderr, " handle=%04x", req->handle );
1600 fprintf( stderr, ", count=%08x", req->count );
1603 static void dump_release_semaphore_reply( const struct release_semaphore_reply *req )
1605 fprintf( stderr, " prev_count=%08x", req->prev_count );
1608 static void dump_query_semaphore_request( const struct query_semaphore_request *req )
1610 fprintf( stderr, " handle=%04x", req->handle );
1613 static void dump_query_semaphore_reply( const struct query_semaphore_reply *req )
1615 fprintf( stderr, " current=%08x", req->current );
1616 fprintf( stderr, ", max=%08x", req->max );
1619 static void dump_open_semaphore_request( const struct open_semaphore_request *req )
1621 fprintf( stderr, " access=%08x", req->access );
1622 fprintf( stderr, ", attributes=%08x", req->attributes );
1623 fprintf( stderr, ", rootdir=%04x", req->rootdir );
1624 dump_varargs_unicode_str( ", name=", cur_size );
1627 static void dump_open_semaphore_reply( const struct open_semaphore_reply *req )
1629 fprintf( stderr, " handle=%04x", req->handle );
1632 static void dump_create_file_request( const struct create_file_request *req )
1634 fprintf( stderr, " access=%08x", req->access );
1635 fprintf( stderr, ", attributes=%08x", req->attributes );
1636 fprintf( stderr, ", sharing=%08x", req->sharing );
1637 fprintf( stderr, ", create=%d", req->create );
1638 fprintf( stderr, ", options=%08x", req->options );
1639 fprintf( stderr, ", attrs=%08x", req->attrs );
1640 dump_varargs_object_attributes( ", objattr=", cur_size );
1641 dump_varargs_string( ", filename=", cur_size );
1644 static void dump_create_file_reply( const struct create_file_reply *req )
1646 fprintf( stderr, " handle=%04x", req->handle );
1649 static void dump_open_file_object_request( const struct open_file_object_request *req )
1651 fprintf( stderr, " access=%08x", req->access );
1652 fprintf( stderr, ", attributes=%08x", req->attributes );
1653 fprintf( stderr, ", rootdir=%04x", req->rootdir );
1654 fprintf( stderr, ", sharing=%08x", req->sharing );
1655 fprintf( stderr, ", options=%08x", req->options );
1656 dump_varargs_unicode_str( ", filename=", cur_size );
1659 static void dump_open_file_object_reply( const struct open_file_object_reply *req )
1661 fprintf( stderr, " handle=%04x", req->handle );
1664 static void dump_alloc_file_handle_request( const struct alloc_file_handle_request *req )
1666 fprintf( stderr, " access=%08x", req->access );
1667 fprintf( stderr, ", attributes=%08x", req->attributes );
1668 fprintf( stderr, ", fd=%d", req->fd );
1671 static void dump_alloc_file_handle_reply( const struct alloc_file_handle_reply *req )
1673 fprintf( stderr, " handle=%04x", req->handle );
1676 static void dump_get_handle_unix_name_request( const struct get_handle_unix_name_request *req )
1678 fprintf( stderr, " handle=%04x", req->handle );
1681 static void dump_get_handle_unix_name_reply( const struct get_handle_unix_name_reply *req )
1683 fprintf( stderr, " name_len=%u", req->name_len );
1684 dump_varargs_string( ", name=", cur_size );
1687 static void dump_get_handle_fd_request( const struct get_handle_fd_request *req )
1689 fprintf( stderr, " handle=%04x", req->handle );
1692 static void dump_get_handle_fd_reply( const struct get_handle_fd_reply *req )
1694 fprintf( stderr, " type=%d", req->type );
1695 fprintf( stderr, ", cacheable=%d", req->cacheable );
1696 fprintf( stderr, ", access=%08x", req->access );
1697 fprintf( stderr, ", options=%08x", req->options );
1700 static void dump_flush_request( const struct flush_request *req )
1702 fprintf( stderr, " blocking=%d", req->blocking );
1703 dump_async_data( ", async=", &req->async );
1706 static void dump_flush_reply( const struct flush_reply *req )
1708 fprintf( stderr, " event=%04x", req->event );
1711 static void dump_lock_file_request( const struct lock_file_request *req )
1713 fprintf( stderr, " handle=%04x", req->handle );
1714 dump_uint64( ", offset=", &req->offset );
1715 dump_uint64( ", count=", &req->count );
1716 fprintf( stderr, ", shared=%d", req->shared );
1717 fprintf( stderr, ", wait=%d", req->wait );
1720 static void dump_lock_file_reply( const struct lock_file_reply *req )
1722 fprintf( stderr, " handle=%04x", req->handle );
1723 fprintf( stderr, ", overlapped=%d", req->overlapped );
1726 static void dump_unlock_file_request( const struct unlock_file_request *req )
1728 fprintf( stderr, " handle=%04x", req->handle );
1729 dump_uint64( ", offset=", &req->offset );
1730 dump_uint64( ", count=", &req->count );
1733 static void dump_create_socket_request( const struct create_socket_request *req )
1735 fprintf( stderr, " access=%08x", req->access );
1736 fprintf( stderr, ", attributes=%08x", req->attributes );
1737 fprintf( stderr, ", family=%d", req->family );
1738 fprintf( stderr, ", type=%d", req->type );
1739 fprintf( stderr, ", protocol=%d", req->protocol );
1740 fprintf( stderr, ", flags=%08x", req->flags );
1743 static void dump_create_socket_reply( const struct create_socket_reply *req )
1745 fprintf( stderr, " handle=%04x", req->handle );
1748 static void dump_accept_socket_request( const struct accept_socket_request *req )
1750 fprintf( stderr, " lhandle=%04x", req->lhandle );
1751 fprintf( stderr, ", access=%08x", req->access );
1752 fprintf( stderr, ", attributes=%08x", req->attributes );
1755 static void dump_accept_socket_reply( const struct accept_socket_reply *req )
1757 fprintf( stderr, " handle=%04x", req->handle );
1760 static void dump_accept_into_socket_request( const struct accept_into_socket_request *req )
1762 fprintf( stderr, " lhandle=%04x", req->lhandle );
1763 fprintf( stderr, ", ahandle=%04x", req->ahandle );
1766 static void dump_set_socket_event_request( const struct set_socket_event_request *req )
1768 fprintf( stderr, " handle=%04x", req->handle );
1769 fprintf( stderr, ", mask=%08x", req->mask );
1770 fprintf( stderr, ", event=%04x", req->event );
1771 fprintf( stderr, ", window=%08x", req->window );
1772 fprintf( stderr, ", msg=%08x", req->msg );
1775 static void dump_get_socket_event_request( const struct get_socket_event_request *req )
1777 fprintf( stderr, " handle=%04x", req->handle );
1778 fprintf( stderr, ", service=%d", req->service );
1779 fprintf( stderr, ", c_event=%04x", req->c_event );
1782 static void dump_get_socket_event_reply( const struct get_socket_event_reply *req )
1784 fprintf( stderr, " mask=%08x", req->mask );
1785 fprintf( stderr, ", pmask=%08x", req->pmask );
1786 fprintf( stderr, ", state=%08x", req->state );
1787 dump_varargs_ints( ", errors=", cur_size );
1790 static void dump_get_socket_info_request( const struct get_socket_info_request *req )
1792 fprintf( stderr, " handle=%04x", req->handle );
1795 static void dump_get_socket_info_reply( const struct get_socket_info_reply *req )
1797 fprintf( stderr, " family=%d", req->family );
1798 fprintf( stderr, ", type=%d", req->type );
1799 fprintf( stderr, ", protocol=%d", req->protocol );
1802 static void dump_enable_socket_event_request( const struct enable_socket_event_request *req )
1804 fprintf( stderr, " handle=%04x", req->handle );
1805 fprintf( stderr, ", mask=%08x", req->mask );
1806 fprintf( stderr, ", sstate=%08x", req->sstate );
1807 fprintf( stderr, ", cstate=%08x", req->cstate );
1810 static void dump_set_socket_deferred_request( const struct set_socket_deferred_request *req )
1812 fprintf( stderr, " handle=%04x", req->handle );
1813 fprintf( stderr, ", deferred=%04x", req->deferred );
1816 static void dump_alloc_console_request( const struct alloc_console_request *req )
1818 fprintf( stderr, " access=%08x", req->access );
1819 fprintf( stderr, ", attributes=%08x", req->attributes );
1820 fprintf( stderr, ", pid=%04x", req->pid );
1821 fprintf( stderr, ", input_fd=%d", req->input_fd );
1824 static void dump_alloc_console_reply( const struct alloc_console_reply *req )
1826 fprintf( stderr, " handle_in=%04x", req->handle_in );
1827 fprintf( stderr, ", event=%04x", req->event );
1830 static void dump_free_console_request( const struct free_console_request *req )
1834 static void dump_get_console_renderer_events_request( const struct get_console_renderer_events_request *req )
1836 fprintf( stderr, " handle=%04x", req->handle );
1839 static void dump_get_console_renderer_events_reply( const struct get_console_renderer_events_reply *req )
1841 dump_varargs_bytes( " data=", cur_size );
1844 static void dump_open_console_request( const struct open_console_request *req )
1846 fprintf( stderr, " from=%04x", req->from );
1847 fprintf( stderr, ", access=%08x", req->access );
1848 fprintf( stderr, ", attributes=%08x", req->attributes );
1849 fprintf( stderr, ", share=%d", req->share );
1852 static void dump_open_console_reply( const struct open_console_reply *req )
1854 fprintf( stderr, " handle=%04x", req->handle );
1857 static void dump_get_console_wait_event_request( const struct get_console_wait_event_request *req )
1861 static void dump_get_console_wait_event_reply( const struct get_console_wait_event_reply *req )
1863 fprintf( stderr, " handle=%04x", req->handle );
1866 static void dump_get_console_mode_request( const struct get_console_mode_request *req )
1868 fprintf( stderr, " handle=%04x", req->handle );
1871 static void dump_get_console_mode_reply( const struct get_console_mode_reply *req )
1873 fprintf( stderr, " mode=%d", req->mode );
1876 static void dump_set_console_mode_request( const struct set_console_mode_request *req )
1878 fprintf( stderr, " handle=%04x", req->handle );
1879 fprintf( stderr, ", mode=%d", req->mode );
1882 static void dump_set_console_input_info_request( const struct set_console_input_info_request *req )
1884 fprintf( stderr, " handle=%04x", req->handle );
1885 fprintf( stderr, ", mask=%d", req->mask );
1886 fprintf( stderr, ", active_sb=%04x", req->active_sb );
1887 fprintf( stderr, ", history_mode=%d", req->history_mode );
1888 fprintf( stderr, ", history_size=%d", req->history_size );
1889 fprintf( stderr, ", edition_mode=%d", req->edition_mode );
1890 fprintf( stderr, ", input_cp=%d", req->input_cp );
1891 fprintf( stderr, ", output_cp=%d", req->output_cp );
1892 fprintf( stderr, ", win=%08x", req->win );
1893 dump_varargs_unicode_str( ", title=", cur_size );
1896 static void dump_get_console_input_info_request( const struct get_console_input_info_request *req )
1898 fprintf( stderr, " handle=%04x", req->handle );
1901 static void dump_get_console_input_info_reply( const struct get_console_input_info_reply *req )
1903 fprintf( stderr, " history_mode=%d", req->history_mode );
1904 fprintf( stderr, ", history_size=%d", req->history_size );
1905 fprintf( stderr, ", history_index=%d", req->history_index );
1906 fprintf( stderr, ", edition_mode=%d", req->edition_mode );
1907 fprintf( stderr, ", input_cp=%d", req->input_cp );
1908 fprintf( stderr, ", output_cp=%d", req->output_cp );
1909 fprintf( stderr, ", win=%08x", req->win );
1910 dump_varargs_unicode_str( ", title=", cur_size );
1913 static void dump_append_console_input_history_request( const struct append_console_input_history_request *req )
1915 fprintf( stderr, " handle=%04x", req->handle );
1916 dump_varargs_unicode_str( ", line=", cur_size );
1919 static void dump_get_console_input_history_request( const struct get_console_input_history_request *req )
1921 fprintf( stderr, " handle=%04x", req->handle );
1922 fprintf( stderr, ", index=%d", req->index );
1925 static void dump_get_console_input_history_reply( const struct get_console_input_history_reply *req )
1927 fprintf( stderr, " total=%d", req->total );
1928 dump_varargs_unicode_str( ", line=", cur_size );
1931 static void dump_create_console_output_request( const struct create_console_output_request *req )
1933 fprintf( stderr, " handle_in=%04x", req->handle_in );
1934 fprintf( stderr, ", access=%08x", req->access );
1935 fprintf( stderr, ", attributes=%08x", req->attributes );
1936 fprintf( stderr, ", share=%08x", req->share );
1937 fprintf( stderr, ", fd=%d", req->fd );
1940 static void dump_create_console_output_reply( const struct create_console_output_reply *req )
1942 fprintf( stderr, " handle_out=%04x", req->handle_out );
1945 static void dump_set_console_output_info_request( const struct set_console_output_info_request *req )
1947 fprintf( stderr, " handle=%04x", req->handle );
1948 fprintf( stderr, ", mask=%d", req->mask );
1949 fprintf( stderr, ", cursor_size=%d", req->cursor_size );
1950 fprintf( stderr, ", cursor_visible=%d", req->cursor_visible );
1951 fprintf( stderr, ", cursor_x=%d", req->cursor_x );
1952 fprintf( stderr, ", cursor_y=%d", req->cursor_y );
1953 fprintf( stderr, ", width=%d", req->width );
1954 fprintf( stderr, ", height=%d", req->height );
1955 fprintf( stderr, ", attr=%d", req->attr );
1956 fprintf( stderr, ", win_left=%d", req->win_left );
1957 fprintf( stderr, ", win_top=%d", req->win_top );
1958 fprintf( stderr, ", win_right=%d", req->win_right );
1959 fprintf( stderr, ", win_bottom=%d", req->win_bottom );
1960 fprintf( stderr, ", max_width=%d", req->max_width );
1961 fprintf( stderr, ", max_height=%d", req->max_height );
1964 static void dump_get_console_output_info_request( const struct get_console_output_info_request *req )
1966 fprintf( stderr, " handle=%04x", req->handle );
1969 static void dump_get_console_output_info_reply( const struct get_console_output_info_reply *req )
1971 fprintf( stderr, " cursor_size=%d", req->cursor_size );
1972 fprintf( stderr, ", cursor_visible=%d", req->cursor_visible );
1973 fprintf( stderr, ", cursor_x=%d", req->cursor_x );
1974 fprintf( stderr, ", cursor_y=%d", req->cursor_y );
1975 fprintf( stderr, ", width=%d", req->width );
1976 fprintf( stderr, ", height=%d", req->height );
1977 fprintf( stderr, ", attr=%d", req->attr );
1978 fprintf( stderr, ", win_left=%d", req->win_left );
1979 fprintf( stderr, ", win_top=%d", req->win_top );
1980 fprintf( stderr, ", win_right=%d", req->win_right );
1981 fprintf( stderr, ", win_bottom=%d", req->win_bottom );
1982 fprintf( stderr, ", max_width=%d", req->max_width );
1983 fprintf( stderr, ", max_height=%d", req->max_height );
1986 static void dump_write_console_input_request( const struct write_console_input_request *req )
1988 fprintf( stderr, " handle=%04x", req->handle );
1989 dump_varargs_input_records( ", rec=", cur_size );
1992 static void dump_write_console_input_reply( const struct write_console_input_reply *req )
1994 fprintf( stderr, " written=%d", req->written );
1997 static void dump_read_console_input_request( const struct read_console_input_request *req )
1999 fprintf( stderr, " handle=%04x", req->handle );
2000 fprintf( stderr, ", flush=%d", req->flush );
2003 static void dump_read_console_input_reply( const struct read_console_input_reply *req )
2005 fprintf( stderr, " read=%d", req->read );
2006 dump_varargs_input_records( ", rec=", cur_size );
2009 static void dump_write_console_output_request( const struct write_console_output_request *req )
2011 fprintf( stderr, " handle=%04x", req->handle );
2012 fprintf( stderr, ", x=%d", req->x );
2013 fprintf( stderr, ", y=%d", req->y );
2014 fprintf( stderr, ", mode=%d", req->mode );
2015 fprintf( stderr, ", wrap=%d", req->wrap );
2016 dump_varargs_bytes( ", data=", cur_size );
2019 static void dump_write_console_output_reply( const struct write_console_output_reply *req )
2021 fprintf( stderr, " written=%d", req->written );
2022 fprintf( stderr, ", width=%d", req->width );
2023 fprintf( stderr, ", height=%d", req->height );
2026 static void dump_fill_console_output_request( const struct fill_console_output_request *req )
2028 fprintf( stderr, " handle=%04x", req->handle );
2029 fprintf( stderr, ", x=%d", req->x );
2030 fprintf( stderr, ", y=%d", req->y );
2031 fprintf( stderr, ", mode=%d", req->mode );
2032 fprintf( stderr, ", count=%d", req->count );
2033 fprintf( stderr, ", wrap=%d", req->wrap );
2034 dump_char_info( ", data=", &req->data );
2037 static void dump_fill_console_output_reply( const struct fill_console_output_reply *req )
2039 fprintf( stderr, " written=%d", req->written );
2042 static void dump_read_console_output_request( const struct read_console_output_request *req )
2044 fprintf( stderr, " handle=%04x", req->handle );
2045 fprintf( stderr, ", x=%d", req->x );
2046 fprintf( stderr, ", y=%d", req->y );
2047 fprintf( stderr, ", mode=%d", req->mode );
2048 fprintf( stderr, ", wrap=%d", req->wrap );
2051 static void dump_read_console_output_reply( const struct read_console_output_reply *req )
2053 fprintf( stderr, " width=%d", req->width );
2054 fprintf( stderr, ", height=%d", req->height );
2055 dump_varargs_bytes( ", data=", cur_size );
2058 static void dump_move_console_output_request( const struct move_console_output_request *req )
2060 fprintf( stderr, " handle=%04x", req->handle );
2061 fprintf( stderr, ", x_src=%d", req->x_src );
2062 fprintf( stderr, ", y_src=%d", req->y_src );
2063 fprintf( stderr, ", x_dst=%d", req->x_dst );
2064 fprintf( stderr, ", y_dst=%d", req->y_dst );
2065 fprintf( stderr, ", w=%d", req->w );
2066 fprintf( stderr, ", h=%d", req->h );
2069 static void dump_send_console_signal_request( const struct send_console_signal_request *req )
2071 fprintf( stderr, " signal=%d", req->signal );
2072 fprintf( stderr, ", group_id=%04x", req->group_id );
2075 static void dump_read_directory_changes_request( const struct read_directory_changes_request *req )
2077 fprintf( stderr, " filter=%08x", req->filter );
2078 fprintf( stderr, ", subtree=%d", req->subtree );
2079 fprintf( stderr, ", want_data=%d", req->want_data );
2080 dump_async_data( ", async=", &req->async );
2083 static void dump_read_change_request( const struct read_change_request *req )
2085 fprintf( stderr, " handle=%04x", req->handle );
2088 static void dump_read_change_reply( const struct read_change_reply *req )
2090 dump_varargs_filesystem_event( " events=", cur_size );
2093 static void dump_create_mapping_request( const struct create_mapping_request *req )
2095 fprintf( stderr, " access=%08x", req->access );
2096 fprintf( stderr, ", attributes=%08x", req->attributes );
2097 fprintf( stderr, ", protect=%08x", req->protect );
2098 dump_uint64( ", size=", &req->size );
2099 fprintf( stderr, ", file_handle=%04x", req->file_handle );
2100 dump_varargs_object_attributes( ", objattr=", cur_size );
2103 static void dump_create_mapping_reply( const struct create_mapping_reply *req )
2105 fprintf( stderr, " handle=%04x", req->handle );
2108 static void dump_open_mapping_request( const struct open_mapping_request *req )
2110 fprintf( stderr, " access=%08x", req->access );
2111 fprintf( stderr, ", attributes=%08x", req->attributes );
2112 fprintf( stderr, ", rootdir=%04x", req->rootdir );
2113 dump_varargs_unicode_str( ", name=", cur_size );
2116 static void dump_open_mapping_reply( const struct open_mapping_reply *req )
2118 fprintf( stderr, " handle=%04x", req->handle );
2121 static void dump_get_mapping_info_request( const struct get_mapping_info_request *req )
2123 fprintf( stderr, " handle=%04x", req->handle );
2124 fprintf( stderr, ", access=%08x", req->access );
2127 static void dump_get_mapping_info_reply( const struct get_mapping_info_reply *req )
2129 dump_uint64( " size=", &req->size );
2130 fprintf( stderr, ", protect=%d", req->protect );
2131 fprintf( stderr, ", header_size=%d", req->header_size );
2132 dump_uint64( ", base=", &req->base );
2133 fprintf( stderr, ", mapping=%04x", req->mapping );
2134 fprintf( stderr, ", shared_file=%04x", req->shared_file );
2137 static void dump_get_mapping_committed_range_request( const struct get_mapping_committed_range_request *req )
2139 fprintf( stderr, " handle=%04x", req->handle );
2140 dump_uint64( ", offset=", &req->offset );
2143 static void dump_get_mapping_committed_range_reply( const struct get_mapping_committed_range_reply *req )
2145 dump_uint64( " size=", &req->size );
2146 fprintf( stderr, ", committed=%d", req->committed );
2149 static void dump_add_mapping_committed_range_request( const struct add_mapping_committed_range_request *req )
2151 fprintf( stderr, " handle=%04x", req->handle );
2152 dump_uint64( ", offset=", &req->offset );
2153 dump_uint64( ", size=", &req->size );
2156 static void dump_create_snapshot_request( const struct create_snapshot_request *req )
2158 fprintf( stderr, " attributes=%08x", req->attributes );
2159 fprintf( stderr, ", flags=%08x", req->flags );
2162 static void dump_create_snapshot_reply( const struct create_snapshot_reply *req )
2164 fprintf( stderr, " handle=%04x", req->handle );
2167 static void dump_next_process_request( const struct next_process_request *req )
2169 fprintf( stderr, " handle=%04x", req->handle );
2170 fprintf( stderr, ", reset=%d", req->reset );
2173 static void dump_next_process_reply( const struct next_process_reply *req )
2175 fprintf( stderr, " count=%d", req->count );
2176 fprintf( stderr, ", pid=%04x", req->pid );
2177 fprintf( stderr, ", ppid=%04x", req->ppid );
2178 fprintf( stderr, ", threads=%d", req->threads );
2179 fprintf( stderr, ", priority=%d", req->priority );
2180 fprintf( stderr, ", handles=%d", req->handles );
2181 fprintf( stderr, ", unix_pid=%d", req->unix_pid );
2182 dump_varargs_unicode_str( ", filename=", cur_size );
2185 static void dump_next_thread_request( const struct next_thread_request *req )
2187 fprintf( stderr, " handle=%04x", req->handle );
2188 fprintf( stderr, ", reset=%d", req->reset );
2191 static void dump_next_thread_reply( const struct next_thread_reply *req )
2193 fprintf( stderr, " count=%d", req->count );
2194 fprintf( stderr, ", pid=%04x", req->pid );
2195 fprintf( stderr, ", tid=%04x", req->tid );
2196 fprintf( stderr, ", base_pri=%d", req->base_pri );
2197 fprintf( stderr, ", delta_pri=%d", req->delta_pri );
2200 static void dump_wait_debug_event_request( const struct wait_debug_event_request *req )
2202 fprintf( stderr, " get_handle=%d", req->get_handle );
2205 static void dump_wait_debug_event_reply( const struct wait_debug_event_reply *req )
2207 fprintf( stderr, " pid=%04x", req->pid );
2208 fprintf( stderr, ", tid=%04x", req->tid );
2209 fprintf( stderr, ", wait=%04x", req->wait );
2210 dump_varargs_debug_event( ", event=", cur_size );
2213 static void dump_queue_exception_event_request( const struct queue_exception_event_request *req )
2215 fprintf( stderr, " first=%d", req->first );
2216 fprintf( stderr, ", code=%08x", req->code );
2217 fprintf( stderr, ", flags=%08x", req->flags );
2218 dump_uint64( ", record=", &req->record );
2219 dump_uint64( ", address=", &req->address );
2220 fprintf( stderr, ", len=%u", req->len );
2221 dump_varargs_uints64( ", params=", min(cur_size,req->len) );
2222 dump_varargs_context( ", context=", cur_size );
2225 static void dump_queue_exception_event_reply( const struct queue_exception_event_reply *req )
2227 fprintf( stderr, " handle=%04x", req->handle );
2230 static void dump_get_exception_status_request( const struct get_exception_status_request *req )
2232 fprintf( stderr, " handle=%04x", req->handle );
2235 static void dump_get_exception_status_reply( const struct get_exception_status_reply *req )
2237 dump_varargs_context( " context=", cur_size );
2240 static void dump_continue_debug_event_request( const struct continue_debug_event_request *req )
2242 fprintf( stderr, " pid=%04x", req->pid );
2243 fprintf( stderr, ", tid=%04x", req->tid );
2244 fprintf( stderr, ", status=%d", req->status );
2247 static void dump_debug_process_request( const struct debug_process_request *req )
2249 fprintf( stderr, " pid=%04x", req->pid );
2250 fprintf( stderr, ", attach=%d", req->attach );
2253 static void dump_debug_break_request( const struct debug_break_request *req )
2255 fprintf( stderr, " handle=%04x", req->handle );
2258 static void dump_debug_break_reply( const struct debug_break_reply *req )
2260 fprintf( stderr, " self=%d", req->self );
2263 static void dump_set_debugger_kill_on_exit_request( const struct set_debugger_kill_on_exit_request *req )
2265 fprintf( stderr, " kill_on_exit=%d", req->kill_on_exit );
2268 static void dump_read_process_memory_request( const struct read_process_memory_request *req )
2270 fprintf( stderr, " handle=%04x", req->handle );
2271 dump_uint64( ", addr=", &req->addr );
2274 static void dump_read_process_memory_reply( const struct read_process_memory_reply *req )
2276 dump_varargs_bytes( " data=", cur_size );
2279 static void dump_write_process_memory_request( const struct write_process_memory_request *req )
2281 fprintf( stderr, " handle=%04x", req->handle );
2282 dump_uint64( ", addr=", &req->addr );
2283 dump_varargs_bytes( ", data=", cur_size );
2286 static void dump_create_key_request( const struct create_key_request *req )
2288 fprintf( stderr, " parent=%04x", req->parent );
2289 fprintf( stderr, ", access=%08x", req->access );
2290 fprintf( stderr, ", attributes=%08x", req->attributes );
2291 fprintf( stderr, ", options=%08x", req->options );
2292 fprintf( stderr, ", namelen=%u", req->namelen );
2293 dump_varargs_unicode_str( ", name=", min(cur_size,req->namelen) );
2294 dump_varargs_unicode_str( ", class=", cur_size );
2297 static void dump_create_key_reply( const struct create_key_reply *req )
2299 fprintf( stderr, " hkey=%04x", req->hkey );
2300 fprintf( stderr, ", created=%d", req->created );
2303 static void dump_open_key_request( const struct open_key_request *req )
2305 fprintf( stderr, " parent=%04x", req->parent );
2306 fprintf( stderr, ", access=%08x", req->access );
2307 fprintf( stderr, ", attributes=%08x", req->attributes );
2308 dump_varargs_unicode_str( ", name=", cur_size );
2311 static void dump_open_key_reply( const struct open_key_reply *req )
2313 fprintf( stderr, " hkey=%04x", req->hkey );
2316 static void dump_delete_key_request( const struct delete_key_request *req )
2318 fprintf( stderr, " hkey=%04x", req->hkey );
2321 static void dump_flush_key_request( const struct flush_key_request *req )
2323 fprintf( stderr, " hkey=%04x", req->hkey );
2326 static void dump_enum_key_request( const struct enum_key_request *req )
2328 fprintf( stderr, " hkey=%04x", req->hkey );
2329 fprintf( stderr, ", index=%d", req->index );
2330 fprintf( stderr, ", info_class=%d", req->info_class );
2333 static void dump_enum_key_reply( const struct enum_key_reply *req )
2335 fprintf( stderr, " subkeys=%d", req->subkeys );
2336 fprintf( stderr, ", max_subkey=%d", req->max_subkey );
2337 fprintf( stderr, ", max_class=%d", req->max_class );
2338 fprintf( stderr, ", values=%d", req->values );
2339 fprintf( stderr, ", max_value=%d", req->max_value );
2340 fprintf( stderr, ", max_data=%d", req->max_data );
2341 dump_timeout( ", modif=", &req->modif );
2342 fprintf( stderr, ", total=%u", req->total );
2343 fprintf( stderr, ", namelen=%u", req->namelen );
2344 dump_varargs_unicode_str( ", name=", min(cur_size,req->namelen) );
2345 dump_varargs_unicode_str( ", class=", cur_size );
2348 static void dump_set_key_value_request( const struct set_key_value_request *req )
2350 fprintf( stderr, " hkey=%04x", req->hkey );
2351 fprintf( stderr, ", type=%d", req->type );
2352 fprintf( stderr, ", namelen=%u", req->namelen );
2353 dump_varargs_unicode_str( ", name=", min(cur_size,req->namelen) );
2354 dump_varargs_bytes( ", data=", cur_size );
2357 static void dump_get_key_value_request( const struct get_key_value_request *req )
2359 fprintf( stderr, " hkey=%04x", req->hkey );
2360 dump_varargs_unicode_str( ", name=", cur_size );
2363 static void dump_get_key_value_reply( const struct get_key_value_reply *req )
2365 fprintf( stderr, " type=%d", req->type );
2366 fprintf( stderr, ", total=%u", req->total );
2367 dump_varargs_bytes( ", data=", cur_size );
2370 static void dump_enum_key_value_request( const struct enum_key_value_request *req )
2372 fprintf( stderr, " hkey=%04x", req->hkey );
2373 fprintf( stderr, ", index=%d", req->index );
2374 fprintf( stderr, ", info_class=%d", req->info_class );
2377 static void dump_enum_key_value_reply( const struct enum_key_value_reply *req )
2379 fprintf( stderr, " type=%d", req->type );
2380 fprintf( stderr, ", total=%u", req->total );
2381 fprintf( stderr, ", namelen=%u", req->namelen );
2382 dump_varargs_unicode_str( ", name=", min(cur_size,req->namelen) );
2383 dump_varargs_bytes( ", data=", cur_size );
2386 static void dump_delete_key_value_request( const struct delete_key_value_request *req )
2388 fprintf( stderr, " hkey=%04x", req->hkey );
2389 dump_varargs_unicode_str( ", name=", cur_size );
2392 static void dump_load_registry_request( const struct load_registry_request *req )
2394 fprintf( stderr, " hkey=%04x", req->hkey );
2395 fprintf( stderr, ", file=%04x", req->file );
2396 dump_varargs_unicode_str( ", name=", cur_size );
2399 static void dump_unload_registry_request( const struct unload_registry_request *req )
2401 fprintf( stderr, " hkey=%04x", req->hkey );
2404 static void dump_save_registry_request( const struct save_registry_request *req )
2406 fprintf( stderr, " hkey=%04x", req->hkey );
2407 fprintf( stderr, ", file=%04x", req->file );
2410 static void dump_set_registry_notification_request( const struct set_registry_notification_request *req )
2412 fprintf( stderr, " hkey=%04x", req->hkey );
2413 fprintf( stderr, ", event=%04x", req->event );
2414 fprintf( stderr, ", subtree=%d", req->subtree );
2415 fprintf( stderr, ", filter=%08x", req->filter );
2418 static void dump_create_timer_request( const struct create_timer_request *req )
2420 fprintf( stderr, " access=%08x", req->access );
2421 fprintf( stderr, ", attributes=%08x", req->attributes );
2422 fprintf( stderr, ", rootdir=%04x", req->rootdir );
2423 fprintf( stderr, ", manual=%d", req->manual );
2424 dump_varargs_unicode_str( ", name=", cur_size );
2427 static void dump_create_timer_reply( const struct create_timer_reply *req )
2429 fprintf( stderr, " handle=%04x", req->handle );
2432 static void dump_open_timer_request( const struct open_timer_request *req )
2434 fprintf( stderr, " access=%08x", req->access );
2435 fprintf( stderr, ", attributes=%08x", req->attributes );
2436 fprintf( stderr, ", rootdir=%04x", req->rootdir );
2437 dump_varargs_unicode_str( ", name=", cur_size );
2440 static void dump_open_timer_reply( const struct open_timer_reply *req )
2442 fprintf( stderr, " handle=%04x", req->handle );
2445 static void dump_set_timer_request( const struct set_timer_request *req )
2447 fprintf( stderr, " handle=%04x", req->handle );
2448 dump_timeout( ", expire=", &req->expire );
2449 dump_uint64( ", callback=", &req->callback );
2450 dump_uint64( ", arg=", &req->arg );
2451 fprintf( stderr, ", period=%d", req->period );
2454 static void dump_set_timer_reply( const struct set_timer_reply *req )
2456 fprintf( stderr, " signaled=%d", req->signaled );
2459 static void dump_cancel_timer_request( const struct cancel_timer_request *req )
2461 fprintf( stderr, " handle=%04x", req->handle );
2464 static void dump_cancel_timer_reply( const struct cancel_timer_reply *req )
2466 fprintf( stderr, " signaled=%d", req->signaled );
2469 static void dump_get_timer_info_request( const struct get_timer_info_request *req )
2471 fprintf( stderr, " handle=%04x", req->handle );
2474 static void dump_get_timer_info_reply( const struct get_timer_info_reply *req )
2476 dump_timeout( " when=", &req->when );
2477 fprintf( stderr, ", signaled=%d", req->signaled );
2480 static void dump_get_thread_context_request( const struct get_thread_context_request *req )
2482 fprintf( stderr, " handle=%04x", req->handle );
2483 fprintf( stderr, ", flags=%08x", req->flags );
2484 fprintf( stderr, ", suspend=%d", req->suspend );
2487 static void dump_get_thread_context_reply( const struct get_thread_context_reply *req )
2489 fprintf( stderr, " self=%d", req->self );
2490 dump_varargs_context( ", context=", cur_size );
2493 static void dump_set_thread_context_request( const struct set_thread_context_request *req )
2495 fprintf( stderr, " handle=%04x", req->handle );
2496 fprintf( stderr, ", suspend=%d", req->suspend );
2497 dump_varargs_context( ", context=", cur_size );
2500 static void dump_set_thread_context_reply( const struct set_thread_context_reply *req )
2502 fprintf( stderr, " self=%d", req->self );
2505 static void dump_get_selector_entry_request( const struct get_selector_entry_request *req )
2507 fprintf( stderr, " handle=%04x", req->handle );
2508 fprintf( stderr, ", entry=%d", req->entry );
2511 static void dump_get_selector_entry_reply( const struct get_selector_entry_reply *req )
2513 fprintf( stderr, " base=%08x", req->base );
2514 fprintf( stderr, ", limit=%08x", req->limit );
2515 fprintf( stderr, ", flags=%02x", req->flags );
2518 static void dump_add_atom_request( const struct add_atom_request *req )
2520 fprintf( stderr, " table=%04x", req->table );
2521 dump_varargs_unicode_str( ", name=", cur_size );
2524 static void dump_add_atom_reply( const struct add_atom_reply *req )
2526 fprintf( stderr, " atom=%04x", req->atom );
2529 static void dump_delete_atom_request( const struct delete_atom_request *req )
2531 fprintf( stderr, " table=%04x", req->table );
2532 fprintf( stderr, ", atom=%04x", req->atom );
2535 static void dump_find_atom_request( const struct find_atom_request *req )
2537 fprintf( stderr, " table=%04x", req->table );
2538 dump_varargs_unicode_str( ", name=", cur_size );
2541 static void dump_find_atom_reply( const struct find_atom_reply *req )
2543 fprintf( stderr, " atom=%04x", req->atom );
2546 static void dump_get_atom_information_request( const struct get_atom_information_request *req )
2548 fprintf( stderr, " table=%04x", req->table );
2549 fprintf( stderr, ", atom=%04x", req->atom );
2552 static void dump_get_atom_information_reply( const struct get_atom_information_reply *req )
2554 fprintf( stderr, " count=%d", req->count );
2555 fprintf( stderr, ", pinned=%d", req->pinned );
2556 fprintf( stderr, ", total=%u", req->total );
2557 dump_varargs_unicode_str( ", name=", cur_size );
2560 static void dump_set_atom_information_request( const struct set_atom_information_request *req )
2562 fprintf( stderr, " table=%04x", req->table );
2563 fprintf( stderr, ", atom=%04x", req->atom );
2564 fprintf( stderr, ", pinned=%d", req->pinned );
2567 static void dump_empty_atom_table_request( const struct empty_atom_table_request *req )
2569 fprintf( stderr, " table=%04x", req->table );
2570 fprintf( stderr, ", if_pinned=%d", req->if_pinned );
2573 static void dump_init_atom_table_request( const struct init_atom_table_request *req )
2575 fprintf( stderr, " entries=%d", req->entries );
2578 static void dump_init_atom_table_reply( const struct init_atom_table_reply *req )
2580 fprintf( stderr, " table=%04x", req->table );
2583 static void dump_get_msg_queue_request( const struct get_msg_queue_request *req )
2587 static void dump_get_msg_queue_reply( const struct get_msg_queue_reply *req )
2589 fprintf( stderr, " handle=%04x", req->handle );
2592 static void dump_set_queue_fd_request( const struct set_queue_fd_request *req )
2594 fprintf( stderr, " handle=%04x", req->handle );
2597 static void dump_set_queue_mask_request( const struct set_queue_mask_request *req )
2599 fprintf( stderr, " wake_mask=%08x", req->wake_mask );
2600 fprintf( stderr, ", changed_mask=%08x", req->changed_mask );
2601 fprintf( stderr, ", skip_wait=%d", req->skip_wait );
2604 static void dump_set_queue_mask_reply( const struct set_queue_mask_reply *req )
2606 fprintf( stderr, " wake_bits=%08x", req->wake_bits );
2607 fprintf( stderr, ", changed_bits=%08x", req->changed_bits );
2610 static void dump_get_queue_status_request( const struct get_queue_status_request *req )
2612 fprintf( stderr, " clear_bits=%08x", req->clear_bits );
2615 static void dump_get_queue_status_reply( const struct get_queue_status_reply *req )
2617 fprintf( stderr, " wake_bits=%08x", req->wake_bits );
2618 fprintf( stderr, ", changed_bits=%08x", req->changed_bits );
2621 static void dump_get_process_idle_event_request( const struct get_process_idle_event_request *req )
2623 fprintf( stderr, " handle=%04x", req->handle );
2626 static void dump_get_process_idle_event_reply( const struct get_process_idle_event_reply *req )
2628 fprintf( stderr, " event=%04x", req->event );
2631 static void dump_send_message_request( const struct send_message_request *req )
2633 fprintf( stderr, " id=%04x", req->id );
2634 fprintf( stderr, ", type=%d", req->type );
2635 fprintf( stderr, ", flags=%d", req->flags );
2636 fprintf( stderr, ", win=%08x", req->win );
2637 fprintf( stderr, ", msg=%08x", req->msg );
2638 dump_uint64( ", wparam=", &req->wparam );
2639 dump_uint64( ", lparam=", &req->lparam );
2640 dump_timeout( ", timeout=", &req->timeout );
2641 dump_varargs_message_data( ", data=", cur_size );
2644 static void dump_post_quit_message_request( const struct post_quit_message_request *req )
2646 fprintf( stderr, " exit_code=%d", req->exit_code );
2649 static void dump_send_hardware_message_request( const struct send_hardware_message_request *req )
2651 fprintf( stderr, " win=%08x", req->win );
2652 dump_hw_input( ", input=", &req->input );
2653 fprintf( stderr, ", flags=%08x", req->flags );
2656 static void dump_send_hardware_message_reply( const struct send_hardware_message_reply *req )
2658 fprintf( stderr, " wait=%d", req->wait );
2659 fprintf( stderr, ", prev_x=%d", req->prev_x );
2660 fprintf( stderr, ", prev_y=%d", req->prev_y );
2661 fprintf( stderr, ", new_x=%d", req->new_x );
2662 fprintf( stderr, ", new_y=%d", req->new_y );
2663 dump_varargs_bytes( ", keystate=", cur_size );
2666 static void dump_get_message_request( const struct get_message_request *req )
2668 fprintf( stderr, " flags=%08x", req->flags );
2669 fprintf( stderr, ", get_win=%08x", req->get_win );
2670 fprintf( stderr, ", get_first=%08x", req->get_first );
2671 fprintf( stderr, ", get_last=%08x", req->get_last );
2672 fprintf( stderr, ", hw_id=%08x", req->hw_id );
2673 fprintf( stderr, ", wake_mask=%08x", req->wake_mask );
2674 fprintf( stderr, ", changed_mask=%08x", req->changed_mask );
2677 static void dump_get_message_reply( const struct get_message_reply *req )
2679 fprintf( stderr, " win=%08x", req->win );
2680 fprintf( stderr, ", msg=%08x", req->msg );
2681 dump_uint64( ", wparam=", &req->wparam );
2682 dump_uint64( ", lparam=", &req->lparam );
2683 fprintf( stderr, ", type=%d", req->type );
2684 fprintf( stderr, ", x=%d", req->x );
2685 fprintf( stderr, ", y=%d", req->y );
2686 fprintf( stderr, ", time=%08x", req->time );
2687 fprintf( stderr, ", active_hooks=%08x", req->active_hooks );
2688 fprintf( stderr, ", total=%u", req->total );
2689 dump_varargs_message_data( ", data=", cur_size );
2692 static void dump_reply_message_request( const struct reply_message_request *req )
2694 fprintf( stderr, " remove=%d", req->remove );
2695 dump_uint64( ", result=", &req->result );
2696 dump_varargs_bytes( ", data=", cur_size );
2699 static void dump_accept_hardware_message_request( const struct accept_hardware_message_request *req )
2701 fprintf( stderr, " hw_id=%08x", req->hw_id );
2702 fprintf( stderr, ", remove=%d", req->remove );
2705 static void dump_get_message_reply_request( const struct get_message_reply_request *req )
2707 fprintf( stderr, " cancel=%d", req->cancel );
2710 static void dump_get_message_reply_reply( const struct get_message_reply_reply *req )
2712 dump_uint64( " result=", &req->result );
2713 dump_varargs_bytes( ", data=", cur_size );
2716 static void dump_set_win_timer_request( const struct set_win_timer_request *req )
2718 fprintf( stderr, " win=%08x", req->win );
2719 fprintf( stderr, ", msg=%08x", req->msg );
2720 fprintf( stderr, ", rate=%08x", req->rate );
2721 dump_uint64( ", id=", &req->id );
2722 dump_uint64( ", lparam=", &req->lparam );
2725 static void dump_set_win_timer_reply( const struct set_win_timer_reply *req )
2727 dump_uint64( " id=", &req->id );
2730 static void dump_kill_win_timer_request( const struct kill_win_timer_request *req )
2732 fprintf( stderr, " win=%08x", req->win );
2733 dump_uint64( ", id=", &req->id );
2734 fprintf( stderr, ", msg=%08x", req->msg );
2737 static void dump_is_window_hung_request( const struct is_window_hung_request *req )
2739 fprintf( stderr, " win=%08x", req->win );
2742 static void dump_is_window_hung_reply( const struct is_window_hung_reply *req )
2744 fprintf( stderr, " is_hung=%d", req->is_hung );
2747 static void dump_get_serial_info_request( const struct get_serial_info_request *req )
2749 fprintf( stderr, " handle=%04x", req->handle );
2750 fprintf( stderr, ", flags=%d", req->flags );
2753 static void dump_get_serial_info_reply( const struct get_serial_info_reply *req )
2755 fprintf( stderr, " readinterval=%08x", req->readinterval );
2756 fprintf( stderr, ", readconst=%08x", req->readconst );
2757 fprintf( stderr, ", readmult=%08x", req->readmult );
2758 fprintf( stderr, ", writeconst=%08x", req->writeconst );
2759 fprintf( stderr, ", writemult=%08x", req->writemult );
2760 fprintf( stderr, ", eventmask=%08x", req->eventmask );
2761 fprintf( stderr, ", cookie=%08x", req->cookie );
2762 fprintf( stderr, ", pending_write=%08x", req->pending_write );
2765 static void dump_set_serial_info_request( const struct set_serial_info_request *req )
2767 fprintf( stderr, " handle=%04x", req->handle );
2768 fprintf( stderr, ", flags=%d", req->flags );
2769 fprintf( stderr, ", readinterval=%08x", req->readinterval );
2770 fprintf( stderr, ", readconst=%08x", req->readconst );
2771 fprintf( stderr, ", readmult=%08x", req->readmult );
2772 fprintf( stderr, ", writeconst=%08x", req->writeconst );
2773 fprintf( stderr, ", writemult=%08x", req->writemult );
2774 fprintf( stderr, ", eventmask=%08x", req->eventmask );
2777 static void dump_register_async_request( const struct register_async_request *req )
2779 fprintf( stderr, " type=%d", req->type );
2780 dump_async_data( ", async=", &req->async );
2781 fprintf( stderr, ", count=%d", req->count );
2784 static void dump_cancel_async_request( const struct cancel_async_request *req )
2786 fprintf( stderr, " handle=%04x", req->handle );
2787 dump_uint64( ", iosb=", &req->iosb );
2788 fprintf( stderr, ", only_thread=%d", req->only_thread );
2791 static void dump_read_request( const struct read_request *req )
2793 fprintf( stderr, " blocking=%d", req->blocking );
2794 dump_async_data( ", async=", &req->async );
2795 dump_uint64( ", pos=", &req->pos );
2798 static void dump_read_reply( const struct read_reply *req )
2800 fprintf( stderr, " wait=%04x", req->wait );
2801 fprintf( stderr, ", options=%08x", req->options );
2802 dump_varargs_bytes( ", data=", cur_size );
2805 static void dump_write_request( const struct write_request *req )
2807 fprintf( stderr, " blocking=%d", req->blocking );
2808 dump_async_data( ", async=", &req->async );
2809 dump_uint64( ", pos=", &req->pos );
2810 dump_varargs_bytes( ", data=", cur_size );
2813 static void dump_write_reply( const struct write_reply *req )
2815 fprintf( stderr, " wait=%04x", req->wait );
2816 fprintf( stderr, ", options=%08x", req->options );
2817 fprintf( stderr, ", size=%u", req->size );
2820 static void dump_ioctl_request( const struct ioctl_request *req )
2822 dump_ioctl_code( " code=", &req->code );
2823 dump_async_data( ", async=", &req->async );
2824 fprintf( stderr, ", blocking=%d", req->blocking );
2825 dump_varargs_bytes( ", in_data=", cur_size );
2828 static void dump_ioctl_reply( const struct ioctl_reply *req )
2830 fprintf( stderr, " wait=%04x", req->wait );
2831 fprintf( stderr, ", options=%08x", req->options );
2832 dump_varargs_bytes( ", out_data=", cur_size );
2835 static void dump_set_irp_result_request( const struct set_irp_result_request *req )
2837 fprintf( stderr, " manager=%04x", req->manager );
2838 fprintf( stderr, ", handle=%04x", req->handle );
2839 fprintf( stderr, ", status=%08x", req->status );
2840 dump_uint64( ", file_ptr=", &req->file_ptr );
2841 fprintf( stderr, ", size=%u", req->size );
2842 dump_varargs_bytes( ", data=", cur_size );
2845 static void dump_get_irp_result_request( const struct get_irp_result_request *req )
2847 fprintf( stderr, " handle=%04x", req->handle );
2848 dump_uint64( ", user_arg=", &req->user_arg );
2851 static void dump_get_irp_result_reply( const struct get_irp_result_reply *req )
2853 fprintf( stderr, " size=%u", req->size );
2854 dump_varargs_bytes( ", out_data=", cur_size );
2857 static void dump_create_named_pipe_request( const struct create_named_pipe_request *req )
2859 fprintf( stderr, " access=%08x", req->access );
2860 fprintf( stderr, ", attributes=%08x", req->attributes );
2861 fprintf( stderr, ", options=%08x", req->options );
2862 fprintf( stderr, ", sharing=%08x", req->sharing );
2863 fprintf( stderr, ", maxinstances=%08x", req->maxinstances );
2864 fprintf( stderr, ", outsize=%08x", req->outsize );
2865 fprintf( stderr, ", insize=%08x", req->insize );
2866 dump_timeout( ", timeout=", &req->timeout );
2867 fprintf( stderr, ", flags=%08x", req->flags );
2868 dump_varargs_object_attributes( ", objattr=", cur_size );
2871 static void dump_create_named_pipe_reply( const struct create_named_pipe_reply *req )
2873 fprintf( stderr, " handle=%04x", req->handle );
2876 static void dump_get_named_pipe_info_request( const struct get_named_pipe_info_request *req )
2878 fprintf( stderr, " handle=%04x", req->handle );
2881 static void dump_get_named_pipe_info_reply( const struct get_named_pipe_info_reply *req )
2883 fprintf( stderr, " flags=%08x", req->flags );
2884 fprintf( stderr, ", sharing=%08x", req->sharing );
2885 fprintf( stderr, ", maxinstances=%08x", req->maxinstances );
2886 fprintf( stderr, ", instances=%08x", req->instances );
2887 fprintf( stderr, ", outsize=%08x", req->outsize );
2888 fprintf( stderr, ", insize=%08x", req->insize );
2891 static void dump_set_named_pipe_info_request( const struct set_named_pipe_info_request *req )
2893 fprintf( stderr, " handle=%04x", req->handle );
2894 fprintf( stderr, ", flags=%08x", req->flags );
2897 static void dump_create_window_request( const struct create_window_request *req )
2899 fprintf( stderr, " parent=%08x", req->parent );
2900 fprintf( stderr, ", owner=%08x", req->owner );
2901 fprintf( stderr, ", atom=%04x", req->atom );
2902 dump_uint64( ", instance=", &req->instance );
2903 dump_varargs_unicode_str( ", class=", cur_size );
2906 static void dump_create_window_reply( const struct create_window_reply *req )
2908 fprintf( stderr, " handle=%08x", req->handle );
2909 fprintf( stderr, ", parent=%08x", req->parent );
2910 fprintf( stderr, ", owner=%08x", req->owner );
2911 fprintf( stderr, ", extra=%d", req->extra );
2912 dump_uint64( ", class_ptr=", &req->class_ptr );
2915 static void dump_destroy_window_request( const struct destroy_window_request *req )
2917 fprintf( stderr, " handle=%08x", req->handle );
2920 static void dump_get_desktop_window_request( const struct get_desktop_window_request *req )
2922 fprintf( stderr, " force=%d", req->force );
2925 static void dump_get_desktop_window_reply( const struct get_desktop_window_reply *req )
2927 fprintf( stderr, " top_window=%08x", req->top_window );
2928 fprintf( stderr, ", msg_window=%08x", req->msg_window );
2931 static void dump_set_window_owner_request( const struct set_window_owner_request *req )
2933 fprintf( stderr, " handle=%08x", req->handle );
2934 fprintf( stderr, ", owner=%08x", req->owner );
2937 static void dump_set_window_owner_reply( const struct set_window_owner_reply *req )
2939 fprintf( stderr, " full_owner=%08x", req->full_owner );
2940 fprintf( stderr, ", prev_owner=%08x", req->prev_owner );
2943 static void dump_get_window_info_request( const struct get_window_info_request *req )
2945 fprintf( stderr, " handle=%08x", req->handle );
2948 static void dump_get_window_info_reply( const struct get_window_info_reply *req )
2950 fprintf( stderr, " full_handle=%08x", req->full_handle );
2951 fprintf( stderr, ", last_active=%08x", req->last_active );
2952 fprintf( stderr, ", pid=%04x", req->pid );
2953 fprintf( stderr, ", tid=%04x", req->tid );
2954 fprintf( stderr, ", atom=%04x", req->atom );
2955 fprintf( stderr, ", is_unicode=%d", req->is_unicode );
2958 static void dump_set_window_info_request( const struct set_window_info_request *req )
2960 fprintf( stderr, " flags=%04x", req->flags );
2961 fprintf( stderr, ", is_unicode=%d", req->is_unicode );
2962 fprintf( stderr, ", handle=%08x", req->handle );
2963 fprintf( stderr, ", style=%08x", req->style );
2964 fprintf( stderr, ", ex_style=%08x", req->ex_style );
2965 fprintf( stderr, ", id=%08x", req->id );
2966 dump_uint64( ", instance=", &req->instance );
2967 dump_uint64( ", user_data=", &req->user_data );
2968 fprintf( stderr, ", extra_offset=%d", req->extra_offset );
2969 fprintf( stderr, ", extra_size=%u", req->extra_size );
2970 dump_uint64( ", extra_value=", &req->extra_value );
2973 static void dump_set_window_info_reply( const struct set_window_info_reply *req )
2975 fprintf( stderr, " old_style=%08x", req->old_style );
2976 fprintf( stderr, ", old_ex_style=%08x", req->old_ex_style );
2977 dump_uint64( ", old_instance=", &req->old_instance );
2978 dump_uint64( ", old_user_data=", &req->old_user_data );
2979 dump_uint64( ", old_extra_value=", &req->old_extra_value );
2980 fprintf( stderr, ", old_id=%08x", req->old_id );
2983 static void dump_set_parent_request( const struct set_parent_request *req )
2985 fprintf( stderr, " handle=%08x", req->handle );
2986 fprintf( stderr, ", parent=%08x", req->parent );
2989 static void dump_set_parent_reply( const struct set_parent_reply *req )
2991 fprintf( stderr, " old_parent=%08x", req->old_parent );
2992 fprintf( stderr, ", full_parent=%08x", req->full_parent );
2995 static void dump_get_window_parents_request( const struct get_window_parents_request *req )
2997 fprintf( stderr, " handle=%08x", req->handle );
3000 static void dump_get_window_parents_reply( const struct get_window_parents_reply *req )
3002 fprintf( stderr, " count=%d", req->count );
3003 dump_varargs_user_handles( ", parents=", cur_size );
3006 static void dump_get_window_children_request( const struct get_window_children_request *req )
3008 fprintf( stderr, " desktop=%04x", req->desktop );
3009 fprintf( stderr, ", parent=%08x", req->parent );
3010 fprintf( stderr, ", atom=%04x", req->atom );
3011 fprintf( stderr, ", tid=%04x", req->tid );
3012 dump_varargs_unicode_str( ", class=", cur_size );
3015 static void dump_get_window_children_reply( const struct get_window_children_reply *req )
3017 fprintf( stderr, " count=%d", req->count );
3018 dump_varargs_user_handles( ", children=", cur_size );
3021 static void dump_get_window_children_from_point_request( const struct get_window_children_from_point_request *req )
3023 fprintf( stderr, " parent=%08x", req->parent );
3024 fprintf( stderr, ", x=%d", req->x );
3025 fprintf( stderr, ", y=%d", req->y );
3028 static void dump_get_window_children_from_point_reply( const struct get_window_children_from_point_reply *req )
3030 fprintf( stderr, " count=%d", req->count );
3031 dump_varargs_user_handles( ", children=", cur_size );
3034 static void dump_get_window_tree_request( const struct get_window_tree_request *req )
3036 fprintf( stderr, " handle=%08x", req->handle );
3039 static void dump_get_window_tree_reply( const struct get_window_tree_reply *req )
3041 fprintf( stderr, " parent=%08x", req->parent );
3042 fprintf( stderr, ", owner=%08x", req->owner );
3043 fprintf( stderr, ", next_sibling=%08x", req->next_sibling );
3044 fprintf( stderr, ", prev_sibling=%08x", req->prev_sibling );
3045 fprintf( stderr, ", first_sibling=%08x", req->first_sibling );
3046 fprintf( stderr, ", last_sibling=%08x", req->last_sibling );
3047 fprintf( stderr, ", first_child=%08x", req->first_child );
3048 fprintf( stderr, ", last_child=%08x", req->last_child );
3051 static void dump_set_window_pos_request( const struct set_window_pos_request *req )
3053 fprintf( stderr, " swp_flags=%04x", req->swp_flags );
3054 fprintf( stderr, ", paint_flags=%04x", req->paint_flags );
3055 fprintf( stderr, ", handle=%08x", req->handle );
3056 fprintf( stderr, ", previous=%08x", req->previous );
3057 dump_rectangle( ", window=", &req->window );
3058 dump_rectangle( ", client=", &req->client );
3059 dump_varargs_rectangles( ", valid=", cur_size );
3062 static void dump_set_window_pos_reply( const struct set_window_pos_reply *req )
3064 fprintf( stderr, " new_style=%08x", req->new_style );
3065 fprintf( stderr, ", new_ex_style=%08x", req->new_ex_style );
3066 fprintf( stderr, ", surface_win=%08x", req->surface_win );
3069 static void dump_get_window_rectangles_request( const struct get_window_rectangles_request *req )
3071 fprintf( stderr, " handle=%08x", req->handle );
3072 fprintf( stderr, ", relative=%d", req->relative );
3075 static void dump_get_window_rectangles_reply( const struct get_window_rectangles_reply *req )
3077 dump_rectangle( " window=", &req->window );
3078 dump_rectangle( ", visible=", &req->visible );
3079 dump_rectangle( ", client=", &req->client );
3082 static void dump_get_window_text_request( const struct get_window_text_request *req )
3084 fprintf( stderr, " handle=%08x", req->handle );
3087 static void dump_get_window_text_reply( const struct get_window_text_reply *req )
3089 dump_varargs_unicode_str( " text=", cur_size );
3092 static void dump_set_window_text_request( const struct set_window_text_request *req )
3094 fprintf( stderr, " handle=%08x", req->handle );
3095 dump_varargs_unicode_str( ", text=", cur_size );
3098 static void dump_get_windows_offset_request( const struct get_windows_offset_request *req )
3100 fprintf( stderr, " from=%08x", req->from );
3101 fprintf( stderr, ", to=%08x", req->to );
3104 static void dump_get_windows_offset_reply( const struct get_windows_offset_reply *req )
3106 fprintf( stderr, " x=%d", req->x );
3107 fprintf( stderr, ", y=%d", req->y );
3108 fprintf( stderr, ", mirror=%d", req->mirror );
3111 static void dump_get_visible_region_request( const struct get_visible_region_request *req )
3113 fprintf( stderr, " window=%08x", req->window );
3114 fprintf( stderr, ", flags=%08x", req->flags );
3117 static void dump_get_visible_region_reply( const struct get_visible_region_reply *req )
3119 fprintf( stderr, " top_win=%08x", req->top_win );
3120 dump_rectangle( ", top_rect=", &req->top_rect );
3121 dump_rectangle( ", win_rect=", &req->win_rect );
3122 fprintf( stderr, ", paint_flags=%08x", req->paint_flags );
3123 fprintf( stderr, ", total_size=%u", req->total_size );
3124 dump_varargs_rectangles( ", region=", cur_size );
3127 static void dump_get_surface_region_request( const struct get_surface_region_request *req )
3129 fprintf( stderr, " window=%08x", req->window );
3132 static void dump_get_surface_region_reply( const struct get_surface_region_reply *req )
3134 dump_rectangle( " visible_rect=", &req->visible_rect );
3135 fprintf( stderr, ", total_size=%u", req->total_size );
3136 dump_varargs_rectangles( ", region=", cur_size );
3139 static void dump_get_window_region_request( const struct get_window_region_request *req )
3141 fprintf( stderr, " window=%08x", req->window );
3144 static void dump_get_window_region_reply( const struct get_window_region_reply *req )
3146 fprintf( stderr, " total_size=%u", req->total_size );
3147 dump_varargs_rectangles( ", region=", cur_size );
3150 static void dump_set_window_region_request( const struct set_window_region_request *req )
3152 fprintf( stderr, " window=%08x", req->window );
3153 fprintf( stderr, ", redraw=%d", req->redraw );
3154 dump_varargs_rectangles( ", region=", cur_size );
3157 static void dump_get_update_region_request( const struct get_update_region_request *req )
3159 fprintf( stderr, " window=%08x", req->window );
3160 fprintf( stderr, ", from_child=%08x", req->from_child );
3161 fprintf( stderr, ", flags=%08x", req->flags );
3164 static void dump_get_update_region_reply( const struct get_update_region_reply *req )
3166 fprintf( stderr, " child=%08x", req->child );
3167 fprintf( stderr, ", flags=%08x", req->flags );
3168 fprintf( stderr, ", total_size=%u", req->total_size );
3169 dump_varargs_rectangles( ", region=", cur_size );
3172 static void dump_update_window_zorder_request( const struct update_window_zorder_request *req )
3174 fprintf( stderr, " window=%08x", req->window );
3175 dump_rectangle( ", rect=", &req->rect );
3178 static void dump_redraw_window_request( const struct redraw_window_request *req )
3180 fprintf( stderr, " window=%08x", req->window );
3181 fprintf( stderr, ", flags=%08x", req->flags );
3182 dump_varargs_rectangles( ", region=", cur_size );
3185 static void dump_set_window_property_request( const struct set_window_property_request *req )
3187 fprintf( stderr, " window=%08x", req->window );
3188 dump_uint64( ", data=", &req->data );
3189 fprintf( stderr, ", atom=%04x", req->atom );
3190 dump_varargs_unicode_str( ", name=", cur_size );
3193 static void dump_remove_window_property_request( const struct remove_window_property_request *req )
3195 fprintf( stderr, " window=%08x", req->window );
3196 fprintf( stderr, ", atom=%04x", req->atom );
3197 dump_varargs_unicode_str( ", name=", cur_size );
3200 static void dump_remove_window_property_reply( const struct remove_window_property_reply *req )
3202 dump_uint64( " data=", &req->data );
3205 static void dump_get_window_property_request( const struct get_window_property_request *req )
3207 fprintf( stderr, " window=%08x", req->window );
3208 fprintf( stderr, ", atom=%04x", req->atom );
3209 dump_varargs_unicode_str( ", name=", cur_size );
3212 static void dump_get_window_property_reply( const struct get_window_property_reply *req )
3214 dump_uint64( " data=", &req->data );
3217 static void dump_get_window_properties_request( const struct get_window_properties_request *req )
3219 fprintf( stderr, " window=%08x", req->window );
3222 static void dump_get_window_properties_reply( const struct get_window_properties_reply *req )
3224 fprintf( stderr, " total=%d", req->total );
3225 dump_varargs_properties( ", props=", cur_size );
3228 static void dump_create_winstation_request( const struct create_winstation_request *req )
3230 fprintf( stderr, " flags=%08x", req->flags );
3231 fprintf( stderr, ", access=%08x", req->access );
3232 fprintf( stderr, ", attributes=%08x", req->attributes );
3233 dump_varargs_unicode_str( ", name=", cur_size );
3236 static void dump_create_winstation_reply( const struct create_winstation_reply *req )
3238 fprintf( stderr, " handle=%04x", req->handle );
3241 static void dump_open_winstation_request( const struct open_winstation_request *req )
3243 fprintf( stderr, " access=%08x", req->access );
3244 fprintf( stderr, ", attributes=%08x", req->attributes );
3245 dump_varargs_unicode_str( ", name=", cur_size );
3248 static void dump_open_winstation_reply( const struct open_winstation_reply *req )
3250 fprintf( stderr, " handle=%04x", req->handle );
3253 static void dump_close_winstation_request( const struct close_winstation_request *req )
3255 fprintf( stderr, " handle=%04x", req->handle );
3258 static void dump_get_process_winstation_request( const struct get_process_winstation_request *req )
3262 static void dump_get_process_winstation_reply( const struct get_process_winstation_reply *req )
3264 fprintf( stderr, " handle=%04x", req->handle );
3267 static void dump_set_process_winstation_request( const struct set_process_winstation_request *req )
3269 fprintf( stderr, " handle=%04x", req->handle );
3272 static void dump_enum_winstation_request( const struct enum_winstation_request *req )
3274 fprintf( stderr, " index=%08x", req->index );
3277 static void dump_enum_winstation_reply( const struct enum_winstation_reply *req )
3279 fprintf( stderr, " next=%08x", req->next );
3280 dump_varargs_unicode_str( ", name=", cur_size );
3283 static void dump_create_desktop_request( const struct create_desktop_request *req )
3285 fprintf( stderr, " flags=%08x", req->flags );
3286 fprintf( stderr, ", access=%08x", req->access );
3287 fprintf( stderr, ", attributes=%08x", req->attributes );
3288 dump_varargs_unicode_str( ", name=", cur_size );
3291 static void dump_create_desktop_reply( const struct create_desktop_reply *req )
3293 fprintf( stderr, " handle=%04x", req->handle );
3296 static void dump_open_desktop_request( const struct open_desktop_request *req )
3298 fprintf( stderr, " winsta=%04x", req->winsta );
3299 fprintf( stderr, ", flags=%08x", req->flags );
3300 fprintf( stderr, ", access=%08x", req->access );
3301 fprintf( stderr, ", attributes=%08x", req->attributes );
3302 dump_varargs_unicode_str( ", name=", cur_size );
3305 static void dump_open_desktop_reply( const struct open_desktop_reply *req )
3307 fprintf( stderr, " handle=%04x", req->handle );
3310 static void dump_open_input_desktop_request( const struct open_input_desktop_request *req )
3312 fprintf( stderr, " flags=%08x", req->flags );
3313 fprintf( stderr, ", access=%08x", req->access );
3314 fprintf( stderr, ", attributes=%08x", req->attributes );
3317 static void dump_open_input_desktop_reply( const struct open_input_desktop_reply *req )
3319 fprintf( stderr, " handle=%04x", req->handle );
3322 static void dump_close_desktop_request( const struct close_desktop_request *req )
3324 fprintf( stderr, " handle=%04x", req->handle );
3327 static void dump_get_thread_desktop_request( const struct get_thread_desktop_request *req )
3329 fprintf( stderr, " tid=%04x", req->tid );
3332 static void dump_get_thread_desktop_reply( const struct get_thread_desktop_reply *req )
3334 fprintf( stderr, " handle=%04x", req->handle );
3337 static void dump_set_thread_desktop_request( const struct set_thread_desktop_request *req )
3339 fprintf( stderr, " handle=%04x", req->handle );
3342 static void dump_enum_desktop_request( const struct enum_desktop_request *req )
3344 fprintf( stderr, " winstation=%04x", req->winstation );
3345 fprintf( stderr, ", index=%08x", req->index );
3348 static void dump_enum_desktop_reply( const struct enum_desktop_reply *req )
3350 fprintf( stderr, " next=%08x", req->next );
3351 dump_varargs_unicode_str( ", name=", cur_size );
3354 static void dump_set_user_object_info_request( const struct set_user_object_info_request *req )
3356 fprintf( stderr, " handle=%04x", req->handle );
3357 fprintf( stderr, ", flags=%08x", req->flags );
3358 fprintf( stderr, ", obj_flags=%08x", req->obj_flags );
3361 static void dump_set_user_object_info_reply( const struct set_user_object_info_reply *req )
3363 fprintf( stderr, " is_desktop=%d", req->is_desktop );
3364 fprintf( stderr, ", old_obj_flags=%08x", req->old_obj_flags );
3365 dump_varargs_unicode_str( ", name=", cur_size );
3368 static void dump_register_hotkey_request( const struct register_hotkey_request *req )
3370 fprintf( stderr, " window=%08x", req->window );
3371 fprintf( stderr, ", id=%d", req->id );
3372 fprintf( stderr, ", flags=%08x", req->flags );
3373 fprintf( stderr, ", vkey=%08x", req->vkey );
3376 static void dump_register_hotkey_reply( const struct register_hotkey_reply *req )
3378 fprintf( stderr, " replaced=%d", req->replaced );
3379 fprintf( stderr, ", flags=%08x", req->flags );
3380 fprintf( stderr, ", vkey=%08x", req->vkey );
3383 static void dump_unregister_hotkey_request( const struct unregister_hotkey_request *req )
3385 fprintf( stderr, " window=%08x", req->window );
3386 fprintf( stderr, ", id=%d", req->id );
3389 static void dump_unregister_hotkey_reply( const struct unregister_hotkey_reply *req )
3391 fprintf( stderr, " flags=%08x", req->flags );
3392 fprintf( stderr, ", vkey=%08x", req->vkey );
3395 static void dump_attach_thread_input_request( const struct attach_thread_input_request *req )
3397 fprintf( stderr, " tid_from=%04x", req->tid_from );
3398 fprintf( stderr, ", tid_to=%04x", req->tid_to );
3399 fprintf( stderr, ", attach=%d", req->attach );
3402 static void dump_get_thread_input_request( const struct get_thread_input_request *req )
3404 fprintf( stderr, " tid=%04x", req->tid );
3407 static void dump_get_thread_input_reply( const struct get_thread_input_reply *req )
3409 fprintf( stderr, " focus=%08x", req->focus );
3410 fprintf( stderr, ", capture=%08x", req->capture );
3411 fprintf( stderr, ", active=%08x", req->active );
3412 fprintf( stderr, ", foreground=%08x", req->foreground );
3413 fprintf( stderr, ", menu_owner=%08x", req->menu_owner );
3414 fprintf( stderr, ", move_size=%08x", req->move_size );
3415 fprintf( stderr, ", caret=%08x", req->caret );
3416 fprintf( stderr, ", cursor=%08x", req->cursor );
3417 fprintf( stderr, ", show_count=%d", req->show_count );
3418 dump_rectangle( ", rect=", &req->rect );
3421 static void dump_get_last_input_time_request( const struct get_last_input_time_request *req )
3425 static void dump_get_last_input_time_reply( const struct get_last_input_time_reply *req )
3427 fprintf( stderr, " time=%08x", req->time );
3430 static void dump_get_key_state_request( const struct get_key_state_request *req )
3432 fprintf( stderr, " tid=%04x", req->tid );
3433 fprintf( stderr, ", key=%d", req->key );
3436 static void dump_get_key_state_reply( const struct get_key_state_reply *req )
3438 fprintf( stderr, " state=%02x", req->state );
3439 dump_varargs_bytes( ", keystate=", cur_size );
3442 static void dump_set_key_state_request( const struct set_key_state_request *req )
3444 fprintf( stderr, " tid=%04x", req->tid );
3445 fprintf( stderr, ", async=%d", req->async );
3446 dump_varargs_bytes( ", keystate=", cur_size );
3449 static void dump_set_foreground_window_request( const struct set_foreground_window_request *req )
3451 fprintf( stderr, " handle=%08x", req->handle );
3454 static void dump_set_foreground_window_reply( const struct set_foreground_window_reply *req )
3456 fprintf( stderr, " previous=%08x", req->previous );
3457 fprintf( stderr, ", send_msg_old=%d", req->send_msg_old );
3458 fprintf( stderr, ", send_msg_new=%d", req->send_msg_new );
3461 static void dump_set_focus_window_request( const struct set_focus_window_request *req )
3463 fprintf( stderr, " handle=%08x", req->handle );
3466 static void dump_set_focus_window_reply( const struct set_focus_window_reply *req )
3468 fprintf( stderr, " previous=%08x", req->previous );
3471 static void dump_set_active_window_request( const struct set_active_window_request *req )
3473 fprintf( stderr, " handle=%08x", req->handle );
3476 static void dump_set_active_window_reply( const struct set_active_window_reply *req )
3478 fprintf( stderr, " previous=%08x", req->previous );
3481 static void dump_set_capture_window_request( const struct set_capture_window_request *req )
3483 fprintf( stderr, " handle=%08x", req->handle );
3484 fprintf( stderr, ", flags=%08x", req->flags );
3487 static void dump_set_capture_window_reply( const struct set_capture_window_reply *req )
3489 fprintf( stderr, " previous=%08x", req->previous );
3490 fprintf( stderr, ", full_handle=%08x", req->full_handle );
3493 static void dump_set_caret_window_request( const struct set_caret_window_request *req )
3495 fprintf( stderr, " handle=%08x", req->handle );
3496 fprintf( stderr, ", width=%d", req->width );
3497 fprintf( stderr, ", height=%d", req->height );
3500 static void dump_set_caret_window_reply( const struct set_caret_window_reply *req )
3502 fprintf( stderr, " previous=%08x", req->previous );
3503 dump_rectangle( ", old_rect=", &req->old_rect );
3504 fprintf( stderr, ", old_hide=%d", req->old_hide );
3505 fprintf( stderr, ", old_state=%d", req->old_state );
3508 static void dump_set_caret_info_request( const struct set_caret_info_request *req )
3510 fprintf( stderr, " flags=%08x", req->flags );
3511 fprintf( stderr, ", handle=%08x", req->handle );
3512 fprintf( stderr, ", x=%d", req->x );
3513 fprintf( stderr, ", y=%d", req->y );
3514 fprintf( stderr, ", hide=%d", req->hide );
3515 fprintf( stderr, ", state=%d", req->state );
3518 static void dump_set_caret_info_reply( const struct set_caret_info_reply *req )
3520 fprintf( stderr, " full_handle=%08x", req->full_handle );
3521 dump_rectangle( ", old_rect=", &req->old_rect );
3522 fprintf( stderr, ", old_hide=%d", req->old_hide );
3523 fprintf( stderr, ", old_state=%d", req->old_state );
3526 static void dump_set_hook_request( const struct set_hook_request *req )
3528 fprintf( stderr, " id=%d", req->id );
3529 fprintf( stderr, ", pid=%04x", req->pid );
3530 fprintf( stderr, ", tid=%04x", req->tid );
3531 fprintf( stderr, ", event_min=%d", req->event_min );
3532 fprintf( stderr, ", event_max=%d", req->event_max );
3533 dump_uint64( ", proc=", &req->proc );
3534 fprintf( stderr, ", flags=%d", req->flags );
3535 fprintf( stderr, ", unicode=%d", req->unicode );
3536 dump_varargs_unicode_str( ", module=", cur_size );
3539 static void dump_set_hook_reply( const struct set_hook_reply *req )
3541 fprintf( stderr, " handle=%08x", req->handle );
3542 fprintf( stderr, ", active_hooks=%08x", req->active_hooks );
3545 static void dump_remove_hook_request( const struct remove_hook_request *req )
3547 fprintf( stderr, " handle=%08x", req->handle );
3548 dump_uint64( ", proc=", &req->proc );
3549 fprintf( stderr, ", id=%d", req->id );
3552 static void dump_remove_hook_reply( const struct remove_hook_reply *req )
3554 fprintf( stderr, " active_hooks=%08x", req->active_hooks );
3557 static void dump_start_hook_chain_request( const struct start_hook_chain_request *req )
3559 fprintf( stderr, " id=%d", req->id );
3560 fprintf( stderr, ", event=%d", req->event );
3561 fprintf( stderr, ", window=%08x", req->window );
3562 fprintf( stderr, ", object_id=%d", req->object_id );
3563 fprintf( stderr, ", child_id=%d", req->child_id );
3566 static void dump_start_hook_chain_reply( const struct start_hook_chain_reply *req )
3568 fprintf( stderr, " handle=%08x", req->handle );
3569 fprintf( stderr, ", pid=%04x", req->pid );
3570 fprintf( stderr, ", tid=%04x", req->tid );
3571 fprintf( stderr, ", unicode=%d", req->unicode );
3572 dump_uint64( ", proc=", &req->proc );
3573 fprintf( stderr, ", active_hooks=%08x", req->active_hooks );
3574 dump_varargs_unicode_str( ", module=", cur_size );
3577 static void dump_finish_hook_chain_request( const struct finish_hook_chain_request *req )
3579 fprintf( stderr, " id=%d", req->id );
3582 static void dump_get_hook_info_request( const struct get_hook_info_request *req )
3584 fprintf( stderr, " handle=%08x", req->handle );
3585 fprintf( stderr, ", get_next=%d", req->get_next );
3586 fprintf( stderr, ", event=%d", req->event );
3587 fprintf( stderr, ", window=%08x", req->window );
3588 fprintf( stderr, ", object_id=%d", req->object_id );
3589 fprintf( stderr, ", child_id=%d", req->child_id );
3592 static void dump_get_hook_info_reply( const struct get_hook_info_reply *req )
3594 fprintf( stderr, " handle=%08x", req->handle );
3595 fprintf( stderr, ", id=%d", req->id );
3596 fprintf( stderr, ", pid=%04x", req->pid );
3597 fprintf( stderr, ", tid=%04x", req->tid );
3598 dump_uint64( ", proc=", &req->proc );
3599 fprintf( stderr, ", unicode=%d", req->unicode );
3600 dump_varargs_unicode_str( ", module=", cur_size );
3603 static void dump_create_class_request( const struct create_class_request *req )
3605 fprintf( stderr, " local=%d", req->local );
3606 fprintf( stderr, ", atom=%04x", req->atom );
3607 fprintf( stderr, ", style=%08x", req->style );
3608 dump_uint64( ", instance=", &req->instance );
3609 fprintf( stderr, ", extra=%d", req->extra );
3610 fprintf( stderr, ", win_extra=%d", req->win_extra );
3611 dump_uint64( ", client_ptr=", &req->client_ptr );
3612 dump_varargs_unicode_str( ", name=", cur_size );
3615 static void dump_create_class_reply( const struct create_class_reply *req )
3617 fprintf( stderr, " atom=%04x", req->atom );
3620 static void dump_destroy_class_request( const struct destroy_class_request *req )
3622 fprintf( stderr, " atom=%04x", req->atom );
3623 dump_uint64( ", instance=", &req->instance );
3624 dump_varargs_unicode_str( ", name=", cur_size );
3627 static void dump_destroy_class_reply( const struct destroy_class_reply *req )
3629 dump_uint64( " client_ptr=", &req->client_ptr );
3632 static void dump_set_class_info_request( const struct set_class_info_request *req )
3634 fprintf( stderr, " window=%08x", req->window );
3635 fprintf( stderr, ", flags=%08x", req->flags );
3636 fprintf( stderr, ", atom=%04x", req->atom );
3637 fprintf( stderr, ", style=%08x", req->style );
3638 fprintf( stderr, ", win_extra=%d", req->win_extra );
3639 dump_uint64( ", instance=", &req->instance );
3640 fprintf( stderr, ", extra_offset=%d", req->extra_offset );
3641 fprintf( stderr, ", extra_size=%u", req->extra_size );
3642 dump_uint64( ", extra_value=", &req->extra_value );
3645 static void dump_set_class_info_reply( const struct set_class_info_reply *req )
3647 fprintf( stderr, " old_atom=%04x", req->old_atom );
3648 fprintf( stderr, ", old_style=%08x", req->old_style );
3649 fprintf( stderr, ", old_extra=%d", req->old_extra );
3650 fprintf( stderr, ", old_win_extra=%d", req->old_win_extra );
3651 dump_uint64( ", old_instance=", &req->old_instance );
3652 dump_uint64( ", old_extra_value=", &req->old_extra_value );
3655 static void dump_set_clipboard_info_request( const struct set_clipboard_info_request *req )
3657 fprintf( stderr, " flags=%08x", req->flags );
3658 fprintf( stderr, ", clipboard=%08x", req->clipboard );
3659 fprintf( stderr, ", owner=%08x", req->owner );
3660 fprintf( stderr, ", viewer=%08x", req->viewer );
3661 fprintf( stderr, ", seqno=%08x", req->seqno );
3664 static void dump_set_clipboard_info_reply( const struct set_clipboard_info_reply *req )
3666 fprintf( stderr, " flags=%08x", req->flags );
3667 fprintf( stderr, ", old_clipboard=%08x", req->old_clipboard );
3668 fprintf( stderr, ", old_owner=%08x", req->old_owner );
3669 fprintf( stderr, ", old_viewer=%08x", req->old_viewer );
3670 fprintf( stderr, ", seqno=%08x", req->seqno );
3673 static void dump_empty_clipboard_request( const struct empty_clipboard_request *req )
3677 static void dump_open_token_request( const struct open_token_request *req )
3679 fprintf( stderr, " handle=%04x", req->handle );
3680 fprintf( stderr, ", access=%08x", req->access );
3681 fprintf( stderr, ", attributes=%08x", req->attributes );
3682 fprintf( stderr, ", flags=%08x", req->flags );
3685 static void dump_open_token_reply( const struct open_token_reply *req )
3687 fprintf( stderr, " token=%04x", req->token );
3690 static void dump_set_global_windows_request( const struct set_global_windows_request *req )
3692 fprintf( stderr, " flags=%08x", req->flags );
3693 fprintf( stderr, ", shell_window=%08x", req->shell_window );
3694 fprintf( stderr, ", shell_listview=%08x", req->shell_listview );
3695 fprintf( stderr, ", progman_window=%08x", req->progman_window );
3696 fprintf( stderr, ", taskman_window=%08x", req->taskman_window );
3699 static void dump_set_global_windows_reply( const struct set_global_windows_reply *req )
3701 fprintf( stderr, " old_shell_window=%08x", req->old_shell_window );
3702 fprintf( stderr, ", old_shell_listview=%08x", req->old_shell_listview );
3703 fprintf( stderr, ", old_progman_window=%08x", req->old_progman_window );
3704 fprintf( stderr, ", old_taskman_window=%08x", req->old_taskman_window );
3707 static void dump_adjust_token_privileges_request( const struct adjust_token_privileges_request *req )
3709 fprintf( stderr, " handle=%04x", req->handle );
3710 fprintf( stderr, ", disable_all=%d", req->disable_all );
3711 fprintf( stderr, ", get_modified_state=%d", req->get_modified_state );
3712 dump_varargs_LUID_AND_ATTRIBUTES( ", privileges=", cur_size );
3715 static void dump_adjust_token_privileges_reply( const struct adjust_token_privileges_reply *req )
3717 fprintf( stderr, " len=%08x", req->len );
3718 dump_varargs_LUID_AND_ATTRIBUTES( ", privileges=", cur_size );
3721 static void dump_get_token_privileges_request( const struct get_token_privileges_request *req )
3723 fprintf( stderr, " handle=%04x", req->handle );
3726 static void dump_get_token_privileges_reply( const struct get_token_privileges_reply *req )
3728 fprintf( stderr, " len=%08x", req->len );
3729 dump_varargs_LUID_AND_ATTRIBUTES( ", privileges=", cur_size );
3732 static void dump_check_token_privileges_request( const struct check_token_privileges_request *req )
3734 fprintf( stderr, " handle=%04x", req->handle );
3735 fprintf( stderr, ", all_required=%d", req->all_required );
3736 dump_varargs_LUID_AND_ATTRIBUTES( ", privileges=", cur_size );
3739 static void dump_check_token_privileges_reply( const struct check_token_privileges_reply *req )
3741 fprintf( stderr, " has_privileges=%d", req->has_privileges );
3742 dump_varargs_LUID_AND_ATTRIBUTES( ", privileges=", cur_size );
3745 static void dump_duplicate_token_request( const struct duplicate_token_request *req )
3747 fprintf( stderr, " handle=%04x", req->handle );
3748 fprintf( stderr, ", access=%08x", req->access );
3749 fprintf( stderr, ", attributes=%08x", req->attributes );
3750 fprintf( stderr, ", primary=%d", req->primary );
3751 fprintf( stderr, ", impersonation_level=%d", req->impersonation_level );
3754 static void dump_duplicate_token_reply( const struct duplicate_token_reply *req )
3756 fprintf( stderr, " new_handle=%04x", req->new_handle );
3759 static void dump_access_check_request( const struct access_check_request *req )
3761 fprintf( stderr, " handle=%04x", req->handle );
3762 fprintf( stderr, ", desired_access=%08x", req->desired_access );
3763 fprintf( stderr, ", mapping_read=%08x", req->mapping_read );
3764 fprintf( stderr, ", mapping_write=%08x", req->mapping_write );
3765 fprintf( stderr, ", mapping_execute=%08x", req->mapping_execute );
3766 fprintf( stderr, ", mapping_all=%08x", req->mapping_all );
3767 dump_varargs_security_descriptor( ", sd=", cur_size );
3770 static void dump_access_check_reply( const struct access_check_reply *req )
3772 fprintf( stderr, " access_granted=%08x", req->access_granted );
3773 fprintf( stderr, ", access_status=%08x", req->access_status );
3774 fprintf( stderr, ", privileges_len=%08x", req->privileges_len );
3775 dump_varargs_LUID_AND_ATTRIBUTES( ", privileges=", cur_size );
3778 static void dump_get_token_sid_request( const struct get_token_sid_request *req )
3780 fprintf( stderr, " handle=%04x", req->handle );
3781 fprintf( stderr, ", which_sid=%08x", req->which_sid );
3784 static void dump_get_token_sid_reply( const struct get_token_sid_reply *req )
3786 fprintf( stderr, " sid_len=%u", req->sid_len );
3787 dump_varargs_SID( ", sid=", cur_size );
3790 static void dump_get_token_groups_request( const struct get_token_groups_request *req )
3792 fprintf( stderr, " handle=%04x", req->handle );
3795 static void dump_get_token_groups_reply( const struct get_token_groups_reply *req )
3797 fprintf( stderr, " user_len=%u", req->user_len );
3798 dump_varargs_token_groups( ", user=", cur_size );
3801 static void dump_get_token_default_dacl_request( const struct get_token_default_dacl_request *req )
3803 fprintf( stderr, " handle=%04x", req->handle );
3806 static void dump_get_token_default_dacl_reply( const struct get_token_default_dacl_reply *req )
3808 fprintf( stderr, " acl_len=%u", req->acl_len );
3809 dump_varargs_ACL( ", acl=", cur_size );
3812 static void dump_set_token_default_dacl_request( const struct set_token_default_dacl_request *req )
3814 fprintf( stderr, " handle=%04x", req->handle );
3815 dump_varargs_ACL( ", acl=", cur_size );
3818 static void dump_set_security_object_request( const struct set_security_object_request *req )
3820 fprintf( stderr, " handle=%04x", req->handle );
3821 fprintf( stderr, ", security_info=%08x", req->security_info );
3822 dump_varargs_security_descriptor( ", sd=", cur_size );
3825 static void dump_get_security_object_request( const struct get_security_object_request *req )
3827 fprintf( stderr, " handle=%04x", req->handle );
3828 fprintf( stderr, ", security_info=%08x", req->security_info );
3831 static void dump_get_security_object_reply( const struct get_security_object_reply *req )
3833 fprintf( stderr, " sd_len=%08x", req->sd_len );
3834 dump_varargs_security_descriptor( ", sd=", cur_size );
3837 static void dump_create_mailslot_request( const struct create_mailslot_request *req )
3839 fprintf( stderr, " access=%08x", req->access );
3840 fprintf( stderr, ", attributes=%08x", req->attributes );
3841 fprintf( stderr, ", rootdir=%04x", req->rootdir );
3842 dump_timeout( ", read_timeout=", &req->read_timeout );
3843 fprintf( stderr, ", max_msgsize=%08x", req->max_msgsize );
3844 dump_varargs_unicode_str( ", name=", cur_size );
3847 static void dump_create_mailslot_reply( const struct create_mailslot_reply *req )
3849 fprintf( stderr, " handle=%04x", req->handle );
3852 static void dump_set_mailslot_info_request( const struct set_mailslot_info_request *req )
3854 fprintf( stderr, " handle=%04x", req->handle );
3855 dump_timeout( ", read_timeout=", &req->read_timeout );
3856 fprintf( stderr, ", flags=%08x", req->flags );
3859 static void dump_set_mailslot_info_reply( const struct set_mailslot_info_reply *req )
3861 dump_timeout( " read_timeout=", &req->read_timeout );
3862 fprintf( stderr, ", max_msgsize=%08x", req->max_msgsize );
3865 static void dump_create_directory_request( const struct create_directory_request *req )
3867 fprintf( stderr, " access=%08x", req->access );
3868 fprintf( stderr, ", attributes=%08x", req->attributes );
3869 fprintf( stderr, ", rootdir=%04x", req->rootdir );
3870 dump_varargs_unicode_str( ", directory_name=", cur_size );
3873 static void dump_create_directory_reply( const struct create_directory_reply *req )
3875 fprintf( stderr, " handle=%04x", req->handle );
3878 static void dump_open_directory_request( const struct open_directory_request *req )
3880 fprintf( stderr, " access=%08x", req->access );
3881 fprintf( stderr, ", attributes=%08x", req->attributes );
3882 fprintf( stderr, ", rootdir=%04x", req->rootdir );
3883 dump_varargs_unicode_str( ", directory_name=", cur_size );
3886 static void dump_open_directory_reply( const struct open_directory_reply *req )
3888 fprintf( stderr, " handle=%04x", req->handle );
3891 static void dump_get_directory_entry_request( const struct get_directory_entry_request *req )
3893 fprintf( stderr, " handle=%04x", req->handle );
3894 fprintf( stderr, ", index=%08x", req->index );
3897 static void dump_get_directory_entry_reply( const struct get_directory_entry_reply *req )
3899 fprintf( stderr, " name_len=%u", req->name_len );
3900 dump_varargs_unicode_str( ", name=", min(cur_size,req->name_len) );
3901 dump_varargs_unicode_str( ", type=", cur_size );
3904 static void dump_create_symlink_request( const struct create_symlink_request *req )
3906 fprintf( stderr, " access=%08x", req->access );
3907 fprintf( stderr, ", attributes=%08x", req->attributes );
3908 fprintf( stderr, ", rootdir=%04x", req->rootdir );
3909 fprintf( stderr, ", name_len=%u", req->name_len );
3910 dump_varargs_unicode_str( ", name=", min(cur_size,req->name_len) );
3911 dump_varargs_unicode_str( ", target_name=", cur_size );
3914 static void dump_create_symlink_reply( const struct create_symlink_reply *req )
3916 fprintf( stderr, " handle=%04x", req->handle );
3919 static void dump_open_symlink_request( const struct open_symlink_request *req )
3921 fprintf( stderr, " access=%08x", req->access );
3922 fprintf( stderr, ", attributes=%08x", req->attributes );
3923 fprintf( stderr, ", rootdir=%04x", req->rootdir );
3924 dump_varargs_unicode_str( ", name=", cur_size );
3927 static void dump_open_symlink_reply( const struct open_symlink_reply *req )
3929 fprintf( stderr, " handle=%04x", req->handle );
3932 static void dump_query_symlink_request( const struct query_symlink_request *req )
3934 fprintf( stderr, " handle=%04x", req->handle );
3937 static void dump_query_symlink_reply( const struct query_symlink_reply *req )
3939 fprintf( stderr, " total=%u", req->total );
3940 dump_varargs_unicode_str( ", target_name=", cur_size );
3943 static void dump_get_object_info_request( const struct get_object_info_request *req )
3945 fprintf( stderr, " handle=%04x", req->handle );
3948 static void dump_get_object_info_reply( const struct get_object_info_reply *req )
3950 fprintf( stderr, " access=%08x", req->access );
3951 fprintf( stderr, ", ref_count=%08x", req->ref_count );
3952 fprintf( stderr, ", handle_count=%08x", req->handle_count );
3953 fprintf( stderr, ", total=%u", req->total );
3954 dump_varargs_unicode_str( ", name=", cur_size );
3957 static void dump_get_object_type_request( const struct get_object_type_request *req )
3959 fprintf( stderr, " handle=%04x", req->handle );
3962 static void dump_get_object_type_reply( const struct get_object_type_reply *req )
3964 fprintf( stderr, " total=%u", req->total );
3965 dump_varargs_unicode_str( ", type=", cur_size );
3968 static void dump_unlink_object_request( const struct unlink_object_request *req )
3970 fprintf( stderr, " handle=%04x", req->handle );
3973 static void dump_get_token_impersonation_level_request( const struct get_token_impersonation_level_request *req )
3975 fprintf( stderr, " handle=%04x", req->handle );
3978 static void dump_get_token_impersonation_level_reply( const struct get_token_impersonation_level_reply *req )
3980 fprintf( stderr, " impersonation_level=%d", req->impersonation_level );
3983 static void dump_allocate_locally_unique_id_request( const struct allocate_locally_unique_id_request *req )
3987 static void dump_allocate_locally_unique_id_reply( const struct allocate_locally_unique_id_reply *req )
3989 dump_luid( " luid=", &req->luid );
3992 static void dump_create_device_manager_request( const struct create_device_manager_request *req )
3994 fprintf( stderr, " access=%08x", req->access );
3995 fprintf( stderr, ", attributes=%08x", req->attributes );
3998 static void dump_create_device_manager_reply( const struct create_device_manager_reply *req )
4000 fprintf( stderr, " handle=%04x", req->handle );
4003 static void dump_create_device_request( const struct create_device_request *req )
4005 fprintf( stderr, " access=%08x", req->access );
4006 fprintf( stderr, ", attributes=%08x", req->attributes );
4007 fprintf( stderr, ", rootdir=%04x", req->rootdir );
4008 dump_uint64( ", user_ptr=", &req->user_ptr );
4009 fprintf( stderr, ", manager=%04x", req->manager );
4010 dump_varargs_unicode_str( ", name=", cur_size );
4013 static void dump_create_device_reply( const struct create_device_reply *req )
4015 fprintf( stderr, " handle=%04x", req->handle );
4018 static void dump_delete_device_request( const struct delete_device_request *req )
4020 fprintf( stderr, " handle=%04x", req->handle );
4023 static void dump_get_next_device_request_request( const struct get_next_device_request_request *req )
4025 fprintf( stderr, " manager=%04x", req->manager );
4026 fprintf( stderr, ", prev=%04x", req->prev );
4027 fprintf( stderr, ", status=%08x", req->status );
4030 static void dump_get_next_device_request_reply( const struct get_next_device_request_reply *req )
4032 dump_irp_params( " params=", &req->params );
4033 fprintf( stderr, ", next=%04x", req->next );
4034 fprintf( stderr, ", client_pid=%04x", req->client_pid );
4035 fprintf( stderr, ", client_tid=%04x", req->client_tid );
4036 fprintf( stderr, ", in_size=%u", req->in_size );
4037 fprintf( stderr, ", out_size=%u", req->out_size );
4038 dump_varargs_bytes( ", next_data=", cur_size );
4041 static void dump_make_process_system_request( const struct make_process_system_request *req )
4045 static void dump_make_process_system_reply( const struct make_process_system_reply *req )
4047 fprintf( stderr, " event=%04x", req->event );
4050 static void dump_get_token_statistics_request( const struct get_token_statistics_request *req )
4052 fprintf( stderr, " handle=%04x", req->handle );
4055 static void dump_get_token_statistics_reply( const struct get_token_statistics_reply *req )
4057 dump_luid( " token_id=", &req->token_id );
4058 dump_luid( ", modified_id=", &req->modified_id );
4059 fprintf( stderr, ", primary=%d", req->primary );
4060 fprintf( stderr, ", impersonation_level=%d", req->impersonation_level );
4061 fprintf( stderr, ", group_count=%d", req->group_count );
4062 fprintf( stderr, ", privilege_count=%d", req->privilege_count );
4065 static void dump_create_completion_request( const struct create_completion_request *req )
4067 fprintf( stderr, " access=%08x", req->access );
4068 fprintf( stderr, ", attributes=%08x", req->attributes );
4069 fprintf( stderr, ", concurrent=%08x", req->concurrent );
4070 fprintf( stderr, ", rootdir=%04x", req->rootdir );
4071 dump_varargs_unicode_str( ", filename=", cur_size );
4074 static void dump_create_completion_reply( const struct create_completion_reply *req )
4076 fprintf( stderr, " handle=%04x", req->handle );
4079 static void dump_open_completion_request( const struct open_completion_request *req )
4081 fprintf( stderr, " access=%08x", req->access );
4082 fprintf( stderr, ", attributes=%08x", req->attributes );
4083 fprintf( stderr, ", rootdir=%04x", req->rootdir );
4084 dump_varargs_unicode_str( ", filename=", cur_size );
4087 static void dump_open_completion_reply( const struct open_completion_reply *req )
4089 fprintf( stderr, " handle=%04x", req->handle );
4092 static void dump_add_completion_request( const struct add_completion_request *req )
4094 fprintf( stderr, " handle=%04x", req->handle );
4095 dump_uint64( ", ckey=", &req->ckey );
4096 dump_uint64( ", cvalue=", &req->cvalue );
4097 dump_uint64( ", information=", &req->information );
4098 fprintf( stderr, ", status=%08x", req->status );
4101 static void dump_remove_completion_request( const struct remove_completion_request *req )
4103 fprintf( stderr, " handle=%04x", req->handle );
4106 static void dump_remove_completion_reply( const struct remove_completion_reply *req )
4108 dump_uint64( " ckey=", &req->ckey );
4109 dump_uint64( ", cvalue=", &req->cvalue );
4110 dump_uint64( ", information=", &req->information );
4111 fprintf( stderr, ", status=%08x", req->status );
4114 static void dump_query_completion_request( const struct query_completion_request *req )
4116 fprintf( stderr, " handle=%04x", req->handle );
4119 static void dump_query_completion_reply( const struct query_completion_reply *req )
4121 fprintf( stderr, " depth=%08x", req->depth );
4124 static void dump_set_completion_info_request( const struct set_completion_info_request *req )
4126 fprintf( stderr, " handle=%04x", req->handle );
4127 dump_uint64( ", ckey=", &req->ckey );
4128 fprintf( stderr, ", chandle=%04x", req->chandle );
4131 static void dump_add_fd_completion_request( const struct add_fd_completion_request *req )
4133 fprintf( stderr, " handle=%04x", req->handle );
4134 dump_uint64( ", cvalue=", &req->cvalue );
4135 dump_uint64( ", information=", &req->information );
4136 fprintf( stderr, ", status=%08x", req->status );
4139 static void dump_get_window_layered_info_request( const struct get_window_layered_info_request *req )
4141 fprintf( stderr, " handle=%08x", req->handle );
4144 static void dump_get_window_layered_info_reply( const struct get_window_layered_info_reply *req )
4146 fprintf( stderr, " color_key=%08x", req->color_key );
4147 fprintf( stderr, ", alpha=%08x", req->alpha );
4148 fprintf( stderr, ", flags=%08x", req->flags );
4151 static void dump_set_window_layered_info_request( const struct set_window_layered_info_request *req )
4153 fprintf( stderr, " handle=%08x", req->handle );
4154 fprintf( stderr, ", color_key=%08x", req->color_key );
4155 fprintf( stderr, ", alpha=%08x", req->alpha );
4156 fprintf( stderr, ", flags=%08x", req->flags );
4159 static void dump_alloc_user_handle_request( const struct alloc_user_handle_request *req )
4163 static void dump_alloc_user_handle_reply( const struct alloc_user_handle_reply *req )
4165 fprintf( stderr, " handle=%08x", req->handle );
4168 static void dump_free_user_handle_request( const struct free_user_handle_request *req )
4170 fprintf( stderr, " handle=%08x", req->handle );
4173 static void dump_set_cursor_request( const struct set_cursor_request *req )
4175 fprintf( stderr, " flags=%08x", req->flags );
4176 fprintf( stderr, ", handle=%08x", req->handle );
4177 fprintf( stderr, ", show_count=%d", req->show_count );
4178 fprintf( stderr, ", x=%d", req->x );
4179 fprintf( stderr, ", y=%d", req->y );
4180 dump_rectangle( ", clip=", &req->clip );
4181 fprintf( stderr, ", clip_msg=%08x", req->clip_msg );
4184 static void dump_set_cursor_reply( const struct set_cursor_reply *req )
4186 fprintf( stderr, " prev_handle=%08x", req->prev_handle );
4187 fprintf( stderr, ", prev_count=%d", req->prev_count );
4188 fprintf( stderr, ", prev_x=%d", req->prev_x );
4189 fprintf( stderr, ", prev_y=%d", req->prev_y );
4190 fprintf( stderr, ", new_x=%d", req->new_x );
4191 fprintf( stderr, ", new_y=%d", req->new_y );
4192 dump_rectangle( ", new_clip=", &req->new_clip );
4193 fprintf( stderr, ", last_change=%08x", req->last_change );
4196 static void dump_update_rawinput_devices_request( const struct update_rawinput_devices_request *req )
4198 dump_varargs_rawinput_devices( " devices=", cur_size );
4201 static void dump_get_suspend_context_request( const struct get_suspend_context_request *req )
4205 static void dump_get_suspend_context_reply( const struct get_suspend_context_reply *req )
4207 dump_varargs_context( " context=", cur_size );
4210 static void dump_set_suspend_context_request( const struct set_suspend_context_request *req )
4212 dump_varargs_context( " context=", cur_size );
4215 static void dump_create_job_request( const struct create_job_request *req )
4217 fprintf( stderr, " access=%08x", req->access );
4218 fprintf( stderr, ", attributes=%08x", req->attributes );
4219 dump_varargs_object_attributes( ", objattr=", cur_size );
4222 static void dump_create_job_reply( const struct create_job_reply *req )
4224 fprintf( stderr, " handle=%04x", req->handle );
4227 static void dump_assign_job_request( const struct assign_job_request *req )
4229 fprintf( stderr, " job=%04x", req->job );
4230 fprintf( stderr, ", process=%04x", req->process );
4233 static void dump_process_in_job_request( const struct process_in_job_request *req )
4235 fprintf( stderr, " job=%04x", req->job );
4236 fprintf( stderr, ", process=%04x", req->process );
4239 static void dump_set_job_limits_request( const struct set_job_limits_request *req )
4241 fprintf( stderr, " handle=%04x", req->handle );
4242 fprintf( stderr, ", limit_flags=%08x", req->limit_flags );
4245 static void dump_set_job_completion_port_request( const struct set_job_completion_port_request *req )
4247 fprintf( stderr, " job=%04x", req->job );
4248 fprintf( stderr, ", port=%04x", req->port );
4249 dump_uint64( ", key=", &req->key );
4252 static void dump_terminate_job_request( const struct terminate_job_request *req )
4254 fprintf( stderr, " handle=%04x", req->handle );
4255 fprintf( stderr, ", status=%d", req->status );
4258 static const dump_func req_dumpers[REQ_NB_REQUESTS] = {
4259 (dump_func)dump_new_process_request,
4260 (dump_func)dump_get_new_process_info_request,
4261 (dump_func)dump_new_thread_request,
4262 (dump_func)dump_get_startup_info_request,
4263 (dump_func)dump_init_process_done_request,
4264 (dump_func)dump_init_thread_request,
4265 (dump_func)dump_terminate_process_request,
4266 (dump_func)dump_terminate_thread_request,
4267 (dump_func)dump_get_process_info_request,
4268 (dump_func)dump_set_process_info_request,
4269 (dump_func)dump_get_thread_info_request,
4270 (dump_func)dump_get_thread_times_request,
4271 (dump_func)dump_set_thread_info_request,
4272 (dump_func)dump_get_dll_info_request,
4273 (dump_func)dump_suspend_thread_request,
4274 (dump_func)dump_resume_thread_request,
4275 (dump_func)dump_load_dll_request,
4276 (dump_func)dump_unload_dll_request,
4277 (dump_func)dump_queue_apc_request,
4278 (dump_func)dump_get_apc_result_request,
4279 (dump_func)dump_close_handle_request,
4280 (dump_func)dump_set_handle_info_request,
4281 (dump_func)dump_dup_handle_request,
4282 (dump_func)dump_open_process_request,
4283 (dump_func)dump_open_thread_request,
4284 (dump_func)dump_select_request,
4285 (dump_func)dump_create_event_request,
4286 (dump_func)dump_event_op_request,
4287 (dump_func)dump_query_event_request,
4288 (dump_func)dump_open_event_request,
4289 (dump_func)dump_create_keyed_event_request,
4290 (dump_func)dump_open_keyed_event_request,
4291 (dump_func)dump_create_mutex_request,
4292 (dump_func)dump_release_mutex_request,
4293 (dump_func)dump_open_mutex_request,
4294 (dump_func)dump_create_semaphore_request,
4295 (dump_func)dump_release_semaphore_request,
4296 (dump_func)dump_query_semaphore_request,
4297 (dump_func)dump_open_semaphore_request,
4298 (dump_func)dump_create_file_request,
4299 (dump_func)dump_open_file_object_request,
4300 (dump_func)dump_alloc_file_handle_request,
4301 (dump_func)dump_get_handle_unix_name_request,
4302 (dump_func)dump_get_handle_fd_request,
4303 (dump_func)dump_flush_request,
4304 (dump_func)dump_lock_file_request,
4305 (dump_func)dump_unlock_file_request,
4306 (dump_func)dump_create_socket_request,
4307 (dump_func)dump_accept_socket_request,
4308 (dump_func)dump_accept_into_socket_request,
4309 (dump_func)dump_set_socket_event_request,
4310 (dump_func)dump_get_socket_event_request,
4311 (dump_func)dump_get_socket_info_request,
4312 (dump_func)dump_enable_socket_event_request,
4313 (dump_func)dump_set_socket_deferred_request,
4314 (dump_func)dump_alloc_console_request,
4315 (dump_func)dump_free_console_request,
4316 (dump_func)dump_get_console_renderer_events_request,
4317 (dump_func)dump_open_console_request,
4318 (dump_func)dump_get_console_wait_event_request,
4319 (dump_func)dump_get_console_mode_request,
4320 (dump_func)dump_set_console_mode_request,
4321 (dump_func)dump_set_console_input_info_request,
4322 (dump_func)dump_get_console_input_info_request,
4323 (dump_func)dump_append_console_input_history_request,
4324 (dump_func)dump_get_console_input_history_request,
4325 (dump_func)dump_create_console_output_request,
4326 (dump_func)dump_set_console_output_info_request,
4327 (dump_func)dump_get_console_output_info_request,
4328 (dump_func)dump_write_console_input_request,
4329 (dump_func)dump_read_console_input_request,
4330 (dump_func)dump_write_console_output_request,
4331 (dump_func)dump_fill_console_output_request,
4332 (dump_func)dump_read_console_output_request,
4333 (dump_func)dump_move_console_output_request,
4334 (dump_func)dump_send_console_signal_request,
4335 (dump_func)dump_read_directory_changes_request,
4336 (dump_func)dump_read_change_request,
4337 (dump_func)dump_create_mapping_request,
4338 (dump_func)dump_open_mapping_request,
4339 (dump_func)dump_get_mapping_info_request,
4340 (dump_func)dump_get_mapping_committed_range_request,
4341 (dump_func)dump_add_mapping_committed_range_request,
4342 (dump_func)dump_create_snapshot_request,
4343 (dump_func)dump_next_process_request,
4344 (dump_func)dump_next_thread_request,
4345 (dump_func)dump_wait_debug_event_request,
4346 (dump_func)dump_queue_exception_event_request,
4347 (dump_func)dump_get_exception_status_request,
4348 (dump_func)dump_continue_debug_event_request,
4349 (dump_func)dump_debug_process_request,
4350 (dump_func)dump_debug_break_request,
4351 (dump_func)dump_set_debugger_kill_on_exit_request,
4352 (dump_func)dump_read_process_memory_request,
4353 (dump_func)dump_write_process_memory_request,
4354 (dump_func)dump_create_key_request,
4355 (dump_func)dump_open_key_request,
4356 (dump_func)dump_delete_key_request,
4357 (dump_func)dump_flush_key_request,
4358 (dump_func)dump_enum_key_request,
4359 (dump_func)dump_set_key_value_request,
4360 (dump_func)dump_get_key_value_request,
4361 (dump_func)dump_enum_key_value_request,
4362 (dump_func)dump_delete_key_value_request,
4363 (dump_func)dump_load_registry_request,
4364 (dump_func)dump_unload_registry_request,
4365 (dump_func)dump_save_registry_request,
4366 (dump_func)dump_set_registry_notification_request,
4367 (dump_func)dump_create_timer_request,
4368 (dump_func)dump_open_timer_request,
4369 (dump_func)dump_set_timer_request,
4370 (dump_func)dump_cancel_timer_request,
4371 (dump_func)dump_get_timer_info_request,
4372 (dump_func)dump_get_thread_context_request,
4373 (dump_func)dump_set_thread_context_request,
4374 (dump_func)dump_get_selector_entry_request,
4375 (dump_func)dump_add_atom_request,
4376 (dump_func)dump_delete_atom_request,
4377 (dump_func)dump_find_atom_request,
4378 (dump_func)dump_get_atom_information_request,
4379 (dump_func)dump_set_atom_information_request,
4380 (dump_func)dump_empty_atom_table_request,
4381 (dump_func)dump_init_atom_table_request,
4382 (dump_func)dump_get_msg_queue_request,
4383 (dump_func)dump_set_queue_fd_request,
4384 (dump_func)dump_set_queue_mask_request,
4385 (dump_func)dump_get_queue_status_request,
4386 (dump_func)dump_get_process_idle_event_request,
4387 (dump_func)dump_send_message_request,
4388 (dump_func)dump_post_quit_message_request,
4389 (dump_func)dump_send_hardware_message_request,
4390 (dump_func)dump_get_message_request,
4391 (dump_func)dump_reply_message_request,
4392 (dump_func)dump_accept_hardware_message_request,
4393 (dump_func)dump_get_message_reply_request,
4394 (dump_func)dump_set_win_timer_request,
4395 (dump_func)dump_kill_win_timer_request,
4396 (dump_func)dump_is_window_hung_request,
4397 (dump_func)dump_get_serial_info_request,
4398 (dump_func)dump_set_serial_info_request,
4399 (dump_func)dump_register_async_request,
4400 (dump_func)dump_cancel_async_request,
4401 (dump_func)dump_read_request,
4402 (dump_func)dump_write_request,
4403 (dump_func)dump_ioctl_request,
4404 (dump_func)dump_set_irp_result_request,
4405 (dump_func)dump_get_irp_result_request,
4406 (dump_func)dump_create_named_pipe_request,
4407 (dump_func)dump_get_named_pipe_info_request,
4408 (dump_func)dump_set_named_pipe_info_request,
4409 (dump_func)dump_create_window_request,
4410 (dump_func)dump_destroy_window_request,
4411 (dump_func)dump_get_desktop_window_request,
4412 (dump_func)dump_set_window_owner_request,
4413 (dump_func)dump_get_window_info_request,
4414 (dump_func)dump_set_window_info_request,
4415 (dump_func)dump_set_parent_request,
4416 (dump_func)dump_get_window_parents_request,
4417 (dump_func)dump_get_window_children_request,
4418 (dump_func)dump_get_window_children_from_point_request,
4419 (dump_func)dump_get_window_tree_request,
4420 (dump_func)dump_set_window_pos_request,
4421 (dump_func)dump_get_window_rectangles_request,
4422 (dump_func)dump_get_window_text_request,
4423 (dump_func)dump_set_window_text_request,
4424 (dump_func)dump_get_windows_offset_request,
4425 (dump_func)dump_get_visible_region_request,
4426 (dump_func)dump_get_surface_region_request,
4427 (dump_func)dump_get_window_region_request,
4428 (dump_func)dump_set_window_region_request,
4429 (dump_func)dump_get_update_region_request,
4430 (dump_func)dump_update_window_zorder_request,
4431 (dump_func)dump_redraw_window_request,
4432 (dump_func)dump_set_window_property_request,
4433 (dump_func)dump_remove_window_property_request,
4434 (dump_func)dump_get_window_property_request,
4435 (dump_func)dump_get_window_properties_request,
4436 (dump_func)dump_create_winstation_request,
4437 (dump_func)dump_open_winstation_request,
4438 (dump_func)dump_close_winstation_request,
4439 (dump_func)dump_get_process_winstation_request,
4440 (dump_func)dump_set_process_winstation_request,
4441 (dump_func)dump_enum_winstation_request,
4442 (dump_func)dump_create_desktop_request,
4443 (dump_func)dump_open_desktop_request,
4444 (dump_func)dump_open_input_desktop_request,
4445 (dump_func)dump_close_desktop_request,
4446 (dump_func)dump_get_thread_desktop_request,
4447 (dump_func)dump_set_thread_desktop_request,
4448 (dump_func)dump_enum_desktop_request,
4449 (dump_func)dump_set_user_object_info_request,
4450 (dump_func)dump_register_hotkey_request,
4451 (dump_func)dump_unregister_hotkey_request,
4452 (dump_func)dump_attach_thread_input_request,
4453 (dump_func)dump_get_thread_input_request,
4454 (dump_func)dump_get_last_input_time_request,
4455 (dump_func)dump_get_key_state_request,
4456 (dump_func)dump_set_key_state_request,
4457 (dump_func)dump_set_foreground_window_request,
4458 (dump_func)dump_set_focus_window_request,
4459 (dump_func)dump_set_active_window_request,
4460 (dump_func)dump_set_capture_window_request,
4461 (dump_func)dump_set_caret_window_request,
4462 (dump_func)dump_set_caret_info_request,
4463 (dump_func)dump_set_hook_request,
4464 (dump_func)dump_remove_hook_request,
4465 (dump_func)dump_start_hook_chain_request,
4466 (dump_func)dump_finish_hook_chain_request,
4467 (dump_func)dump_get_hook_info_request,
4468 (dump_func)dump_create_class_request,
4469 (dump_func)dump_destroy_class_request,
4470 (dump_func)dump_set_class_info_request,
4471 (dump_func)dump_set_clipboard_info_request,
4472 (dump_func)dump_empty_clipboard_request,
4473 (dump_func)dump_open_token_request,
4474 (dump_func)dump_set_global_windows_request,
4475 (dump_func)dump_adjust_token_privileges_request,
4476 (dump_func)dump_get_token_privileges_request,
4477 (dump_func)dump_check_token_privileges_request,
4478 (dump_func)dump_duplicate_token_request,
4479 (dump_func)dump_access_check_request,
4480 (dump_func)dump_get_token_sid_request,
4481 (dump_func)dump_get_token_groups_request,
4482 (dump_func)dump_get_token_default_dacl_request,
4483 (dump_func)dump_set_token_default_dacl_request,
4484 (dump_func)dump_set_security_object_request,
4485 (dump_func)dump_get_security_object_request,
4486 (dump_func)dump_create_mailslot_request,
4487 (dump_func)dump_set_mailslot_info_request,
4488 (dump_func)dump_create_directory_request,
4489 (dump_func)dump_open_directory_request,
4490 (dump_func)dump_get_directory_entry_request,
4491 (dump_func)dump_create_symlink_request,
4492 (dump_func)dump_open_symlink_request,
4493 (dump_func)dump_query_symlink_request,
4494 (dump_func)dump_get_object_info_request,
4495 (dump_func)dump_get_object_type_request,
4496 (dump_func)dump_unlink_object_request,
4497 (dump_func)dump_get_token_impersonation_level_request,
4498 (dump_func)dump_allocate_locally_unique_id_request,
4499 (dump_func)dump_create_device_manager_request,
4500 (dump_func)dump_create_device_request,
4501 (dump_func)dump_delete_device_request,
4502 (dump_func)dump_get_next_device_request_request,
4503 (dump_func)dump_make_process_system_request,
4504 (dump_func)dump_get_token_statistics_request,
4505 (dump_func)dump_create_completion_request,
4506 (dump_func)dump_open_completion_request,
4507 (dump_func)dump_add_completion_request,
4508 (dump_func)dump_remove_completion_request,
4509 (dump_func)dump_query_completion_request,
4510 (dump_func)dump_set_completion_info_request,
4511 (dump_func)dump_add_fd_completion_request,
4512 (dump_func)dump_get_window_layered_info_request,
4513 (dump_func)dump_set_window_layered_info_request,
4514 (dump_func)dump_alloc_user_handle_request,
4515 (dump_func)dump_free_user_handle_request,
4516 (dump_func)dump_set_cursor_request,
4517 (dump_func)dump_update_rawinput_devices_request,
4518 (dump_func)dump_get_suspend_context_request,
4519 (dump_func)dump_set_suspend_context_request,
4520 (dump_func)dump_create_job_request,
4521 (dump_func)dump_assign_job_request,
4522 (dump_func)dump_process_in_job_request,
4523 (dump_func)dump_set_job_limits_request,
4524 (dump_func)dump_set_job_completion_port_request,
4525 (dump_func)dump_terminate_job_request,
4528 static const dump_func reply_dumpers[REQ_NB_REQUESTS] = {
4529 (dump_func)dump_new_process_reply,
4530 (dump_func)dump_get_new_process_info_reply,
4531 (dump_func)dump_new_thread_reply,
4532 (dump_func)dump_get_startup_info_reply,
4533 NULL,
4534 (dump_func)dump_init_thread_reply,
4535 (dump_func)dump_terminate_process_reply,
4536 (dump_func)dump_terminate_thread_reply,
4537 (dump_func)dump_get_process_info_reply,
4538 NULL,
4539 (dump_func)dump_get_thread_info_reply,
4540 (dump_func)dump_get_thread_times_reply,
4541 NULL,
4542 (dump_func)dump_get_dll_info_reply,
4543 (dump_func)dump_suspend_thread_reply,
4544 (dump_func)dump_resume_thread_reply,
4545 NULL,
4546 NULL,
4547 (dump_func)dump_queue_apc_reply,
4548 (dump_func)dump_get_apc_result_reply,
4549 NULL,
4550 (dump_func)dump_set_handle_info_reply,
4551 (dump_func)dump_dup_handle_reply,
4552 (dump_func)dump_open_process_reply,
4553 (dump_func)dump_open_thread_reply,
4554 (dump_func)dump_select_reply,
4555 (dump_func)dump_create_event_reply,
4556 NULL,
4557 (dump_func)dump_query_event_reply,
4558 (dump_func)dump_open_event_reply,
4559 (dump_func)dump_create_keyed_event_reply,
4560 (dump_func)dump_open_keyed_event_reply,
4561 (dump_func)dump_create_mutex_reply,
4562 (dump_func)dump_release_mutex_reply,
4563 (dump_func)dump_open_mutex_reply,
4564 (dump_func)dump_create_semaphore_reply,
4565 (dump_func)dump_release_semaphore_reply,
4566 (dump_func)dump_query_semaphore_reply,
4567 (dump_func)dump_open_semaphore_reply,
4568 (dump_func)dump_create_file_reply,
4569 (dump_func)dump_open_file_object_reply,
4570 (dump_func)dump_alloc_file_handle_reply,
4571 (dump_func)dump_get_handle_unix_name_reply,
4572 (dump_func)dump_get_handle_fd_reply,
4573 (dump_func)dump_flush_reply,
4574 (dump_func)dump_lock_file_reply,
4575 NULL,
4576 (dump_func)dump_create_socket_reply,
4577 (dump_func)dump_accept_socket_reply,
4578 NULL,
4579 NULL,
4580 (dump_func)dump_get_socket_event_reply,
4581 (dump_func)dump_get_socket_info_reply,
4582 NULL,
4583 NULL,
4584 (dump_func)dump_alloc_console_reply,
4585 NULL,
4586 (dump_func)dump_get_console_renderer_events_reply,
4587 (dump_func)dump_open_console_reply,
4588 (dump_func)dump_get_console_wait_event_reply,
4589 (dump_func)dump_get_console_mode_reply,
4590 NULL,
4591 NULL,
4592 (dump_func)dump_get_console_input_info_reply,
4593 NULL,
4594 (dump_func)dump_get_console_input_history_reply,
4595 (dump_func)dump_create_console_output_reply,
4596 NULL,
4597 (dump_func)dump_get_console_output_info_reply,
4598 (dump_func)dump_write_console_input_reply,
4599 (dump_func)dump_read_console_input_reply,
4600 (dump_func)dump_write_console_output_reply,
4601 (dump_func)dump_fill_console_output_reply,
4602 (dump_func)dump_read_console_output_reply,
4603 NULL,
4604 NULL,
4605 NULL,
4606 (dump_func)dump_read_change_reply,
4607 (dump_func)dump_create_mapping_reply,
4608 (dump_func)dump_open_mapping_reply,
4609 (dump_func)dump_get_mapping_info_reply,
4610 (dump_func)dump_get_mapping_committed_range_reply,
4611 NULL,
4612 (dump_func)dump_create_snapshot_reply,
4613 (dump_func)dump_next_process_reply,
4614 (dump_func)dump_next_thread_reply,
4615 (dump_func)dump_wait_debug_event_reply,
4616 (dump_func)dump_queue_exception_event_reply,
4617 (dump_func)dump_get_exception_status_reply,
4618 NULL,
4619 NULL,
4620 (dump_func)dump_debug_break_reply,
4621 NULL,
4622 (dump_func)dump_read_process_memory_reply,
4623 NULL,
4624 (dump_func)dump_create_key_reply,
4625 (dump_func)dump_open_key_reply,
4626 NULL,
4627 NULL,
4628 (dump_func)dump_enum_key_reply,
4629 NULL,
4630 (dump_func)dump_get_key_value_reply,
4631 (dump_func)dump_enum_key_value_reply,
4632 NULL,
4633 NULL,
4634 NULL,
4635 NULL,
4636 NULL,
4637 (dump_func)dump_create_timer_reply,
4638 (dump_func)dump_open_timer_reply,
4639 (dump_func)dump_set_timer_reply,
4640 (dump_func)dump_cancel_timer_reply,
4641 (dump_func)dump_get_timer_info_reply,
4642 (dump_func)dump_get_thread_context_reply,
4643 (dump_func)dump_set_thread_context_reply,
4644 (dump_func)dump_get_selector_entry_reply,
4645 (dump_func)dump_add_atom_reply,
4646 NULL,
4647 (dump_func)dump_find_atom_reply,
4648 (dump_func)dump_get_atom_information_reply,
4649 NULL,
4650 NULL,
4651 (dump_func)dump_init_atom_table_reply,
4652 (dump_func)dump_get_msg_queue_reply,
4653 NULL,
4654 (dump_func)dump_set_queue_mask_reply,
4655 (dump_func)dump_get_queue_status_reply,
4656 (dump_func)dump_get_process_idle_event_reply,
4657 NULL,
4658 NULL,
4659 (dump_func)dump_send_hardware_message_reply,
4660 (dump_func)dump_get_message_reply,
4661 NULL,
4662 NULL,
4663 (dump_func)dump_get_message_reply_reply,
4664 (dump_func)dump_set_win_timer_reply,
4665 NULL,
4666 (dump_func)dump_is_window_hung_reply,
4667 (dump_func)dump_get_serial_info_reply,
4668 NULL,
4669 NULL,
4670 NULL,
4671 (dump_func)dump_read_reply,
4672 (dump_func)dump_write_reply,
4673 (dump_func)dump_ioctl_reply,
4674 NULL,
4675 (dump_func)dump_get_irp_result_reply,
4676 (dump_func)dump_create_named_pipe_reply,
4677 (dump_func)dump_get_named_pipe_info_reply,
4678 NULL,
4679 (dump_func)dump_create_window_reply,
4680 NULL,
4681 (dump_func)dump_get_desktop_window_reply,
4682 (dump_func)dump_set_window_owner_reply,
4683 (dump_func)dump_get_window_info_reply,
4684 (dump_func)dump_set_window_info_reply,
4685 (dump_func)dump_set_parent_reply,
4686 (dump_func)dump_get_window_parents_reply,
4687 (dump_func)dump_get_window_children_reply,
4688 (dump_func)dump_get_window_children_from_point_reply,
4689 (dump_func)dump_get_window_tree_reply,
4690 (dump_func)dump_set_window_pos_reply,
4691 (dump_func)dump_get_window_rectangles_reply,
4692 (dump_func)dump_get_window_text_reply,
4693 NULL,
4694 (dump_func)dump_get_windows_offset_reply,
4695 (dump_func)dump_get_visible_region_reply,
4696 (dump_func)dump_get_surface_region_reply,
4697 (dump_func)dump_get_window_region_reply,
4698 NULL,
4699 (dump_func)dump_get_update_region_reply,
4700 NULL,
4701 NULL,
4702 NULL,
4703 (dump_func)dump_remove_window_property_reply,
4704 (dump_func)dump_get_window_property_reply,
4705 (dump_func)dump_get_window_properties_reply,
4706 (dump_func)dump_create_winstation_reply,
4707 (dump_func)dump_open_winstation_reply,
4708 NULL,
4709 (dump_func)dump_get_process_winstation_reply,
4710 NULL,
4711 (dump_func)dump_enum_winstation_reply,
4712 (dump_func)dump_create_desktop_reply,
4713 (dump_func)dump_open_desktop_reply,
4714 (dump_func)dump_open_input_desktop_reply,
4715 NULL,
4716 (dump_func)dump_get_thread_desktop_reply,
4717 NULL,
4718 (dump_func)dump_enum_desktop_reply,
4719 (dump_func)dump_set_user_object_info_reply,
4720 (dump_func)dump_register_hotkey_reply,
4721 (dump_func)dump_unregister_hotkey_reply,
4722 NULL,
4723 (dump_func)dump_get_thread_input_reply,
4724 (dump_func)dump_get_last_input_time_reply,
4725 (dump_func)dump_get_key_state_reply,
4726 NULL,
4727 (dump_func)dump_set_foreground_window_reply,
4728 (dump_func)dump_set_focus_window_reply,
4729 (dump_func)dump_set_active_window_reply,
4730 (dump_func)dump_set_capture_window_reply,
4731 (dump_func)dump_set_caret_window_reply,
4732 (dump_func)dump_set_caret_info_reply,
4733 (dump_func)dump_set_hook_reply,
4734 (dump_func)dump_remove_hook_reply,
4735 (dump_func)dump_start_hook_chain_reply,
4736 NULL,
4737 (dump_func)dump_get_hook_info_reply,
4738 (dump_func)dump_create_class_reply,
4739 (dump_func)dump_destroy_class_reply,
4740 (dump_func)dump_set_class_info_reply,
4741 (dump_func)dump_set_clipboard_info_reply,
4742 NULL,
4743 (dump_func)dump_open_token_reply,
4744 (dump_func)dump_set_global_windows_reply,
4745 (dump_func)dump_adjust_token_privileges_reply,
4746 (dump_func)dump_get_token_privileges_reply,
4747 (dump_func)dump_check_token_privileges_reply,
4748 (dump_func)dump_duplicate_token_reply,
4749 (dump_func)dump_access_check_reply,
4750 (dump_func)dump_get_token_sid_reply,
4751 (dump_func)dump_get_token_groups_reply,
4752 (dump_func)dump_get_token_default_dacl_reply,
4753 NULL,
4754 NULL,
4755 (dump_func)dump_get_security_object_reply,
4756 (dump_func)dump_create_mailslot_reply,
4757 (dump_func)dump_set_mailslot_info_reply,
4758 (dump_func)dump_create_directory_reply,
4759 (dump_func)dump_open_directory_reply,
4760 (dump_func)dump_get_directory_entry_reply,
4761 (dump_func)dump_create_symlink_reply,
4762 (dump_func)dump_open_symlink_reply,
4763 (dump_func)dump_query_symlink_reply,
4764 (dump_func)dump_get_object_info_reply,
4765 (dump_func)dump_get_object_type_reply,
4766 NULL,
4767 (dump_func)dump_get_token_impersonation_level_reply,
4768 (dump_func)dump_allocate_locally_unique_id_reply,
4769 (dump_func)dump_create_device_manager_reply,
4770 (dump_func)dump_create_device_reply,
4771 NULL,
4772 (dump_func)dump_get_next_device_request_reply,
4773 (dump_func)dump_make_process_system_reply,
4774 (dump_func)dump_get_token_statistics_reply,
4775 (dump_func)dump_create_completion_reply,
4776 (dump_func)dump_open_completion_reply,
4777 NULL,
4778 (dump_func)dump_remove_completion_reply,
4779 (dump_func)dump_query_completion_reply,
4780 NULL,
4781 NULL,
4782 (dump_func)dump_get_window_layered_info_reply,
4783 NULL,
4784 (dump_func)dump_alloc_user_handle_reply,
4785 NULL,
4786 (dump_func)dump_set_cursor_reply,
4787 NULL,
4788 (dump_func)dump_get_suspend_context_reply,
4789 NULL,
4790 (dump_func)dump_create_job_reply,
4791 NULL,
4792 NULL,
4793 NULL,
4794 NULL,
4795 NULL,
4798 static const char * const req_names[REQ_NB_REQUESTS] = {
4799 "new_process",
4800 "get_new_process_info",
4801 "new_thread",
4802 "get_startup_info",
4803 "init_process_done",
4804 "init_thread",
4805 "terminate_process",
4806 "terminate_thread",
4807 "get_process_info",
4808 "set_process_info",
4809 "get_thread_info",
4810 "get_thread_times",
4811 "set_thread_info",
4812 "get_dll_info",
4813 "suspend_thread",
4814 "resume_thread",
4815 "load_dll",
4816 "unload_dll",
4817 "queue_apc",
4818 "get_apc_result",
4819 "close_handle",
4820 "set_handle_info",
4821 "dup_handle",
4822 "open_process",
4823 "open_thread",
4824 "select",
4825 "create_event",
4826 "event_op",
4827 "query_event",
4828 "open_event",
4829 "create_keyed_event",
4830 "open_keyed_event",
4831 "create_mutex",
4832 "release_mutex",
4833 "open_mutex",
4834 "create_semaphore",
4835 "release_semaphore",
4836 "query_semaphore",
4837 "open_semaphore",
4838 "create_file",
4839 "open_file_object",
4840 "alloc_file_handle",
4841 "get_handle_unix_name",
4842 "get_handle_fd",
4843 "flush",
4844 "lock_file",
4845 "unlock_file",
4846 "create_socket",
4847 "accept_socket",
4848 "accept_into_socket",
4849 "set_socket_event",
4850 "get_socket_event",
4851 "get_socket_info",
4852 "enable_socket_event",
4853 "set_socket_deferred",
4854 "alloc_console",
4855 "free_console",
4856 "get_console_renderer_events",
4857 "open_console",
4858 "get_console_wait_event",
4859 "get_console_mode",
4860 "set_console_mode",
4861 "set_console_input_info",
4862 "get_console_input_info",
4863 "append_console_input_history",
4864 "get_console_input_history",
4865 "create_console_output",
4866 "set_console_output_info",
4867 "get_console_output_info",
4868 "write_console_input",
4869 "read_console_input",
4870 "write_console_output",
4871 "fill_console_output",
4872 "read_console_output",
4873 "move_console_output",
4874 "send_console_signal",
4875 "read_directory_changes",
4876 "read_change",
4877 "create_mapping",
4878 "open_mapping",
4879 "get_mapping_info",
4880 "get_mapping_committed_range",
4881 "add_mapping_committed_range",
4882 "create_snapshot",
4883 "next_process",
4884 "next_thread",
4885 "wait_debug_event",
4886 "queue_exception_event",
4887 "get_exception_status",
4888 "continue_debug_event",
4889 "debug_process",
4890 "debug_break",
4891 "set_debugger_kill_on_exit",
4892 "read_process_memory",
4893 "write_process_memory",
4894 "create_key",
4895 "open_key",
4896 "delete_key",
4897 "flush_key",
4898 "enum_key",
4899 "set_key_value",
4900 "get_key_value",
4901 "enum_key_value",
4902 "delete_key_value",
4903 "load_registry",
4904 "unload_registry",
4905 "save_registry",
4906 "set_registry_notification",
4907 "create_timer",
4908 "open_timer",
4909 "set_timer",
4910 "cancel_timer",
4911 "get_timer_info",
4912 "get_thread_context",
4913 "set_thread_context",
4914 "get_selector_entry",
4915 "add_atom",
4916 "delete_atom",
4917 "find_atom",
4918 "get_atom_information",
4919 "set_atom_information",
4920 "empty_atom_table",
4921 "init_atom_table",
4922 "get_msg_queue",
4923 "set_queue_fd",
4924 "set_queue_mask",
4925 "get_queue_status",
4926 "get_process_idle_event",
4927 "send_message",
4928 "post_quit_message",
4929 "send_hardware_message",
4930 "get_message",
4931 "reply_message",
4932 "accept_hardware_message",
4933 "get_message_reply",
4934 "set_win_timer",
4935 "kill_win_timer",
4936 "is_window_hung",
4937 "get_serial_info",
4938 "set_serial_info",
4939 "register_async",
4940 "cancel_async",
4941 "read",
4942 "write",
4943 "ioctl",
4944 "set_irp_result",
4945 "get_irp_result",
4946 "create_named_pipe",
4947 "get_named_pipe_info",
4948 "set_named_pipe_info",
4949 "create_window",
4950 "destroy_window",
4951 "get_desktop_window",
4952 "set_window_owner",
4953 "get_window_info",
4954 "set_window_info",
4955 "set_parent",
4956 "get_window_parents",
4957 "get_window_children",
4958 "get_window_children_from_point",
4959 "get_window_tree",
4960 "set_window_pos",
4961 "get_window_rectangles",
4962 "get_window_text",
4963 "set_window_text",
4964 "get_windows_offset",
4965 "get_visible_region",
4966 "get_surface_region",
4967 "get_window_region",
4968 "set_window_region",
4969 "get_update_region",
4970 "update_window_zorder",
4971 "redraw_window",
4972 "set_window_property",
4973 "remove_window_property",
4974 "get_window_property",
4975 "get_window_properties",
4976 "create_winstation",
4977 "open_winstation",
4978 "close_winstation",
4979 "get_process_winstation",
4980 "set_process_winstation",
4981 "enum_winstation",
4982 "create_desktop",
4983 "open_desktop",
4984 "open_input_desktop",
4985 "close_desktop",
4986 "get_thread_desktop",
4987 "set_thread_desktop",
4988 "enum_desktop",
4989 "set_user_object_info",
4990 "register_hotkey",
4991 "unregister_hotkey",
4992 "attach_thread_input",
4993 "get_thread_input",
4994 "get_last_input_time",
4995 "get_key_state",
4996 "set_key_state",
4997 "set_foreground_window",
4998 "set_focus_window",
4999 "set_active_window",
5000 "set_capture_window",
5001 "set_caret_window",
5002 "set_caret_info",
5003 "set_hook",
5004 "remove_hook",
5005 "start_hook_chain",
5006 "finish_hook_chain",
5007 "get_hook_info",
5008 "create_class",
5009 "destroy_class",
5010 "set_class_info",
5011 "set_clipboard_info",
5012 "empty_clipboard",
5013 "open_token",
5014 "set_global_windows",
5015 "adjust_token_privileges",
5016 "get_token_privileges",
5017 "check_token_privileges",
5018 "duplicate_token",
5019 "access_check",
5020 "get_token_sid",
5021 "get_token_groups",
5022 "get_token_default_dacl",
5023 "set_token_default_dacl",
5024 "set_security_object",
5025 "get_security_object",
5026 "create_mailslot",
5027 "set_mailslot_info",
5028 "create_directory",
5029 "open_directory",
5030 "get_directory_entry",
5031 "create_symlink",
5032 "open_symlink",
5033 "query_symlink",
5034 "get_object_info",
5035 "get_object_type",
5036 "unlink_object",
5037 "get_token_impersonation_level",
5038 "allocate_locally_unique_id",
5039 "create_device_manager",
5040 "create_device",
5041 "delete_device",
5042 "get_next_device_request",
5043 "make_process_system",
5044 "get_token_statistics",
5045 "create_completion",
5046 "open_completion",
5047 "add_completion",
5048 "remove_completion",
5049 "query_completion",
5050 "set_completion_info",
5051 "add_fd_completion",
5052 "get_window_layered_info",
5053 "set_window_layered_info",
5054 "alloc_user_handle",
5055 "free_user_handle",
5056 "set_cursor",
5057 "update_rawinput_devices",
5058 "get_suspend_context",
5059 "set_suspend_context",
5060 "create_job",
5061 "assign_job",
5062 "process_in_job",
5063 "set_job_limits",
5064 "set_job_completion_port",
5065 "terminate_job",
5068 static const struct
5070 const char *name;
5071 unsigned int value;
5072 } status_names[] =
5074 { "ABANDONED_WAIT_0", STATUS_ABANDONED_WAIT_0 },
5075 { "ACCESS_DENIED", STATUS_ACCESS_DENIED },
5076 { "ACCESS_VIOLATION", STATUS_ACCESS_VIOLATION },
5077 { "ADDRESS_ALREADY_ASSOCIATED", STATUS_ADDRESS_ALREADY_ASSOCIATED },
5078 { "ALERTED", STATUS_ALERTED },
5079 { "ALIAS_EXISTS", STATUS_ALIAS_EXISTS },
5080 { "BAD_DEVICE_TYPE", STATUS_BAD_DEVICE_TYPE },
5081 { "BAD_IMPERSONATION_LEVEL", STATUS_BAD_IMPERSONATION_LEVEL },
5082 { "BREAKPOINT", STATUS_BREAKPOINT },
5083 { "BUFFER_OVERFLOW", STATUS_BUFFER_OVERFLOW },
5084 { "BUFFER_TOO_SMALL", STATUS_BUFFER_TOO_SMALL },
5085 { "CANCELLED", STATUS_CANCELLED },
5086 { "CANNOT_DELETE", STATUS_CANNOT_DELETE },
5087 { "CANT_OPEN_ANONYMOUS", STATUS_CANT_OPEN_ANONYMOUS },
5088 { "CANT_WAIT", STATUS_CANT_WAIT },
5089 { "CHILD_MUST_BE_VOLATILE", STATUS_CHILD_MUST_BE_VOLATILE },
5090 { "CONNECTION_ABORTED", STATUS_CONNECTION_ABORTED },
5091 { "CONNECTION_DISCONNECTED", STATUS_CONNECTION_DISCONNECTED },
5092 { "CONNECTION_REFUSED", STATUS_CONNECTION_REFUSED },
5093 { "CONNECTION_RESET", STATUS_CONNECTION_RESET },
5094 { "DEBUGGER_INACTIVE", STATUS_DEBUGGER_INACTIVE },
5095 { "DEVICE_BUSY", STATUS_DEVICE_BUSY },
5096 { "DIRECTORY_NOT_EMPTY", STATUS_DIRECTORY_NOT_EMPTY },
5097 { "DISK_FULL", STATUS_DISK_FULL },
5098 { "DLL_NOT_FOUND", STATUS_DLL_NOT_FOUND },
5099 { "ERROR_CLASS_ALREADY_EXISTS", 0xc0010000 | ERROR_CLASS_ALREADY_EXISTS },
5100 { "ERROR_CLASS_DOES_NOT_EXIST", 0xc0010000 | ERROR_CLASS_DOES_NOT_EXIST },
5101 { "ERROR_CLASS_HAS_WINDOWS", 0xc0010000 | ERROR_CLASS_HAS_WINDOWS },
5102 { "ERROR_CLIPBOARD_NOT_OPEN", 0xc0010000 | ERROR_CLIPBOARD_NOT_OPEN },
5103 { "ERROR_HOTKEY_ALREADY_REGISTERED", 0xc0010000 | ERROR_HOTKEY_ALREADY_REGISTERED },
5104 { "ERROR_HOTKEY_NOT_REGISTERED", 0xc0010000 | ERROR_HOTKEY_NOT_REGISTERED },
5105 { "ERROR_INVALID_CURSOR_HANDLE", 0xc0010000 | ERROR_INVALID_CURSOR_HANDLE },
5106 { "ERROR_INVALID_INDEX", 0xc0010000 | ERROR_INVALID_INDEX },
5107 { "ERROR_INVALID_WINDOW_HANDLE", 0xc0010000 | ERROR_INVALID_WINDOW_HANDLE },
5108 { "ERROR_WINDOW_OF_OTHER_THREAD", 0xc0010000 | ERROR_WINDOW_OF_OTHER_THREAD },
5109 { "FILE_DELETED", STATUS_FILE_DELETED },
5110 { "FILE_IS_A_DIRECTORY", STATUS_FILE_IS_A_DIRECTORY },
5111 { "FILE_LOCK_CONFLICT", STATUS_FILE_LOCK_CONFLICT },
5112 { "GENERIC_NOT_MAPPED", STATUS_GENERIC_NOT_MAPPED },
5113 { "HANDLES_CLOSED", STATUS_HANDLES_CLOSED },
5114 { "HANDLE_NOT_CLOSABLE", STATUS_HANDLE_NOT_CLOSABLE },
5115 { "HOST_UNREACHABLE", STATUS_HOST_UNREACHABLE },
5116 { "ILLEGAL_FUNCTION", STATUS_ILLEGAL_FUNCTION },
5117 { "INSTANCE_NOT_AVAILABLE", STATUS_INSTANCE_NOT_AVAILABLE },
5118 { "INSUFFICIENT_RESOURCES", STATUS_INSUFFICIENT_RESOURCES },
5119 { "INVALID_CID", STATUS_INVALID_CID },
5120 { "INVALID_DEVICE_REQUEST", STATUS_INVALID_DEVICE_REQUEST },
5121 { "INVALID_FILE_FOR_SECTION", STATUS_INVALID_FILE_FOR_SECTION },
5122 { "INVALID_HANDLE", STATUS_INVALID_HANDLE },
5123 { "INVALID_IMAGE_FORMAT", STATUS_INVALID_IMAGE_FORMAT },
5124 { "INVALID_IMAGE_NE_FORMAT", STATUS_INVALID_IMAGE_NE_FORMAT },
5125 { "INVALID_IMAGE_NOT_MZ", STATUS_INVALID_IMAGE_NOT_MZ },
5126 { "INVALID_IMAGE_PROTECT", STATUS_INVALID_IMAGE_PROTECT },
5127 { "INVALID_IMAGE_WIN_64", STATUS_INVALID_IMAGE_WIN_64 },
5128 { "INVALID_PARAMETER", STATUS_INVALID_PARAMETER },
5129 { "INVALID_SECURITY_DESCR", STATUS_INVALID_SECURITY_DESCR },
5130 { "IO_TIMEOUT", STATUS_IO_TIMEOUT },
5131 { "KEY_DELETED", STATUS_KEY_DELETED },
5132 { "MAPPED_FILE_SIZE_ZERO", STATUS_MAPPED_FILE_SIZE_ZERO },
5133 { "MORE_PROCESSING_REQUIRED", STATUS_MORE_PROCESSING_REQUIRED },
5134 { "MUTANT_NOT_OWNED", STATUS_MUTANT_NOT_OWNED },
5135 { "NAME_TOO_LONG", STATUS_NAME_TOO_LONG },
5136 { "NETWORK_BUSY", STATUS_NETWORK_BUSY },
5137 { "NETWORK_UNREACHABLE", STATUS_NETWORK_UNREACHABLE },
5138 { "NOT_ALL_ASSIGNED", STATUS_NOT_ALL_ASSIGNED },
5139 { "NOT_A_DIRECTORY", STATUS_NOT_A_DIRECTORY },
5140 { "NOT_FOUND", STATUS_NOT_FOUND },
5141 { "NOT_IMPLEMENTED", STATUS_NOT_IMPLEMENTED },
5142 { "NOT_REGISTRY_FILE", STATUS_NOT_REGISTRY_FILE },
5143 { "NOT_SUPPORTED", STATUS_NOT_SUPPORTED },
5144 { "NO_DATA_DETECTED", STATUS_NO_DATA_DETECTED },
5145 { "NO_IMPERSONATION_TOKEN", STATUS_NO_IMPERSONATION_TOKEN },
5146 { "NO_MEMORY", STATUS_NO_MEMORY },
5147 { "NO_MORE_ENTRIES", STATUS_NO_MORE_ENTRIES },
5148 { "NO_MORE_FILES", STATUS_NO_MORE_FILES },
5149 { "NO_SUCH_DEVICE", STATUS_NO_SUCH_DEVICE },
5150 { "NO_SUCH_FILE", STATUS_NO_SUCH_FILE },
5151 { "NO_TOKEN", STATUS_NO_TOKEN },
5152 { "OBJECT_NAME_COLLISION", STATUS_OBJECT_NAME_COLLISION },
5153 { "OBJECT_NAME_EXISTS", STATUS_OBJECT_NAME_EXISTS },
5154 { "OBJECT_NAME_INVALID", STATUS_OBJECT_NAME_INVALID },
5155 { "OBJECT_NAME_NOT_FOUND", STATUS_OBJECT_NAME_NOT_FOUND },
5156 { "OBJECT_PATH_INVALID", STATUS_OBJECT_PATH_INVALID },
5157 { "OBJECT_PATH_NOT_FOUND", STATUS_OBJECT_PATH_NOT_FOUND },
5158 { "OBJECT_PATH_SYNTAX_BAD", STATUS_OBJECT_PATH_SYNTAX_BAD },
5159 { "OBJECT_TYPE_MISMATCH", STATUS_OBJECT_TYPE_MISMATCH },
5160 { "PENDING", STATUS_PENDING },
5161 { "PIPE_BUSY", STATUS_PIPE_BUSY },
5162 { "PIPE_CONNECTED", STATUS_PIPE_CONNECTED },
5163 { "PIPE_DISCONNECTED", STATUS_PIPE_DISCONNECTED },
5164 { "PIPE_LISTENING", STATUS_PIPE_LISTENING },
5165 { "PIPE_NOT_AVAILABLE", STATUS_PIPE_NOT_AVAILABLE },
5166 { "PRIVILEGE_NOT_HELD", STATUS_PRIVILEGE_NOT_HELD },
5167 { "PROCESS_IN_JOB", STATUS_PROCESS_IN_JOB },
5168 { "PROCESS_IS_TERMINATING", STATUS_PROCESS_IS_TERMINATING },
5169 { "SECTION_TOO_BIG", STATUS_SECTION_TOO_BIG },
5170 { "SEMAPHORE_LIMIT_EXCEEDED", STATUS_SEMAPHORE_LIMIT_EXCEEDED },
5171 { "SHARING_VIOLATION", STATUS_SHARING_VIOLATION },
5172 { "SHUTDOWN_IN_PROGRESS", STATUS_SHUTDOWN_IN_PROGRESS },
5173 { "SUSPEND_COUNT_EXCEEDED", STATUS_SUSPEND_COUNT_EXCEEDED },
5174 { "THREAD_IS_TERMINATING", STATUS_THREAD_IS_TERMINATING },
5175 { "TIMEOUT", STATUS_TIMEOUT },
5176 { "TOO_MANY_OPENED_FILES", STATUS_TOO_MANY_OPENED_FILES },
5177 { "UNSUCCESSFUL", STATUS_UNSUCCESSFUL },
5178 { "USER_APC", STATUS_USER_APC },
5179 { "USER_MAPPED_FILE", STATUS_USER_MAPPED_FILE },
5180 { "VOLUME_DISMOUNTED", STATUS_VOLUME_DISMOUNTED },
5181 { "WAS_LOCKED", STATUS_WAS_LOCKED },
5182 { NULL, 0 }
5185 /* ### make_requests end ### */
5186 /* Everything above this line is generated automatically by tools/make_requests */
5188 static const char *get_status_name( unsigned int status )
5190 int i;
5191 static char buffer[10];
5193 if (status)
5195 for (i = 0; status_names[i].name; i++)
5196 if (status_names[i].value == status) return status_names[i].name;
5198 sprintf( buffer, "%x", status );
5199 return buffer;
5202 void trace_request(void)
5204 enum request req = current->req.request_header.req;
5205 if (req < REQ_NB_REQUESTS)
5207 fprintf( stderr, "%04x: %s(", current->id, req_names[req] );
5208 if (req_dumpers[req])
5210 cur_data = get_req_data();
5211 cur_size = get_req_data_size();
5212 req_dumpers[req]( &current->req );
5214 fprintf( stderr, " )\n" );
5216 else fprintf( stderr, "%04x: %d(?)\n", current->id, req );
5219 void trace_reply( enum request req, const union generic_reply *reply )
5221 if (req < REQ_NB_REQUESTS)
5223 fprintf( stderr, "%04x: %s() = %s",
5224 current->id, req_names[req], get_status_name(current->error) );
5225 if (reply_dumpers[req])
5227 fprintf( stderr, " {" );
5228 cur_data = current->reply_data;
5229 cur_size = reply->reply_header.reply_size;
5230 reply_dumpers[req]( reply );
5231 fprintf( stderr, " }" );
5233 fputc( '\n', stderr );
5235 else fprintf( stderr, "%04x: %d() = %s\n",
5236 current->id, req, get_status_name(current->error) );