windowscodecs: Add tests for DdsFrameDecode_Dds_CopyBlocks().
[wine.git] / server / trace.c
blob555e6976576bbc6f1618ae21a80f5184ad6ac4d5
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 #include "ddk/ntddser.h"
43 #define USE_WS_PREFIX
44 #include "winsock2.h"
45 #include "file.h"
46 #include "request.h"
47 #include "unicode.h"
49 static const void *cur_data;
50 static data_size_t cur_size;
52 static const char *get_status_name( unsigned int status );
54 /* utility functions */
56 static inline void remove_data( data_size_t size )
58 cur_data = (const char *)cur_data + size;
59 cur_size -= size;
62 static void dump_uints( const char *prefix, const unsigned int *ptr, int len )
64 fprintf( stderr, "%s{", prefix );
65 while (len > 0)
67 fprintf( stderr, "%08x", *ptr++ );
68 if (--len) fputc( ',', stderr );
70 fputc( '}', stderr );
73 static void dump_handles( const char *prefix, const obj_handle_t *data, data_size_t size )
75 data_size_t len = size / sizeof(*data);
77 fprintf( stderr,"%s{", prefix );
78 while (len > 0)
80 fprintf( stderr, "%04x", *data++ );
81 if (--len) fputc( ',', stderr );
83 fputc( '}', stderr );
86 static void dump_timeout( const char *prefix, const timeout_t *time )
88 fprintf( stderr, "%s%s", prefix, get_timeout_str(*time) );
91 static void dump_abstime( const char *prefix, const abstime_t *when )
93 timeout_t timeout = abstime_to_timeout( *when );
94 dump_timeout( prefix, &timeout );
97 static void dump_uint64( const char *prefix, const unsigned __int64 *val )
99 if ((unsigned int)*val != *val)
100 fprintf( stderr, "%s%x%08x", prefix, (unsigned int)(*val >> 32), (unsigned int)*val );
101 else
102 fprintf( stderr, "%s%08x", prefix, (unsigned int)*val );
105 static void dump_rectangle( const char *prefix, const rectangle_t *rect )
107 fprintf( stderr, "%s{%d,%d;%d,%d}", prefix,
108 rect->left, rect->top, rect->right, rect->bottom );
111 static void dump_char_info( const char *prefix, const char_info_t *info )
113 fprintf( stderr, "%s{'", prefix );
114 dump_strW( &info->ch, sizeof(info->ch), stderr, "\'\'" );
115 fprintf( stderr, "',%04x}", info->attr );
118 static void dump_ioctl_code( const char *prefix, const ioctl_code_t *code )
120 switch(*code)
122 #define CASE(c) case c: fprintf( stderr, "%s%s", prefix, #c ); break
123 CASE(FSCTL_DISMOUNT_VOLUME);
124 CASE(FSCTL_PIPE_DISCONNECT);
125 CASE(FSCTL_PIPE_LISTEN);
126 CASE(FSCTL_PIPE_PEEK);
127 CASE(FSCTL_PIPE_WAIT);
128 CASE(IOCTL_SERIAL_GET_TIMEOUTS);
129 CASE(IOCTL_SERIAL_GET_WAIT_MASK);
130 CASE(IOCTL_SERIAL_SET_TIMEOUTS);
131 CASE(IOCTL_SERIAL_SET_WAIT_MASK);
132 CASE(WS_SIO_ADDRESS_LIST_CHANGE);
133 default: fprintf( stderr, "%s%08x", prefix, *code ); break;
134 #undef CASE
138 static void dump_client_cpu( const char *prefix, const client_cpu_t *code )
140 switch (*code)
142 #define CASE(c) case CPU_##c: fprintf( stderr, "%s%s", prefix, #c ); break
143 CASE(x86);
144 CASE(x86_64);
145 CASE(POWERPC);
146 CASE(ARM);
147 CASE(ARM64);
148 default: fprintf( stderr, "%s%u", prefix, *code ); break;
149 #undef CASE
153 static void dump_apc_call( const char *prefix, const apc_call_t *call )
155 fprintf( stderr, "%s{", prefix );
156 switch(call->type)
158 case APC_NONE:
159 fprintf( stderr, "APC_NONE" );
160 break;
161 case APC_USER:
162 dump_uint64( "APC_USER,func=", &call->user.user.func );
163 dump_uint64( ",args={", &call->user.user.args[0] );
164 dump_uint64( ",", &call->user.user.args[1] );
165 dump_uint64( ",", &call->user.user.args[2] );
166 fputc( '}', stderr );
167 break;
168 case APC_TIMER:
169 dump_timeout( "APC_TIMER,time=", &call->user.timer.time );
170 dump_uint64( ",arg=", &call->user.timer.arg );
171 break;
172 case APC_ASYNC_IO:
173 dump_uint64( "APC_ASYNC_IO,user=", &call->async_io.user );
174 dump_uint64( ",sb=", &call->async_io.sb );
175 fprintf( stderr, ",status=%s", get_status_name(call->async_io.status) );
176 break;
177 case APC_VIRTUAL_ALLOC:
178 dump_uint64( "APC_VIRTUAL_ALLOC,addr==", &call->virtual_alloc.addr );
179 dump_uint64( ",size=", &call->virtual_alloc.size );
180 dump_uint64( ",zero_bits=", &call->virtual_alloc.zero_bits );
181 fprintf( stderr, ",op_type=%x,prot=%x", call->virtual_alloc.op_type, call->virtual_alloc.prot );
182 break;
183 case APC_VIRTUAL_FREE:
184 dump_uint64( "APC_VIRTUAL_FREE,addr=", &call->virtual_free.addr );
185 dump_uint64( ",size=", &call->virtual_free.size );
186 fprintf( stderr, ",op_type=%x", call->virtual_free.op_type );
187 break;
188 case APC_VIRTUAL_QUERY:
189 dump_uint64( "APC_VIRTUAL_QUERY,addr=", &call->virtual_query.addr );
190 break;
191 case APC_VIRTUAL_PROTECT:
192 dump_uint64( "APC_VIRTUAL_PROTECT,addr=", &call->virtual_protect.addr );
193 dump_uint64( ",size=", &call->virtual_protect.size );
194 fprintf( stderr, ",prot=%x", call->virtual_protect.prot );
195 break;
196 case APC_VIRTUAL_FLUSH:
197 dump_uint64( "APC_VIRTUAL_FLUSH,addr=", &call->virtual_flush.addr );
198 dump_uint64( ",size=", &call->virtual_flush.size );
199 break;
200 case APC_VIRTUAL_LOCK:
201 dump_uint64( "APC_VIRTUAL_LOCK,addr=", &call->virtual_lock.addr );
202 dump_uint64( ",size=", &call->virtual_lock.size );
203 break;
204 case APC_VIRTUAL_UNLOCK:
205 dump_uint64( "APC_VIRTUAL_UNLOCK,addr=", &call->virtual_unlock.addr );
206 dump_uint64( ",size=", &call->virtual_unlock.size );
207 break;
208 case APC_MAP_VIEW:
209 fprintf( stderr, "APC_MAP_VIEW,handle=%04x", call->map_view.handle );
210 dump_uint64( ",addr=", &call->map_view.addr );
211 dump_uint64( ",size=", &call->map_view.size );
212 dump_uint64( ",offset=", &call->map_view.offset );
213 dump_uint64( ",zero_bits=", &call->map_view.zero_bits );
214 fprintf( stderr, ",alloc_type=%x,prot=%x", call->map_view.alloc_type, call->map_view.prot );
215 break;
216 case APC_UNMAP_VIEW:
217 dump_uint64( "APC_UNMAP_VIEW,addr=", &call->unmap_view.addr );
218 break;
219 case APC_CREATE_THREAD:
220 dump_uint64( "APC_CREATE_THREAD,func=", &call->create_thread.func );
221 dump_uint64( ",arg=", &call->create_thread.arg );
222 dump_uint64( ",reserve=", &call->create_thread.reserve );
223 dump_uint64( ",commit=", &call->create_thread.commit );
224 fprintf( stderr, ",suspend=%u", call->create_thread.suspend );
225 break;
226 case APC_BREAK_PROCESS:
227 fprintf( stderr, "APC_BREAK_PROCESS" );
228 break;
229 default:
230 fprintf( stderr, "type=%u", call->type );
231 break;
233 fputc( '}', stderr );
236 static void dump_apc_result( const char *prefix, const apc_result_t *result )
238 fprintf( stderr, "%s{", prefix );
239 switch(result->type)
241 case APC_NONE:
242 break;
243 case APC_ASYNC_IO:
244 fprintf( stderr, "APC_ASYNC_IO,status=%s,total=%u",
245 get_status_name( result->async_io.status ), result->async_io.total );
246 break;
247 case APC_VIRTUAL_ALLOC:
248 fprintf( stderr, "APC_VIRTUAL_ALLOC,status=%s",
249 get_status_name( result->virtual_alloc.status ));
250 dump_uint64( ",addr=", &result->virtual_alloc.addr );
251 dump_uint64( ",size=", &result->virtual_alloc.size );
252 break;
253 case APC_VIRTUAL_FREE:
254 fprintf( stderr, "APC_VIRTUAL_FREE,status=%s",
255 get_status_name( result->virtual_free.status ));
256 dump_uint64( ",addr=", &result->virtual_free.addr );
257 dump_uint64( ",size=", &result->virtual_free.size );
258 break;
259 case APC_VIRTUAL_QUERY:
260 fprintf( stderr, "APC_VIRTUAL_QUERY,status=%s",
261 get_status_name( result->virtual_query.status ));
262 dump_uint64( ",base=", &result->virtual_query.base );
263 dump_uint64( ",alloc_base=", &result->virtual_query.alloc_base );
264 dump_uint64( ",size=", &result->virtual_query.size );
265 fprintf( stderr, ",state=%x,prot=%x,alloc_prot=%x,alloc_type=%x",
266 result->virtual_query.state, result->virtual_query.prot,
267 result->virtual_query.alloc_prot, result->virtual_query.alloc_type );
268 break;
269 case APC_VIRTUAL_PROTECT:
270 fprintf( stderr, "APC_VIRTUAL_PROTECT,status=%s",
271 get_status_name( result->virtual_protect.status ));
272 dump_uint64( ",addr=", &result->virtual_protect.addr );
273 dump_uint64( ",size=", &result->virtual_protect.size );
274 fprintf( stderr, ",prot=%x", result->virtual_protect.prot );
275 break;
276 case APC_VIRTUAL_FLUSH:
277 fprintf( stderr, "APC_VIRTUAL_FLUSH,status=%s",
278 get_status_name( result->virtual_flush.status ));
279 dump_uint64( ",addr=", &result->virtual_flush.addr );
280 dump_uint64( ",size=", &result->virtual_flush.size );
281 break;
282 case APC_VIRTUAL_LOCK:
283 fprintf( stderr, "APC_VIRTUAL_LOCK,status=%s",
284 get_status_name( result->virtual_lock.status ));
285 dump_uint64( ",addr=", &result->virtual_lock.addr );
286 dump_uint64( ",size=", &result->virtual_lock.size );
287 break;
288 case APC_VIRTUAL_UNLOCK:
289 fprintf( stderr, "APC_VIRTUAL_UNLOCK,status=%s",
290 get_status_name( result->virtual_unlock.status ));
291 dump_uint64( ",addr=", &result->virtual_unlock.addr );
292 dump_uint64( ",size=", &result->virtual_unlock.size );
293 break;
294 case APC_MAP_VIEW:
295 fprintf( stderr, "APC_MAP_VIEW,status=%s",
296 get_status_name( result->map_view.status ));
297 dump_uint64( ",addr=", &result->map_view.addr );
298 dump_uint64( ",size=", &result->map_view.size );
299 break;
300 case APC_UNMAP_VIEW:
301 fprintf( stderr, "APC_UNMAP_VIEW,status=%s",
302 get_status_name( result->unmap_view.status ) );
303 break;
304 case APC_CREATE_THREAD:
305 fprintf( stderr, "APC_CREATE_THREAD,status=%s,tid=%04x,handle=%04x",
306 get_status_name( result->create_thread.status ),
307 result->create_thread.tid, result->create_thread.handle );
308 break;
309 case APC_BREAK_PROCESS:
310 fprintf( stderr, "APC_BREAK_PROCESS,status=%s", get_status_name( result->break_process.status ) );
311 break;
312 default:
313 fprintf( stderr, "type=%u", result->type );
314 break;
316 fputc( '}', stderr );
319 static void dump_async_data( const char *prefix, const async_data_t *data )
321 fprintf( stderr, "%s{handle=%04x,event=%04x", prefix, data->handle, data->event );
322 dump_uint64( ",iosb=", &data->iosb );
323 dump_uint64( ",user=", &data->user );
324 dump_uint64( ",apc=", &data->apc );
325 dump_uint64( ",apc_context=", &data->apc_context );
326 fputc( '}', stderr );
329 static void dump_irp_params( const char *prefix, const irp_params_t *data )
331 switch (data->type)
333 case IRP_CALL_NONE:
334 fprintf( stderr, "%s{NONE}", prefix );
335 break;
336 case IRP_CALL_CREATE:
337 fprintf( stderr, "%s{CREATE,access=%08x,sharing=%08x,options=%08x",
338 prefix, data->create.access, data->create.sharing, data->create.options );
339 dump_uint64( ",device=", &data->create.device );
340 fprintf( stderr, ",file=%08x}", data->create.file );
341 break;
342 case IRP_CALL_CLOSE:
343 fprintf( stderr, "%s{CLOSE", prefix );
344 dump_uint64( ",file=", &data->close.file );
345 fputc( '}', stderr );
346 break;
347 case IRP_CALL_READ:
348 fprintf( stderr, "%s{READ,key=%08x,out_size=%u", prefix, data->read.key,
349 data->read.out_size );
350 dump_uint64( ",pos=", &data->read.pos );
351 dump_uint64( ",file=", &data->read.file );
352 fputc( '}', stderr );
353 break;
354 case IRP_CALL_WRITE:
355 fprintf( stderr, "%s{WRITE,key=%08x", prefix, data->write.key );
356 dump_uint64( ",pos=", &data->write.pos );
357 dump_uint64( ",file=", &data->write.file );
358 fputc( '}', stderr );
359 break;
360 case IRP_CALL_FLUSH:
361 fprintf( stderr, "%s{FLUSH", prefix );
362 dump_uint64( ",file=", &data->flush.file );
363 fputc( '}', stderr );
364 break;
365 case IRP_CALL_IOCTL:
366 fprintf( stderr, "%s{IOCTL", prefix );
367 dump_ioctl_code( ",code=", &data->ioctl.code );
368 fprintf( stderr, ",out_size=%u", data->ioctl.out_size );
369 dump_uint64( ",file=", &data->ioctl.file );
370 fputc( '}', stderr );
371 break;
372 case IRP_CALL_FREE:
373 fprintf( stderr, "%s{FREE", prefix );
374 dump_uint64( ",obj=", &data->free.obj );
375 fputc( '}', stderr );
376 break;
377 case IRP_CALL_CANCEL:
378 fprintf( stderr, "%s{CANCEL", prefix );
379 dump_uint64( ",irp=", &data->cancel.irp );
380 fputc( '}', stderr );
381 break;
385 static void dump_hw_input( const char *prefix, const hw_input_t *input )
387 switch (input->type)
389 case INPUT_MOUSE:
390 fprintf( stderr, "%s{type=MOUSE,x=%d,y=%d,data=%08x,flags=%08x,time=%u",
391 prefix, input->mouse.x, input->mouse.y, input->mouse.data, input->mouse.flags,
392 input->mouse.time );
393 dump_uint64( ",info=", &input->mouse.info );
394 fputc( '}', stderr );
395 break;
396 case INPUT_KEYBOARD:
397 fprintf( stderr, "%s{type=KEYBOARD,vkey=%04hx,scan=%04hx,flags=%08x,time=%u",
398 prefix, input->kbd.vkey, input->kbd.scan, input->kbd.flags, input->kbd.time );
399 dump_uint64( ",info=", &input->kbd.info );
400 fputc( '}', stderr );
401 break;
402 case INPUT_HARDWARE:
403 fprintf( stderr, "%s{type=HARDWARE,msg=%04x", prefix, input->hw.msg );
404 dump_uint64( ",lparam=", &input->hw.lparam );
405 fputc( '}', stderr );
406 break;
407 default:
408 fprintf( stderr, "%s{type=%04x}", prefix, input->type );
409 break;
413 static void dump_luid( const char *prefix, const luid_t *luid )
415 fprintf( stderr, "%s%d.%u", prefix, luid->high_part, luid->low_part );
418 static void dump_varargs_ints( const char *prefix, data_size_t size )
420 const int *data = cur_data;
421 data_size_t len = size / sizeof(*data);
423 fprintf( stderr,"%s{", prefix );
424 while (len > 0)
426 fprintf( stderr, "%d", *data++ );
427 if (--len) fputc( ',', stderr );
429 fputc( '}', stderr );
430 remove_data( size );
433 static void dump_varargs_uints( const char *prefix, data_size_t size )
435 const unsigned int *data = cur_data;
437 dump_uints( prefix, data, size / sizeof(*data) );
438 remove_data( size );
441 static void dump_varargs_uints64( const char *prefix, data_size_t size )
443 const unsigned __int64 *data = cur_data;
444 data_size_t len = size / sizeof(*data);
446 fprintf( stderr,"%s{", prefix );
447 while (len > 0)
449 dump_uint64( "", data++ );
450 if (--len) fputc( ',', stderr );
452 fputc( '}', stderr );
453 remove_data( size );
456 static void dump_varargs_apc_result( const char *prefix, data_size_t size )
458 const apc_result_t *result = cur_data;
460 if (size >= sizeof(*result))
462 dump_apc_result( prefix, result );
463 size = sizeof(*result);
465 remove_data( size );
468 static void dump_varargs_select_op( const char *prefix, data_size_t size )
470 select_op_t data;
472 if (!size)
474 fprintf( stderr, "%s{}", prefix );
475 return;
477 memset( &data, 0, sizeof(data) );
478 memcpy( &data, cur_data, min( size, sizeof(data) ));
480 fprintf( stderr, "%s{", prefix );
481 switch (data.op)
483 case SELECT_NONE:
484 fprintf( stderr, "NONE" );
485 break;
486 case SELECT_WAIT:
487 case SELECT_WAIT_ALL:
488 fprintf( stderr, "%s", data.op == SELECT_WAIT ? "WAIT" : "WAIT_ALL" );
489 if (size > offsetof( select_op_t, wait.handles ))
490 dump_handles( ",handles=", data.wait.handles,
491 min( size, sizeof(data.wait) ) - offsetof( select_op_t, wait.handles ));
492 break;
493 case SELECT_SIGNAL_AND_WAIT:
494 fprintf( stderr, "SIGNAL_AND_WAIT,signal=%04x,wait=%04x",
495 data.signal_and_wait.signal, data.signal_and_wait.wait );
496 break;
497 case SELECT_KEYED_EVENT_WAIT:
498 case SELECT_KEYED_EVENT_RELEASE:
499 fprintf( stderr, "KEYED_EVENT_%s,handle=%04x",
500 data.op == SELECT_KEYED_EVENT_WAIT ? "WAIT" : "RELEASE",
501 data.keyed_event.handle );
502 dump_uint64( ",key=", &data.keyed_event.key );
503 break;
504 default:
505 fprintf( stderr, "op=%u", data.op );
506 break;
508 fputc( '}', stderr );
509 remove_data( size );
512 static void dump_varargs_user_handles( const char *prefix, data_size_t size )
514 const user_handle_t *data = cur_data;
515 data_size_t len = size / sizeof(*data);
517 fprintf( stderr,"%s{", prefix );
518 while (len > 0)
520 fprintf( stderr, "%08x", *data++ );
521 if (--len) fputc( ',', stderr );
523 fputc( '}', stderr );
524 remove_data( size );
527 static void dump_varargs_bytes( const char *prefix, data_size_t size )
529 const unsigned char *data = cur_data;
530 data_size_t len = min( 1024, size );
532 fprintf( stderr,"%s{", prefix );
533 while (len > 0)
535 fprintf( stderr, "%02x", *data++ );
536 if (--len) fputc( ',', stderr );
538 if (size > 1024) fprintf( stderr, "...(total %u)", size );
539 fputc( '}', stderr );
540 remove_data( size );
543 static void dump_varargs_string( const char *prefix, data_size_t size )
545 fprintf( stderr, "%s\"%.*s\"", prefix, (int)size, (const char *)cur_data );
546 remove_data( size );
549 static void dump_varargs_unicode_str( const char *prefix, data_size_t size )
551 fprintf( stderr, "%sL\"", prefix );
552 dump_strW( cur_data, size, stderr, "\"\"" );
553 fputc( '\"', stderr );
554 remove_data( size );
557 static void dump_varargs_context( const char *prefix, data_size_t size )
559 const context_t *context = cur_data;
560 context_t ctx;
561 unsigned int i;
563 if (!size)
565 fprintf( stderr, "%s{}", prefix );
566 return;
568 size = min( size, sizeof(ctx) );
569 memset( &ctx, 0, sizeof(ctx) );
570 memcpy( &ctx, context, size );
572 fprintf( stderr,"%s{", prefix );
573 dump_client_cpu( "cpu=", &ctx.cpu );
574 switch (ctx.cpu)
576 case CPU_x86:
577 if (ctx.flags & SERVER_CTX_CONTROL)
578 fprintf( stderr, ",eip=%08x,esp=%08x,ebp=%08x,eflags=%08x,cs=%04x,ss=%04x",
579 ctx.ctl.i386_regs.eip, ctx.ctl.i386_regs.esp, ctx.ctl.i386_regs.ebp,
580 ctx.ctl.i386_regs.eflags, ctx.ctl.i386_regs.cs, ctx.ctl.i386_regs.ss );
581 if (ctx.flags & SERVER_CTX_SEGMENTS)
582 fprintf( stderr, ",ds=%04x,es=%04x,fs=%04x,gs=%04x",
583 ctx.seg.i386_regs.ds, ctx.seg.i386_regs.es,
584 ctx.seg.i386_regs.fs, ctx.seg.i386_regs.gs );
585 if (ctx.flags & SERVER_CTX_INTEGER)
586 fprintf( stderr, ",eax=%08x,ebx=%08x,ecx=%08x,edx=%08x,esi=%08x,edi=%08x",
587 ctx.integer.i386_regs.eax, ctx.integer.i386_regs.ebx, ctx.integer.i386_regs.ecx,
588 ctx.integer.i386_regs.edx, ctx.integer.i386_regs.esi, ctx.integer.i386_regs.edi );
589 if (ctx.flags & SERVER_CTX_DEBUG_REGISTERS)
590 fprintf( stderr, ",dr0=%08x,dr1=%08x,dr2=%08x,dr3=%08x,dr6=%08x,dr7=%08x",
591 ctx.debug.i386_regs.dr0, ctx.debug.i386_regs.dr1, ctx.debug.i386_regs.dr2,
592 ctx.debug.i386_regs.dr3, ctx.debug.i386_regs.dr6, ctx.debug.i386_regs.dr7 );
593 if (ctx.flags & SERVER_CTX_FLOATING_POINT)
595 fprintf( stderr, ",fp.ctrl=%08x,fp.status=%08x,fp.tag=%08x,fp.err_off=%08x,fp.err_sel=%08x",
596 ctx.fp.i386_regs.ctrl, ctx.fp.i386_regs.status, ctx.fp.i386_regs.tag,
597 ctx.fp.i386_regs.err_off, ctx.fp.i386_regs.err_sel );
598 fprintf( stderr, ",fp.data_off=%08x,fp.data_sel=%08x,fp.cr0npx=%08x",
599 ctx.fp.i386_regs.data_off, ctx.fp.i386_regs.data_sel, ctx.fp.i386_regs.cr0npx );
600 for (i = 0; i < 8; i++)
602 long double reg = 0;
603 memcpy( &reg, &ctx.fp.i386_regs.regs[10 * i], 10 );
604 fprintf( stderr, ",fp.reg%u=%Lg", i, reg );
607 if (ctx.flags & SERVER_CTX_EXTENDED_REGISTERS)
608 dump_uints( ",extended=", (const unsigned int *)ctx.ext.i386_regs,
609 sizeof(ctx.ext.i386_regs) / sizeof(int) );
610 break;
611 case CPU_x86_64:
612 if (ctx.flags & SERVER_CTX_CONTROL)
614 dump_uint64( ",rip=", &ctx.ctl.x86_64_regs.rip );
615 dump_uint64( ",rbp=", &ctx.ctl.x86_64_regs.rbp );
616 dump_uint64( ",rsp=", &ctx.ctl.x86_64_regs.rsp );
617 fprintf( stderr, ",cs=%04x,ss=%04x,flags=%08x",
618 ctx.ctl.x86_64_regs.cs, ctx.ctl.x86_64_regs.ss, ctx.ctl.x86_64_regs.flags );
620 if (ctx.flags & SERVER_CTX_INTEGER)
622 dump_uint64( ",rax=", &ctx.integer.x86_64_regs.rax );
623 dump_uint64( ",rbx=", &ctx.integer.x86_64_regs.rbx );
624 dump_uint64( ",rcx=", &ctx.integer.x86_64_regs.rcx );
625 dump_uint64( ",rdx=", &ctx.integer.x86_64_regs.rdx );
626 dump_uint64( ",rsi=", &ctx.integer.x86_64_regs.rsi );
627 dump_uint64( ",rdi=", &ctx.integer.x86_64_regs.rdi );
628 dump_uint64( ",r8=", &ctx.integer.x86_64_regs.r8 );
629 dump_uint64( ",r9=", &ctx.integer.x86_64_regs.r9 );
630 dump_uint64( ",r10=", &ctx.integer.x86_64_regs.r10 );
631 dump_uint64( ",r11=", &ctx.integer.x86_64_regs.r11 );
632 dump_uint64( ",r12=", &ctx.integer.x86_64_regs.r12 );
633 dump_uint64( ",r13=", &ctx.integer.x86_64_regs.r13 );
634 dump_uint64( ",r14=", &ctx.integer.x86_64_regs.r14 );
635 dump_uint64( ",r15=", &ctx.integer.x86_64_regs.r15 );
637 if (ctx.flags & SERVER_CTX_SEGMENTS)
638 fprintf( stderr, ",ds=%04x,es=%04x,fs=%04x,gs=%04x",
639 ctx.seg.x86_64_regs.ds, ctx.seg.x86_64_regs.es,
640 ctx.seg.x86_64_regs.fs, ctx.seg.x86_64_regs.gs );
641 if (ctx.flags & SERVER_CTX_DEBUG_REGISTERS)
643 dump_uint64( ",dr0=", &ctx.debug.x86_64_regs.dr0 );
644 dump_uint64( ",dr1=", &ctx.debug.x86_64_regs.dr1 );
645 dump_uint64( ",dr2=", &ctx.debug.x86_64_regs.dr2 );
646 dump_uint64( ",dr3=", &ctx.debug.x86_64_regs.dr3 );
647 dump_uint64( ",dr6=", &ctx.debug.x86_64_regs.dr6 );
648 dump_uint64( ",dr7=", &ctx.debug.x86_64_regs.dr7 );
650 if (ctx.flags & SERVER_CTX_FLOATING_POINT)
652 for (i = 0; i < 32; i++)
653 fprintf( stderr, ",fp%u=%08x%08x%08x%08x", i,
654 (unsigned int)(ctx.fp.x86_64_regs.fpregs[i].high >> 32),
655 (unsigned int)ctx.fp.x86_64_regs.fpregs[i].high,
656 (unsigned int)(ctx.fp.x86_64_regs.fpregs[i].low >> 32),
657 (unsigned int)ctx.fp.x86_64_regs.fpregs[i].low );
659 break;
660 case CPU_POWERPC:
661 if (ctx.flags & SERVER_CTX_CONTROL)
662 fprintf( stderr, ",iar=%08x,msr=%08x,ctr=%08x,lr=%08x,dar=%08x,dsisr=%08x,trap=%08x",
663 ctx.ctl.powerpc_regs.iar, ctx.ctl.powerpc_regs.msr, ctx.ctl.powerpc_regs.ctr,
664 ctx.ctl.powerpc_regs.lr, ctx.ctl.powerpc_regs.dar, ctx.ctl.powerpc_regs.dsisr,
665 ctx.ctl.powerpc_regs.trap );
666 if (ctx.flags & SERVER_CTX_INTEGER)
668 for (i = 0; i < 32; i++) fprintf( stderr, ",gpr%u=%08x", i, ctx.integer.powerpc_regs.gpr[i] );
669 fprintf( stderr, ",cr=%08x,xer=%08x",
670 ctx.integer.powerpc_regs.cr, ctx.integer.powerpc_regs.xer );
672 if (ctx.flags & SERVER_CTX_DEBUG_REGISTERS)
673 for (i = 0; i < 8; i++) fprintf( stderr, ",dr%u=%08x", i, ctx.debug.powerpc_regs.dr[i] );
674 if (ctx.flags & SERVER_CTX_FLOATING_POINT)
676 for (i = 0; i < 32; i++) fprintf( stderr, ",fpr%u=%g", i, ctx.fp.powerpc_regs.fpr[i] );
677 fprintf( stderr, ",fpscr=%g", ctx.fp.powerpc_regs.fpscr );
679 break;
680 case CPU_ARM:
681 if (ctx.flags & SERVER_CTX_CONTROL)
682 fprintf( stderr, ",sp=%08x,lr=%08x,pc=%08x,cpsr=%08x",
683 ctx.ctl.arm_regs.sp, ctx.ctl.arm_regs.lr,
684 ctx.ctl.arm_regs.pc, ctx.ctl.arm_regs.cpsr );
685 if (ctx.flags & SERVER_CTX_INTEGER)
686 for (i = 0; i < 13; i++) fprintf( stderr, ",r%u=%08x", i, ctx.integer.arm_regs.r[i] );
687 if (ctx.flags & SERVER_CTX_DEBUG_REGISTERS)
689 for (i = 0; i < 8; i++)
690 fprintf( stderr, ",bcr%u=%08x,bvr%u=%08x",
691 i, ctx.debug.arm_regs.bcr[i], i, ctx.debug.arm_regs.bvr[i] );
692 fprintf( stderr, ",wcr0=%08x,wvr0=%08x",
693 ctx.debug.arm_regs.wcr[0], ctx.debug.arm_regs.wvr[0] );
695 if (ctx.flags & SERVER_CTX_FLOATING_POINT)
697 for (i = 0; i < 32; i++)
699 fprintf( stderr, ",d%u=", i );
700 dump_uint64( "", &ctx.fp.arm_regs.d[i] );
702 fprintf( stderr, ",fpscr=%08x", ctx.fp.arm_regs.fpscr );
704 break;
705 case CPU_ARM64:
706 if (ctx.flags & SERVER_CTX_CONTROL)
708 dump_uint64( ",sp=", &ctx.ctl.arm64_regs.sp );
709 dump_uint64( ",pc=", &ctx.ctl.arm64_regs.pc );
710 dump_uint64( ",pstate=", &ctx.ctl.arm64_regs.pstate );
712 if (ctx.flags & SERVER_CTX_INTEGER)
714 for (i = 0; i < 31; i++)
716 fprintf( stderr, ",x%u=", i );
717 dump_uint64( "", &ctx.integer.arm64_regs.x[i] );
720 if (ctx.flags & SERVER_CTX_DEBUG_REGISTERS)
722 for (i = 0; i < 8; i++)
724 fprintf( stderr, ",bcr%u=%08x,bvr%u=", i, ctx.debug.arm64_regs.bcr[i], i );
725 dump_uint64( "", &ctx.debug.arm64_regs.bvr[i] );
727 for (i = 0; i < 2; i++)
729 fprintf( stderr, ",wcr%u=%08x,wvr%u=", i, ctx.debug.arm64_regs.wcr[i], i );
730 dump_uint64( "", &ctx.debug.arm64_regs.wvr[i] );
733 if (ctx.flags & SERVER_CTX_FLOATING_POINT)
735 for (i = 0; i < 32; i++)
737 fprintf( stderr, ",q%u=", i );
738 dump_uint64( "", &ctx.fp.arm64_regs.q[i].high );
739 dump_uint64( "", &ctx.fp.arm64_regs.q[i].low );
741 fprintf( stderr, ",fpcr=%08x,fpsr=%08x", ctx.fp.arm64_regs.fpcr, ctx.fp.arm64_regs.fpsr );
743 break;
745 fputc( '}', stderr );
746 remove_data( size );
749 static void dump_varargs_debug_event( const char *prefix, data_size_t size )
751 debug_event_t event;
752 unsigned int i;
754 if (!size)
756 fprintf( stderr, "%s{}", prefix );
757 return;
759 size = min( size, sizeof(event) );
760 memset( &event, 0, sizeof(event) );
761 memcpy( &event, cur_data, size );
763 switch(event.code)
765 case EXCEPTION_DEBUG_EVENT:
766 fprintf( stderr, "%s{exception,first=%d,exc_code=%08x,flags=%08x", prefix,
767 event.exception.first, event.exception.exc_code, event.exception.flags );
768 dump_uint64( ",record=", &event.exception.record );
769 dump_uint64( ",address=", &event.exception.address );
770 fprintf( stderr, ",params={" );
771 event.exception.nb_params = min( event.exception.nb_params, EXCEPTION_MAXIMUM_PARAMETERS );
772 for (i = 0; i < event.exception.nb_params; i++)
774 dump_uint64( "", &event.exception.params[i] );
775 if (i < event.exception.nb_params) fputc( ',', stderr );
777 fprintf( stderr, "}}" );
778 break;
779 case CREATE_THREAD_DEBUG_EVENT:
780 fprintf( stderr, "%s{create_thread,thread=%04x", prefix, event.create_thread.handle );
781 dump_uint64( ",teb=", &event.create_thread.teb );
782 dump_uint64( ",start=", &event.create_thread.start );
783 fputc( '}', stderr );
784 break;
785 case CREATE_PROCESS_DEBUG_EVENT:
786 fprintf( stderr, "%s{create_process,file=%04x,process=%04x,thread=%04x", prefix,
787 event.create_process.file, event.create_process.process,
788 event.create_process.thread );
789 dump_uint64( ",base=", &event.create_process.base );
790 fprintf( stderr, ",offset=%d,size=%d",
791 event.create_process.dbg_offset, event.create_process.dbg_size );
792 dump_uint64( ",teb=", &event.create_process.teb );
793 dump_uint64( ",start=", &event.create_process.start );
794 dump_uint64( ",name=", &event.create_process.name );
795 fprintf( stderr, ",unicode=%d}", event.create_process.unicode );
796 break;
797 case EXIT_THREAD_DEBUG_EVENT:
798 fprintf( stderr, "%s{exit_thread,code=%d}", prefix, event.exit.exit_code );
799 break;
800 case EXIT_PROCESS_DEBUG_EVENT:
801 fprintf( stderr, "%s{exit_process,code=%d}", prefix, event.exit.exit_code );
802 break;
803 case LOAD_DLL_DEBUG_EVENT:
804 fprintf( stderr, "%s{load_dll,file=%04x", prefix, event.load_dll.handle );
805 dump_uint64( ",base=", &event.load_dll.base );
806 fprintf( stderr, ",offset=%d,size=%d",
807 event.load_dll.dbg_offset, event.load_dll.dbg_size );
808 dump_uint64( ",name=", &event.load_dll.name );
809 fprintf( stderr, ",unicode=%d}", event.load_dll.unicode );
810 break;
811 case UNLOAD_DLL_DEBUG_EVENT:
812 fprintf( stderr, "%s{unload_dll", prefix );
813 dump_uint64( ",base=", &event.unload_dll.base );
814 fputc( '}', stderr );
815 break;
816 case 0: /* zero is the code returned on timeouts */
817 fprintf( stderr, "%s{}", prefix );
818 break;
819 default:
820 fprintf( stderr, "%s{code=??? (%d)}", prefix, event.code );
821 break;
823 remove_data( size );
826 /* dump a unicode string contained in a buffer; helper for dump_varargs_startup_info */
827 static data_size_t dump_inline_unicode_string( const char *prefix, data_size_t pos, data_size_t len, data_size_t total_size )
829 fputs( prefix, stderr );
830 if (pos >= total_size) return pos;
831 if (len > total_size - pos) len = total_size - pos;
832 dump_strW( (const WCHAR *)cur_data + pos/sizeof(WCHAR), len, stderr, "\"\"" );
833 return pos + (len / sizeof(WCHAR)) * sizeof(WCHAR);
836 static void dump_varargs_startup_info( const char *prefix, data_size_t size )
838 startup_info_t info;
839 data_size_t pos = sizeof(info);
841 memset( &info, 0, sizeof(info) );
842 memcpy( &info, cur_data, min( size, sizeof(info) ));
844 fprintf( stderr,
845 "%s{debug_flags=%x,console_flags=%x,console=%04x,hstdin=%04x,hstdout=%04x,hstderr=%04x,"
846 "x=%u,y=%u,xsize=%u,ysize=%u,xchars=%u,ychars=%u,attribute=%02x,flags=%x,show=%u",
847 prefix, info.debug_flags, info.console_flags, info.console,
848 info.hstdin, info.hstdout, info.hstderr, info.x, info.y, info.xsize, info.ysize,
849 info.xchars, info.ychars, info.attribute, info.flags, info.show );
850 pos = dump_inline_unicode_string( ",curdir=L\"", pos, info.curdir_len, size );
851 pos = dump_inline_unicode_string( "\",dllpath=L\"", pos, info.dllpath_len, size );
852 pos = dump_inline_unicode_string( "\",imagepath=L\"", pos, info.imagepath_len, size );
853 pos = dump_inline_unicode_string( "\",cmdline=L\"", pos, info.cmdline_len, size );
854 pos = dump_inline_unicode_string( "\",title=L\"", pos, info.title_len, size );
855 pos = dump_inline_unicode_string( "\",desktop=L\"", pos, info.desktop_len, size );
856 pos = dump_inline_unicode_string( "\",shellinfo=L\"", pos, info.shellinfo_len, size );
857 pos = dump_inline_unicode_string( "\",runtime=L\"", pos, info.runtime_len, size );
858 fprintf( stderr, "\"}" );
859 remove_data( size );
862 static void dump_varargs_input_records( const char *prefix, data_size_t size )
864 const INPUT_RECORD *rec = cur_data;
865 data_size_t len = size / sizeof(*rec);
867 fprintf( stderr,"%s{", prefix );
868 while (len > 0)
870 fprintf( stderr, "{%04x,...}", rec->EventType );
871 rec++;
872 if (--len) fputc( ',', stderr );
874 fputc( '}', stderr );
875 remove_data( size );
878 static void dump_varargs_rectangles( const char *prefix, data_size_t size )
880 const rectangle_t *rect = cur_data;
881 data_size_t len = size / sizeof(*rect);
883 fprintf( stderr,"%s{", prefix );
884 while (len > 0)
886 dump_rectangle( "", rect++ );
887 if (--len) fputc( ',', stderr );
889 fputc( '}', stderr );
890 remove_data( size );
893 static void dump_varargs_message_data( const char *prefix, data_size_t size )
895 /* FIXME: dump the structured data */
896 dump_varargs_bytes( prefix, size );
899 static void dump_varargs_properties( const char *prefix, data_size_t size )
901 const property_data_t *prop = cur_data;
902 data_size_t len = size / sizeof(*prop);
904 fprintf( stderr,"%s{", prefix );
905 while (len > 0)
907 fprintf( stderr, "{atom=%04x,str=%d", prop->atom, prop->string );
908 dump_uint64( ",data=", &prop->data );
909 fputc( '}', stderr );
910 prop++;
911 if (--len) fputc( ',', stderr );
913 fputc( '}', stderr );
914 remove_data( size );
917 static void dump_varargs_LUID_AND_ATTRIBUTES( const char *prefix, data_size_t size )
919 const LUID_AND_ATTRIBUTES *lat = cur_data;
920 data_size_t len = size / sizeof(*lat);
922 fprintf( stderr,"%s{", prefix );
923 while (len > 0)
925 fprintf( stderr, "{luid=%08x%08x,attr=%x}",
926 lat->Luid.HighPart, lat->Luid.LowPart, lat->Attributes );
927 lat++;
928 if (--len) fputc( ',', stderr );
930 fputc( '}', stderr );
931 remove_data( size );
934 static void dump_inline_sid( const char *prefix, const SID *sid, data_size_t size )
936 DWORD i;
938 /* security check */
939 if ((FIELD_OFFSET(SID, SubAuthority[0]) > size) ||
940 (FIELD_OFFSET(SID, SubAuthority[sid->SubAuthorityCount]) > size))
942 fprintf( stderr, "<invalid sid>" );
943 return;
946 fprintf( stderr,"%s{", prefix );
947 fprintf( stderr, "S-%u-%u", sid->Revision, MAKELONG(
948 MAKEWORD( sid->IdentifierAuthority.Value[5],
949 sid->IdentifierAuthority.Value[4] ),
950 MAKEWORD( sid->IdentifierAuthority.Value[3],
951 sid->IdentifierAuthority.Value[2] ) ) );
952 for (i = 0; i < sid->SubAuthorityCount; i++)
953 fprintf( stderr, "-%u", sid->SubAuthority[i] );
954 fputc( '}', stderr );
957 static void dump_varargs_SID( const char *prefix, data_size_t size )
959 const SID *sid = cur_data;
960 dump_inline_sid( prefix, sid, size );
961 remove_data( size );
964 static void dump_inline_acl( const char *prefix, const ACL *acl, data_size_t size )
966 const ACE_HEADER *ace;
967 ULONG i;
969 fprintf( stderr,"%s{", prefix );
970 if (size)
972 if (size < sizeof(ACL))
974 fprintf( stderr, "<invalid acl>}" );
975 return;
977 size -= sizeof(ACL);
978 ace = (const ACE_HEADER *)(acl + 1);
979 for (i = 0; i < acl->AceCount; i++)
981 const SID *sid = NULL;
982 data_size_t sid_size = 0;
984 if (size < sizeof(ACE_HEADER) || size < ace->AceSize) break;
985 size -= ace->AceSize;
986 if (i != 0) fputc( ',', stderr );
987 fprintf( stderr, "{AceType=" );
988 switch (ace->AceType)
990 case ACCESS_DENIED_ACE_TYPE:
991 sid = (const SID *)&((const ACCESS_DENIED_ACE *)ace)->SidStart;
992 sid_size = ace->AceSize - FIELD_OFFSET(ACCESS_DENIED_ACE, SidStart);
993 fprintf( stderr, "ACCESS_DENIED_ACE_TYPE,Mask=%x",
994 ((const ACCESS_DENIED_ACE *)ace)->Mask );
995 break;
996 case ACCESS_ALLOWED_ACE_TYPE:
997 sid = (const SID *)&((const ACCESS_ALLOWED_ACE *)ace)->SidStart;
998 sid_size = ace->AceSize - FIELD_OFFSET(ACCESS_ALLOWED_ACE, SidStart);
999 fprintf( stderr, "ACCESS_ALLOWED_ACE_TYPE,Mask=%x",
1000 ((const ACCESS_ALLOWED_ACE *)ace)->Mask );
1001 break;
1002 case SYSTEM_AUDIT_ACE_TYPE:
1003 sid = (const SID *)&((const SYSTEM_AUDIT_ACE *)ace)->SidStart;
1004 sid_size = ace->AceSize - FIELD_OFFSET(SYSTEM_AUDIT_ACE, SidStart);
1005 fprintf( stderr, "SYSTEM_AUDIT_ACE_TYPE,Mask=%x",
1006 ((const SYSTEM_AUDIT_ACE *)ace)->Mask );
1007 break;
1008 case SYSTEM_ALARM_ACE_TYPE:
1009 sid = (const SID *)&((const SYSTEM_ALARM_ACE *)ace)->SidStart;
1010 sid_size = ace->AceSize - FIELD_OFFSET(SYSTEM_ALARM_ACE, SidStart);
1011 fprintf( stderr, "SYSTEM_ALARM_ACE_TYPE,Mask=%x",
1012 ((const SYSTEM_ALARM_ACE *)ace)->Mask );
1013 break;
1014 case SYSTEM_MANDATORY_LABEL_ACE_TYPE:
1015 sid = (const SID *)&((const SYSTEM_MANDATORY_LABEL_ACE *)ace)->SidStart;
1016 sid_size = ace->AceSize - FIELD_OFFSET(SYSTEM_MANDATORY_LABEL_ACE, SidStart);
1017 fprintf( stderr, "SYSTEM_MANDATORY_LABEL_ACE_TYPE,Mask=%x",
1018 ((const SYSTEM_MANDATORY_LABEL_ACE *)ace)->Mask );
1019 break;
1020 default:
1021 fprintf( stderr, "unknown<%d>", ace->AceType );
1022 break;
1024 fprintf( stderr, ",AceFlags=%x", ace->AceFlags );
1025 if (sid)
1026 dump_inline_sid( ",Sid=", sid, sid_size );
1027 ace = (const ACE_HEADER *)((const char *)ace + ace->AceSize);
1028 fputc( '}', stderr );
1031 fputc( '}', stderr );
1034 static void dump_varargs_ACL( const char *prefix, data_size_t size )
1036 const ACL *acl = cur_data;
1037 dump_inline_acl( prefix, acl, size );
1038 remove_data( size );
1041 static void dump_inline_security_descriptor( const char *prefix, const struct security_descriptor *sd, data_size_t size )
1043 fprintf( stderr,"%s{", prefix );
1044 if (size >= sizeof(struct security_descriptor))
1046 size_t offset = sizeof(struct security_descriptor);
1047 fprintf( stderr, "control=%08x", sd->control );
1048 if ((sd->owner_len > FIELD_OFFSET(SID, SubAuthority[255])) || (offset + sd->owner_len > size))
1049 return;
1050 if (sd->owner_len)
1051 dump_inline_sid( ",owner=", (const SID *)((const char *)sd + offset), sd->owner_len );
1052 else
1053 fprintf( stderr, ",owner=<not present>" );
1054 offset += sd->owner_len;
1055 if ((sd->group_len > FIELD_OFFSET(SID, SubAuthority[255])) || (offset + sd->group_len > size))
1056 return;
1057 if (sd->group_len)
1058 dump_inline_sid( ",group=", (const SID *)((const char *)sd + offset), sd->group_len );
1059 else
1060 fprintf( stderr, ",group=<not present>" );
1061 offset += sd->group_len;
1062 if ((sd->sacl_len >= MAX_ACL_LEN) || (offset + sd->sacl_len > size))
1063 return;
1064 dump_inline_acl( ",sacl=", (const ACL *)((const char *)sd + offset), sd->sacl_len );
1065 offset += sd->sacl_len;
1066 if ((sd->dacl_len >= MAX_ACL_LEN) || (offset + sd->dacl_len > size))
1067 return;
1068 dump_inline_acl( ",dacl=", (const ACL *)((const char *)sd + offset), sd->dacl_len );
1069 offset += sd->dacl_len;
1071 fputc( '}', stderr );
1074 static void dump_varargs_security_descriptor( const char *prefix, data_size_t size )
1076 const struct security_descriptor *sd = cur_data;
1077 dump_inline_security_descriptor( prefix, sd, size );
1078 remove_data( size );
1081 static void dump_varargs_token_groups( const char *prefix, data_size_t size )
1083 const struct token_groups *tg = cur_data;
1085 fprintf( stderr,"%s{", prefix );
1086 if (size >= sizeof(struct token_groups))
1088 size_t offset = sizeof(*tg);
1089 fprintf( stderr, "count=%08x,", tg->count );
1090 if (tg->count * sizeof(unsigned int) <= size)
1092 unsigned int i;
1093 const unsigned int *attr = (const unsigned int *)(tg + 1);
1095 offset += tg->count * sizeof(unsigned int);
1097 fputc( '[', stderr );
1098 for (i = 0; i < tg->count; i++)
1100 const SID *sid = (const SID *)((const char *)cur_data + offset);
1101 if (i != 0)
1102 fputc( ',', stderr );
1103 fputc( '{', stderr );
1104 fprintf( stderr, "attributes=%08x", attr[i] );
1105 dump_inline_sid( ",sid=", sid, size - offset );
1106 if ((offset + FIELD_OFFSET(SID, SubAuthority[0]) > size) ||
1107 (offset + FIELD_OFFSET(SID, SubAuthority[sid->SubAuthorityCount]) > size))
1108 break;
1109 offset += FIELD_OFFSET(SID, SubAuthority[sid->SubAuthorityCount]);
1110 fputc( '}', stderr );
1112 fputc( ']', stderr );
1115 fputc( '}', stderr );
1118 static void dump_varargs_object_attributes( const char *prefix, data_size_t size )
1120 const struct object_attributes *objattr = cur_data;
1122 fprintf( stderr,"%s{", prefix );
1123 if (size)
1125 const WCHAR *str;
1127 if (size < sizeof(*objattr) ||
1128 (size - sizeof(*objattr) < objattr->sd_len) ||
1129 (size - sizeof(*objattr) - objattr->sd_len < objattr->name_len))
1131 fprintf( stderr, "***invalid***}" );
1132 remove_data( size );
1133 return;
1136 fprintf( stderr, "rootdir=%04x,attributes=%08x", objattr->rootdir, objattr->attributes );
1137 dump_inline_security_descriptor( ",sd=", (const struct security_descriptor *)(objattr + 1), objattr->sd_len );
1138 str = (const WCHAR *)objattr + (sizeof(*objattr) + objattr->sd_len) / sizeof(WCHAR);
1139 fprintf( stderr, ",name=L\"" );
1140 dump_strW( str, objattr->name_len, stderr, "\"\"" );
1141 fputc( '\"', stderr );
1142 remove_data( (sizeof(*objattr) + (objattr->sd_len & ~1) + (objattr->name_len & ~1) + 3) & ~3 );
1144 fputc( '}', stderr );
1147 static void dump_varargs_filesystem_event( const char *prefix, data_size_t size )
1149 static const char * const actions[] = {
1150 NULL,
1151 "ADDED",
1152 "REMOVED",
1153 "MODIFIED",
1154 "RENAMED_OLD_NAME",
1155 "RENAMED_NEW_NAME",
1156 "ADDED_STREAM",
1157 "REMOVED_STREAM",
1158 "MODIFIED_STREAM"
1161 fprintf( stderr,"%s{", prefix );
1162 while (size)
1164 const struct filesystem_event *event = cur_data;
1165 data_size_t len = (offsetof( struct filesystem_event, name[event->len] ) + sizeof(int)-1)
1166 / sizeof(int) * sizeof(int);
1167 if (size < len) break;
1168 if (event->action < ARRAY_SIZE( actions ) && actions[event->action])
1169 fprintf( stderr, "{action=%s", actions[event->action] );
1170 else
1171 fprintf( stderr, "{action=%u", event->action );
1172 fprintf( stderr, ",name=\"%.*s\"}", event->len, event->name );
1173 size -= len;
1174 remove_data( len );
1175 if (size)fputc( ',', stderr );
1177 fputc( '}', stderr );
1180 static void dump_varargs_pe_image_info( const char *prefix, data_size_t size )
1182 pe_image_info_t info;
1184 if (!size)
1186 fprintf( stderr, "%s{}", prefix );
1187 return;
1189 memset( &info, 0, sizeof(info) );
1190 memcpy( &info, cur_data, min( size, sizeof(info) ));
1192 fprintf( stderr, "%s{", prefix );
1193 dump_uint64( "base=", &info.base );
1194 dump_uint64( ",entry_point=", &info.entry_point );
1195 dump_uint64( ",map_size=", &info.map_size );
1196 dump_uint64( ",stack_size=", &info.stack_size );
1197 dump_uint64( ",stack_commit=", &info.stack_commit );
1198 fprintf( stderr, ",zerobits=%08x,subsystem=%08x,subsystem_low=%04x,subsystem_high=%04x,gp=%08x"
1199 ",image_charact=%04x,dll_charact=%04x,machine=%04x,contains_code=%u,image_flags=%02x"
1200 ",loader_flags=%08x,header_size=%08x,file_size=%08x,checksum=%08x",
1201 info.zerobits, info.subsystem, info.subsystem_low, info.subsystem_high, info.gp,
1202 info.image_charact, info.dll_charact, info.machine, info.contains_code, info.image_flags,
1203 info.loader_flags, info.header_size, info.file_size, info.checksum );
1204 dump_client_cpu( ",cpu=", &info.cpu );
1205 fputc( '}', stderr );
1206 remove_data( size );
1209 static void dump_varargs_rawinput_devices(const char *prefix, data_size_t size )
1211 const struct rawinput_device *device;
1213 fprintf( stderr, "%s{", prefix );
1214 while (size >= sizeof(*device))
1216 device = cur_data;
1217 fprintf( stderr, "{usage_page=%04x,usage=%04x,flags=%08x,target=%08x}",
1218 device->usage_page, device->usage, device->flags, device->target );
1219 size -= sizeof(*device);
1220 remove_data( sizeof(*device) );
1221 if (size) fputc( ',', stderr );
1223 fputc( '}', stderr );
1226 static void dump_varargs_handle_infos( const char *prefix, data_size_t size )
1228 const struct handle_info *handle;
1230 fprintf( stderr, "%s{", prefix );
1231 while (size >= sizeof(*handle))
1233 handle = cur_data;
1234 fprintf( stderr, "{owner=%04x,handle=%04x,access=%08x}",
1235 handle->owner, handle->handle, handle->access );
1236 size -= sizeof(*handle);
1237 remove_data( sizeof(*handle) );
1238 if (size) fputc( ',', stderr );
1240 fputc( '}', stderr );
1243 typedef void (*dump_func)( const void *req );
1245 /* Everything below this line is generated automatically by tools/make_requests */
1246 /* ### make_requests begin ### */
1248 static void dump_new_process_request( const struct new_process_request *req )
1250 fprintf( stderr, " parent_process=%04x", req->parent_process );
1251 fprintf( stderr, ", inherit_all=%d", req->inherit_all );
1252 fprintf( stderr, ", create_flags=%08x", req->create_flags );
1253 fprintf( stderr, ", socket_fd=%d", req->socket_fd );
1254 fprintf( stderr, ", exe_file=%04x", req->exe_file );
1255 fprintf( stderr, ", access=%08x", req->access );
1256 dump_client_cpu( ", cpu=", &req->cpu );
1257 fprintf( stderr, ", info_size=%u", req->info_size );
1258 dump_varargs_object_attributes( ", objattr=", cur_size );
1259 dump_varargs_startup_info( ", info=", min(cur_size,req->info_size) );
1260 dump_varargs_unicode_str( ", env=", cur_size );
1263 static void dump_new_process_reply( const struct new_process_reply *req )
1265 fprintf( stderr, " info=%04x", req->info );
1266 fprintf( stderr, ", pid=%04x", req->pid );
1267 fprintf( stderr, ", handle=%04x", req->handle );
1270 static void dump_exec_process_request( const struct exec_process_request *req )
1272 fprintf( stderr, " socket_fd=%d", req->socket_fd );
1273 dump_client_cpu( ", cpu=", &req->cpu );
1276 static void dump_get_new_process_info_request( const struct get_new_process_info_request *req )
1278 fprintf( stderr, " info=%04x", req->info );
1281 static void dump_get_new_process_info_reply( const struct get_new_process_info_reply *req )
1283 fprintf( stderr, " success=%d", req->success );
1284 fprintf( stderr, ", exit_code=%d", req->exit_code );
1287 static void dump_new_thread_request( const struct new_thread_request *req )
1289 fprintf( stderr, " process=%04x", req->process );
1290 fprintf( stderr, ", access=%08x", req->access );
1291 fprintf( stderr, ", suspend=%d", req->suspend );
1292 fprintf( stderr, ", request_fd=%d", req->request_fd );
1293 dump_varargs_object_attributes( ", objattr=", cur_size );
1296 static void dump_new_thread_reply( const struct new_thread_reply *req )
1298 fprintf( stderr, " tid=%04x", req->tid );
1299 fprintf( stderr, ", handle=%04x", req->handle );
1302 static void dump_get_startup_info_request( const struct get_startup_info_request *req )
1306 static void dump_get_startup_info_reply( const struct get_startup_info_reply *req )
1308 fprintf( stderr, " info_size=%u", req->info_size );
1309 dump_varargs_startup_info( ", info=", min(cur_size,req->info_size) );
1310 dump_varargs_unicode_str( ", env=", cur_size );
1313 static void dump_init_process_done_request( const struct init_process_done_request *req )
1315 fprintf( stderr, " gui=%d", req->gui );
1316 dump_uint64( ", module=", &req->module );
1317 dump_uint64( ", ldt_copy=", &req->ldt_copy );
1318 dump_uint64( ", entry=", &req->entry );
1321 static void dump_init_process_done_reply( const struct init_process_done_reply *req )
1323 fprintf( stderr, " suspend=%d", req->suspend );
1326 static void dump_init_thread_request( const struct init_thread_request *req )
1328 fprintf( stderr, " unix_pid=%d", req->unix_pid );
1329 fprintf( stderr, ", unix_tid=%d", req->unix_tid );
1330 fprintf( stderr, ", debug_level=%d", req->debug_level );
1331 dump_uint64( ", teb=", &req->teb );
1332 dump_uint64( ", entry=", &req->entry );
1333 fprintf( stderr, ", reply_fd=%d", req->reply_fd );
1334 fprintf( stderr, ", wait_fd=%d", req->wait_fd );
1335 dump_client_cpu( ", cpu=", &req->cpu );
1338 static void dump_init_thread_reply( const struct init_thread_reply *req )
1340 fprintf( stderr, " pid=%04x", req->pid );
1341 fprintf( stderr, ", tid=%04x", req->tid );
1342 dump_timeout( ", server_start=", &req->server_start );
1343 fprintf( stderr, ", info_size=%u", req->info_size );
1344 fprintf( stderr, ", version=%d", req->version );
1345 fprintf( stderr, ", all_cpus=%08x", req->all_cpus );
1346 fprintf( stderr, ", suspend=%d", req->suspend );
1349 static void dump_terminate_process_request( const struct terminate_process_request *req )
1351 fprintf( stderr, " handle=%04x", req->handle );
1352 fprintf( stderr, ", exit_code=%d", req->exit_code );
1355 static void dump_terminate_process_reply( const struct terminate_process_reply *req )
1357 fprintf( stderr, " self=%d", req->self );
1360 static void dump_terminate_thread_request( const struct terminate_thread_request *req )
1362 fprintf( stderr, " handle=%04x", req->handle );
1363 fprintf( stderr, ", exit_code=%d", req->exit_code );
1366 static void dump_terminate_thread_reply( const struct terminate_thread_reply *req )
1368 fprintf( stderr, " self=%d", req->self );
1371 static void dump_get_process_info_request( const struct get_process_info_request *req )
1373 fprintf( stderr, " handle=%04x", req->handle );
1376 static void dump_get_process_info_reply( const struct get_process_info_reply *req )
1378 fprintf( stderr, " pid=%04x", req->pid );
1379 fprintf( stderr, ", ppid=%04x", req->ppid );
1380 dump_uint64( ", affinity=", &req->affinity );
1381 dump_uint64( ", peb=", &req->peb );
1382 dump_timeout( ", start_time=", &req->start_time );
1383 dump_timeout( ", end_time=", &req->end_time );
1384 fprintf( stderr, ", exit_code=%d", req->exit_code );
1385 fprintf( stderr, ", priority=%d", req->priority );
1386 dump_client_cpu( ", cpu=", &req->cpu );
1387 fprintf( stderr, ", debugger_present=%d", req->debugger_present );
1388 fprintf( stderr, ", debug_children=%d", req->debug_children );
1389 dump_varargs_pe_image_info( ", image=", cur_size );
1392 static void dump_get_process_vm_counters_request( const struct get_process_vm_counters_request *req )
1394 fprintf( stderr, " handle=%04x", req->handle );
1397 static void dump_get_process_vm_counters_reply( const struct get_process_vm_counters_reply *req )
1399 dump_uint64( " peak_virtual_size=", &req->peak_virtual_size );
1400 dump_uint64( ", virtual_size=", &req->virtual_size );
1401 dump_uint64( ", peak_working_set_size=", &req->peak_working_set_size );
1402 dump_uint64( ", working_set_size=", &req->working_set_size );
1403 dump_uint64( ", pagefile_usage=", &req->pagefile_usage );
1404 dump_uint64( ", peak_pagefile_usage=", &req->peak_pagefile_usage );
1407 static void dump_set_process_info_request( const struct set_process_info_request *req )
1409 fprintf( stderr, " handle=%04x", req->handle );
1410 fprintf( stderr, ", mask=%d", req->mask );
1411 fprintf( stderr, ", priority=%d", req->priority );
1412 dump_uint64( ", affinity=", &req->affinity );
1415 static void dump_get_thread_info_request( const struct get_thread_info_request *req )
1417 fprintf( stderr, " handle=%04x", req->handle );
1418 fprintf( stderr, ", tid_in=%04x", req->tid_in );
1421 static void dump_get_thread_info_reply( const struct get_thread_info_reply *req )
1423 fprintf( stderr, " pid=%04x", req->pid );
1424 fprintf( stderr, ", tid=%04x", req->tid );
1425 dump_uint64( ", teb=", &req->teb );
1426 dump_uint64( ", entry_point=", &req->entry_point );
1427 dump_uint64( ", affinity=", &req->affinity );
1428 fprintf( stderr, ", exit_code=%d", req->exit_code );
1429 fprintf( stderr, ", priority=%d", req->priority );
1430 fprintf( stderr, ", last=%d", req->last );
1431 fprintf( stderr, ", suspend_count=%d", req->suspend_count );
1432 fprintf( stderr, ", desc_len=%u", req->desc_len );
1433 dump_varargs_unicode_str( ", desc=", cur_size );
1436 static void dump_get_thread_times_request( const struct get_thread_times_request *req )
1438 fprintf( stderr, " handle=%04x", req->handle );
1441 static void dump_get_thread_times_reply( const struct get_thread_times_reply *req )
1443 dump_timeout( " creation_time=", &req->creation_time );
1444 dump_timeout( ", exit_time=", &req->exit_time );
1447 static void dump_set_thread_info_request( const struct set_thread_info_request *req )
1449 fprintf( stderr, " handle=%04x", req->handle );
1450 fprintf( stderr, ", mask=%d", req->mask );
1451 fprintf( stderr, ", priority=%d", req->priority );
1452 dump_uint64( ", affinity=", &req->affinity );
1453 dump_uint64( ", entry_point=", &req->entry_point );
1454 fprintf( stderr, ", token=%04x", req->token );
1455 dump_varargs_unicode_str( ", desc=", cur_size );
1458 static void dump_get_dll_info_request( const struct get_dll_info_request *req )
1460 fprintf( stderr, " handle=%04x", req->handle );
1461 dump_uint64( ", base_address=", &req->base_address );
1464 static void dump_get_dll_info_reply( const struct get_dll_info_reply *req )
1466 dump_uint64( " entry_point=", &req->entry_point );
1467 fprintf( stderr, ", filename_len=%u", req->filename_len );
1468 dump_varargs_unicode_str( ", filename=", cur_size );
1471 static void dump_suspend_thread_request( const struct suspend_thread_request *req )
1473 fprintf( stderr, " handle=%04x", req->handle );
1476 static void dump_suspend_thread_reply( const struct suspend_thread_reply *req )
1478 fprintf( stderr, " count=%d", req->count );
1481 static void dump_resume_thread_request( const struct resume_thread_request *req )
1483 fprintf( stderr, " handle=%04x", req->handle );
1486 static void dump_resume_thread_reply( const struct resume_thread_reply *req )
1488 fprintf( stderr, " count=%d", req->count );
1491 static void dump_load_dll_request( const struct load_dll_request *req )
1493 fprintf( stderr, " dbg_offset=%u", req->dbg_offset );
1494 dump_uint64( ", base=", &req->base );
1495 dump_uint64( ", name=", &req->name );
1496 fprintf( stderr, ", dbg_size=%u", req->dbg_size );
1497 dump_varargs_unicode_str( ", filename=", cur_size );
1500 static void dump_unload_dll_request( const struct unload_dll_request *req )
1502 dump_uint64( " base=", &req->base );
1505 static void dump_queue_apc_request( const struct queue_apc_request *req )
1507 fprintf( stderr, " handle=%04x", req->handle );
1508 dump_apc_call( ", call=", &req->call );
1511 static void dump_queue_apc_reply( const struct queue_apc_reply *req )
1513 fprintf( stderr, " handle=%04x", req->handle );
1514 fprintf( stderr, ", self=%d", req->self );
1517 static void dump_get_apc_result_request( const struct get_apc_result_request *req )
1519 fprintf( stderr, " handle=%04x", req->handle );
1522 static void dump_get_apc_result_reply( const struct get_apc_result_reply *req )
1524 dump_apc_result( " result=", &req->result );
1527 static void dump_close_handle_request( const struct close_handle_request *req )
1529 fprintf( stderr, " handle=%04x", req->handle );
1532 static void dump_set_handle_info_request( const struct set_handle_info_request *req )
1534 fprintf( stderr, " handle=%04x", req->handle );
1535 fprintf( stderr, ", flags=%d", req->flags );
1536 fprintf( stderr, ", mask=%d", req->mask );
1539 static void dump_set_handle_info_reply( const struct set_handle_info_reply *req )
1541 fprintf( stderr, " old_flags=%d", req->old_flags );
1544 static void dump_dup_handle_request( const struct dup_handle_request *req )
1546 fprintf( stderr, " src_process=%04x", req->src_process );
1547 fprintf( stderr, ", src_handle=%04x", req->src_handle );
1548 fprintf( stderr, ", dst_process=%04x", req->dst_process );
1549 fprintf( stderr, ", access=%08x", req->access );
1550 fprintf( stderr, ", attributes=%08x", req->attributes );
1551 fprintf( stderr, ", options=%08x", req->options );
1554 static void dump_dup_handle_reply( const struct dup_handle_reply *req )
1556 fprintf( stderr, " handle=%04x", req->handle );
1557 fprintf( stderr, ", self=%d", req->self );
1558 fprintf( stderr, ", closed=%d", req->closed );
1561 static void dump_open_process_request( const struct open_process_request *req )
1563 fprintf( stderr, " pid=%04x", req->pid );
1564 fprintf( stderr, ", access=%08x", req->access );
1565 fprintf( stderr, ", attributes=%08x", req->attributes );
1568 static void dump_open_process_reply( const struct open_process_reply *req )
1570 fprintf( stderr, " handle=%04x", req->handle );
1573 static void dump_open_thread_request( const struct open_thread_request *req )
1575 fprintf( stderr, " tid=%04x", req->tid );
1576 fprintf( stderr, ", access=%08x", req->access );
1577 fprintf( stderr, ", attributes=%08x", req->attributes );
1580 static void dump_open_thread_reply( const struct open_thread_reply *req )
1582 fprintf( stderr, " handle=%04x", req->handle );
1585 static void dump_select_request( const struct select_request *req )
1587 fprintf( stderr, " flags=%d", req->flags );
1588 dump_uint64( ", cookie=", &req->cookie );
1589 dump_abstime( ", timeout=", &req->timeout );
1590 fprintf( stderr, ", size=%u", req->size );
1591 fprintf( stderr, ", prev_apc=%04x", req->prev_apc );
1592 dump_varargs_apc_result( ", result=", cur_size );
1593 dump_varargs_select_op( ", data=", min(cur_size,req->size) );
1594 dump_varargs_context( ", context=", cur_size );
1597 static void dump_select_reply( const struct select_reply *req )
1599 dump_apc_call( " call=", &req->call );
1600 fprintf( stderr, ", apc_handle=%04x", req->apc_handle );
1601 dump_varargs_context( ", context=", cur_size );
1604 static void dump_create_event_request( const struct create_event_request *req )
1606 fprintf( stderr, " access=%08x", req->access );
1607 fprintf( stderr, ", manual_reset=%d", req->manual_reset );
1608 fprintf( stderr, ", initial_state=%d", req->initial_state );
1609 dump_varargs_object_attributes( ", objattr=", cur_size );
1612 static void dump_create_event_reply( const struct create_event_reply *req )
1614 fprintf( stderr, " handle=%04x", req->handle );
1617 static void dump_event_op_request( const struct event_op_request *req )
1619 fprintf( stderr, " handle=%04x", req->handle );
1620 fprintf( stderr, ", op=%d", req->op );
1623 static void dump_event_op_reply( const struct event_op_reply *req )
1625 fprintf( stderr, " state=%d", req->state );
1628 static void dump_query_event_request( const struct query_event_request *req )
1630 fprintf( stderr, " handle=%04x", req->handle );
1633 static void dump_query_event_reply( const struct query_event_reply *req )
1635 fprintf( stderr, " manual_reset=%d", req->manual_reset );
1636 fprintf( stderr, ", state=%d", req->state );
1639 static void dump_open_event_request( const struct open_event_request *req )
1641 fprintf( stderr, " access=%08x", req->access );
1642 fprintf( stderr, ", attributes=%08x", req->attributes );
1643 fprintf( stderr, ", rootdir=%04x", req->rootdir );
1644 dump_varargs_unicode_str( ", name=", cur_size );
1647 static void dump_open_event_reply( const struct open_event_reply *req )
1649 fprintf( stderr, " handle=%04x", req->handle );
1652 static void dump_create_keyed_event_request( const struct create_keyed_event_request *req )
1654 fprintf( stderr, " access=%08x", req->access );
1655 dump_varargs_object_attributes( ", objattr=", cur_size );
1658 static void dump_create_keyed_event_reply( const struct create_keyed_event_reply *req )
1660 fprintf( stderr, " handle=%04x", req->handle );
1663 static void dump_open_keyed_event_request( const struct open_keyed_event_request *req )
1665 fprintf( stderr, " access=%08x", req->access );
1666 fprintf( stderr, ", attributes=%08x", req->attributes );
1667 fprintf( stderr, ", rootdir=%04x", req->rootdir );
1668 dump_varargs_unicode_str( ", name=", cur_size );
1671 static void dump_open_keyed_event_reply( const struct open_keyed_event_reply *req )
1673 fprintf( stderr, " handle=%04x", req->handle );
1676 static void dump_create_mutex_request( const struct create_mutex_request *req )
1678 fprintf( stderr, " access=%08x", req->access );
1679 fprintf( stderr, ", owned=%d", req->owned );
1680 dump_varargs_object_attributes( ", objattr=", cur_size );
1683 static void dump_create_mutex_reply( const struct create_mutex_reply *req )
1685 fprintf( stderr, " handle=%04x", req->handle );
1688 static void dump_release_mutex_request( const struct release_mutex_request *req )
1690 fprintf( stderr, " handle=%04x", req->handle );
1693 static void dump_release_mutex_reply( const struct release_mutex_reply *req )
1695 fprintf( stderr, " prev_count=%08x", req->prev_count );
1698 static void dump_open_mutex_request( const struct open_mutex_request *req )
1700 fprintf( stderr, " access=%08x", req->access );
1701 fprintf( stderr, ", attributes=%08x", req->attributes );
1702 fprintf( stderr, ", rootdir=%04x", req->rootdir );
1703 dump_varargs_unicode_str( ", name=", cur_size );
1706 static void dump_open_mutex_reply( const struct open_mutex_reply *req )
1708 fprintf( stderr, " handle=%04x", req->handle );
1711 static void dump_query_mutex_request( const struct query_mutex_request *req )
1713 fprintf( stderr, " handle=%04x", req->handle );
1716 static void dump_query_mutex_reply( const struct query_mutex_reply *req )
1718 fprintf( stderr, " count=%08x", req->count );
1719 fprintf( stderr, ", owned=%d", req->owned );
1720 fprintf( stderr, ", abandoned=%d", req->abandoned );
1723 static void dump_create_semaphore_request( const struct create_semaphore_request *req )
1725 fprintf( stderr, " access=%08x", req->access );
1726 fprintf( stderr, ", initial=%08x", req->initial );
1727 fprintf( stderr, ", max=%08x", req->max );
1728 dump_varargs_object_attributes( ", objattr=", cur_size );
1731 static void dump_create_semaphore_reply( const struct create_semaphore_reply *req )
1733 fprintf( stderr, " handle=%04x", req->handle );
1736 static void dump_release_semaphore_request( const struct release_semaphore_request *req )
1738 fprintf( stderr, " handle=%04x", req->handle );
1739 fprintf( stderr, ", count=%08x", req->count );
1742 static void dump_release_semaphore_reply( const struct release_semaphore_reply *req )
1744 fprintf( stderr, " prev_count=%08x", req->prev_count );
1747 static void dump_query_semaphore_request( const struct query_semaphore_request *req )
1749 fprintf( stderr, " handle=%04x", req->handle );
1752 static void dump_query_semaphore_reply( const struct query_semaphore_reply *req )
1754 fprintf( stderr, " current=%08x", req->current );
1755 fprintf( stderr, ", max=%08x", req->max );
1758 static void dump_open_semaphore_request( const struct open_semaphore_request *req )
1760 fprintf( stderr, " access=%08x", req->access );
1761 fprintf( stderr, ", attributes=%08x", req->attributes );
1762 fprintf( stderr, ", rootdir=%04x", req->rootdir );
1763 dump_varargs_unicode_str( ", name=", cur_size );
1766 static void dump_open_semaphore_reply( const struct open_semaphore_reply *req )
1768 fprintf( stderr, " handle=%04x", req->handle );
1771 static void dump_create_file_request( const struct create_file_request *req )
1773 fprintf( stderr, " access=%08x", req->access );
1774 fprintf( stderr, ", sharing=%08x", req->sharing );
1775 fprintf( stderr, ", create=%d", req->create );
1776 fprintf( stderr, ", options=%08x", req->options );
1777 fprintf( stderr, ", attrs=%08x", req->attrs );
1778 dump_varargs_object_attributes( ", objattr=", cur_size );
1779 dump_varargs_string( ", filename=", cur_size );
1782 static void dump_create_file_reply( const struct create_file_reply *req )
1784 fprintf( stderr, " handle=%04x", req->handle );
1787 static void dump_open_file_object_request( const struct open_file_object_request *req )
1789 fprintf( stderr, " access=%08x", req->access );
1790 fprintf( stderr, ", attributes=%08x", req->attributes );
1791 fprintf( stderr, ", rootdir=%04x", req->rootdir );
1792 fprintf( stderr, ", sharing=%08x", req->sharing );
1793 fprintf( stderr, ", options=%08x", req->options );
1794 dump_varargs_unicode_str( ", filename=", cur_size );
1797 static void dump_open_file_object_reply( const struct open_file_object_reply *req )
1799 fprintf( stderr, " handle=%04x", req->handle );
1802 static void dump_alloc_file_handle_request( const struct alloc_file_handle_request *req )
1804 fprintf( stderr, " access=%08x", req->access );
1805 fprintf( stderr, ", attributes=%08x", req->attributes );
1806 fprintf( stderr, ", fd=%d", req->fd );
1809 static void dump_alloc_file_handle_reply( const struct alloc_file_handle_reply *req )
1811 fprintf( stderr, " handle=%04x", req->handle );
1814 static void dump_get_handle_unix_name_request( const struct get_handle_unix_name_request *req )
1816 fprintf( stderr, " handle=%04x", req->handle );
1819 static void dump_get_handle_unix_name_reply( const struct get_handle_unix_name_reply *req )
1821 fprintf( stderr, " name_len=%u", req->name_len );
1822 dump_varargs_string( ", name=", cur_size );
1825 static void dump_get_handle_fd_request( const struct get_handle_fd_request *req )
1827 fprintf( stderr, " handle=%04x", req->handle );
1830 static void dump_get_handle_fd_reply( const struct get_handle_fd_reply *req )
1832 fprintf( stderr, " type=%d", req->type );
1833 fprintf( stderr, ", cacheable=%d", req->cacheable );
1834 fprintf( stderr, ", access=%08x", req->access );
1835 fprintf( stderr, ", options=%08x", req->options );
1838 static void dump_get_directory_cache_entry_request( const struct get_directory_cache_entry_request *req )
1840 fprintf( stderr, " handle=%04x", req->handle );
1843 static void dump_get_directory_cache_entry_reply( const struct get_directory_cache_entry_reply *req )
1845 fprintf( stderr, " entry=%d", req->entry );
1846 dump_varargs_ints( ", free=", cur_size );
1849 static void dump_flush_request( const struct flush_request *req )
1851 dump_async_data( " async=", &req->async );
1854 static void dump_flush_reply( const struct flush_reply *req )
1856 fprintf( stderr, " event=%04x", req->event );
1859 static void dump_get_file_info_request( const struct get_file_info_request *req )
1861 fprintf( stderr, " handle=%04x", req->handle );
1862 fprintf( stderr, ", info_class=%08x", req->info_class );
1865 static void dump_get_file_info_reply( const struct get_file_info_reply *req )
1867 dump_varargs_bytes( " data=", cur_size );
1870 static void dump_get_volume_info_request( const struct get_volume_info_request *req )
1872 fprintf( stderr, " handle=%04x", req->handle );
1873 fprintf( stderr, ", info_class=%08x", req->info_class );
1876 static void dump_get_volume_info_reply( const struct get_volume_info_reply *req )
1878 dump_varargs_bytes( " data=", cur_size );
1881 static void dump_lock_file_request( const struct lock_file_request *req )
1883 fprintf( stderr, " handle=%04x", req->handle );
1884 dump_uint64( ", offset=", &req->offset );
1885 dump_uint64( ", count=", &req->count );
1886 fprintf( stderr, ", shared=%d", req->shared );
1887 fprintf( stderr, ", wait=%d", req->wait );
1890 static void dump_lock_file_reply( const struct lock_file_reply *req )
1892 fprintf( stderr, " handle=%04x", req->handle );
1893 fprintf( stderr, ", overlapped=%d", req->overlapped );
1896 static void dump_unlock_file_request( const struct unlock_file_request *req )
1898 fprintf( stderr, " handle=%04x", req->handle );
1899 dump_uint64( ", offset=", &req->offset );
1900 dump_uint64( ", count=", &req->count );
1903 static void dump_create_socket_request( const struct create_socket_request *req )
1905 fprintf( stderr, " access=%08x", req->access );
1906 fprintf( stderr, ", attributes=%08x", req->attributes );
1907 fprintf( stderr, ", family=%d", req->family );
1908 fprintf( stderr, ", type=%d", req->type );
1909 fprintf( stderr, ", protocol=%d", req->protocol );
1910 fprintf( stderr, ", flags=%08x", req->flags );
1913 static void dump_create_socket_reply( const struct create_socket_reply *req )
1915 fprintf( stderr, " handle=%04x", req->handle );
1918 static void dump_accept_socket_request( const struct accept_socket_request *req )
1920 fprintf( stderr, " lhandle=%04x", req->lhandle );
1921 fprintf( stderr, ", access=%08x", req->access );
1922 fprintf( stderr, ", attributes=%08x", req->attributes );
1925 static void dump_accept_socket_reply( const struct accept_socket_reply *req )
1927 fprintf( stderr, " handle=%04x", req->handle );
1930 static void dump_accept_into_socket_request( const struct accept_into_socket_request *req )
1932 fprintf( stderr, " lhandle=%04x", req->lhandle );
1933 fprintf( stderr, ", ahandle=%04x", req->ahandle );
1936 static void dump_set_socket_event_request( const struct set_socket_event_request *req )
1938 fprintf( stderr, " handle=%04x", req->handle );
1939 fprintf( stderr, ", mask=%08x", req->mask );
1940 fprintf( stderr, ", event=%04x", req->event );
1941 fprintf( stderr, ", window=%08x", req->window );
1942 fprintf( stderr, ", msg=%08x", req->msg );
1945 static void dump_get_socket_event_request( const struct get_socket_event_request *req )
1947 fprintf( stderr, " handle=%04x", req->handle );
1948 fprintf( stderr, ", service=%d", req->service );
1949 fprintf( stderr, ", c_event=%04x", req->c_event );
1952 static void dump_get_socket_event_reply( const struct get_socket_event_reply *req )
1954 fprintf( stderr, " mask=%08x", req->mask );
1955 fprintf( stderr, ", pmask=%08x", req->pmask );
1956 fprintf( stderr, ", state=%08x", req->state );
1957 dump_varargs_ints( ", errors=", cur_size );
1960 static void dump_get_socket_info_request( const struct get_socket_info_request *req )
1962 fprintf( stderr, " handle=%04x", req->handle );
1965 static void dump_get_socket_info_reply( const struct get_socket_info_reply *req )
1967 fprintf( stderr, " family=%d", req->family );
1968 fprintf( stderr, ", type=%d", req->type );
1969 fprintf( stderr, ", protocol=%d", req->protocol );
1972 static void dump_enable_socket_event_request( const struct enable_socket_event_request *req )
1974 fprintf( stderr, " handle=%04x", req->handle );
1975 fprintf( stderr, ", mask=%08x", req->mask );
1976 fprintf( stderr, ", sstate=%08x", req->sstate );
1977 fprintf( stderr, ", cstate=%08x", req->cstate );
1980 static void dump_set_socket_deferred_request( const struct set_socket_deferred_request *req )
1982 fprintf( stderr, " handle=%04x", req->handle );
1983 fprintf( stderr, ", deferred=%04x", req->deferred );
1986 static void dump_alloc_console_request( const struct alloc_console_request *req )
1988 fprintf( stderr, " access=%08x", req->access );
1989 fprintf( stderr, ", attributes=%08x", req->attributes );
1990 fprintf( stderr, ", pid=%04x", req->pid );
1991 fprintf( stderr, ", input_fd=%d", req->input_fd );
1994 static void dump_alloc_console_reply( const struct alloc_console_reply *req )
1996 fprintf( stderr, " handle_in=%04x", req->handle_in );
1997 fprintf( stderr, ", event=%04x", req->event );
2000 static void dump_free_console_request( const struct free_console_request *req )
2004 static void dump_get_console_renderer_events_request( const struct get_console_renderer_events_request *req )
2006 fprintf( stderr, " handle=%04x", req->handle );
2009 static void dump_get_console_renderer_events_reply( const struct get_console_renderer_events_reply *req )
2011 dump_varargs_bytes( " data=", cur_size );
2014 static void dump_open_console_request( const struct open_console_request *req )
2016 fprintf( stderr, " from=%04x", req->from );
2017 fprintf( stderr, ", access=%08x", req->access );
2018 fprintf( stderr, ", attributes=%08x", req->attributes );
2019 fprintf( stderr, ", share=%d", req->share );
2022 static void dump_open_console_reply( const struct open_console_reply *req )
2024 fprintf( stderr, " handle=%04x", req->handle );
2027 static void dump_attach_console_request( const struct attach_console_request *req )
2029 fprintf( stderr, " pid=%04x", req->pid );
2032 static void dump_attach_console_reply( const struct attach_console_reply *req )
2034 fprintf( stderr, " std_in=%04x", req->std_in );
2035 fprintf( stderr, ", std_out=%04x", req->std_out );
2036 fprintf( stderr, ", std_err=%04x", req->std_err );
2039 static void dump_get_console_wait_event_request( const struct get_console_wait_event_request *req )
2041 fprintf( stderr, " handle=%04x", req->handle );
2044 static void dump_get_console_wait_event_reply( const struct get_console_wait_event_reply *req )
2046 fprintf( stderr, " event=%04x", req->event );
2049 static void dump_get_console_mode_request( const struct get_console_mode_request *req )
2051 fprintf( stderr, " handle=%04x", req->handle );
2054 static void dump_get_console_mode_reply( const struct get_console_mode_reply *req )
2056 fprintf( stderr, " mode=%d", req->mode );
2059 static void dump_set_console_mode_request( const struct set_console_mode_request *req )
2061 fprintf( stderr, " handle=%04x", req->handle );
2062 fprintf( stderr, ", mode=%d", req->mode );
2065 static void dump_set_console_input_info_request( const struct set_console_input_info_request *req )
2067 fprintf( stderr, " handle=%04x", req->handle );
2068 fprintf( stderr, ", mask=%d", req->mask );
2069 fprintf( stderr, ", active_sb=%04x", req->active_sb );
2070 fprintf( stderr, ", history_mode=%d", req->history_mode );
2071 fprintf( stderr, ", history_size=%d", req->history_size );
2072 fprintf( stderr, ", edition_mode=%d", req->edition_mode );
2073 fprintf( stderr, ", input_cp=%d", req->input_cp );
2074 fprintf( stderr, ", output_cp=%d", req->output_cp );
2075 fprintf( stderr, ", win=%08x", req->win );
2076 dump_varargs_unicode_str( ", title=", cur_size );
2079 static void dump_get_console_input_info_request( const struct get_console_input_info_request *req )
2081 fprintf( stderr, " handle=%04x", req->handle );
2084 static void dump_get_console_input_info_reply( const struct get_console_input_info_reply *req )
2086 fprintf( stderr, " history_mode=%d", req->history_mode );
2087 fprintf( stderr, ", history_size=%d", req->history_size );
2088 fprintf( stderr, ", history_index=%d", req->history_index );
2089 fprintf( stderr, ", edition_mode=%d", req->edition_mode );
2090 fprintf( stderr, ", input_cp=%d", req->input_cp );
2091 fprintf( stderr, ", output_cp=%d", req->output_cp );
2092 fprintf( stderr, ", win=%08x", req->win );
2093 dump_varargs_unicode_str( ", title=", cur_size );
2096 static void dump_append_console_input_history_request( const struct append_console_input_history_request *req )
2098 fprintf( stderr, " handle=%04x", req->handle );
2099 dump_varargs_unicode_str( ", line=", cur_size );
2102 static void dump_get_console_input_history_request( const struct get_console_input_history_request *req )
2104 fprintf( stderr, " handle=%04x", req->handle );
2105 fprintf( stderr, ", index=%d", req->index );
2108 static void dump_get_console_input_history_reply( const struct get_console_input_history_reply *req )
2110 fprintf( stderr, " total=%d", req->total );
2111 dump_varargs_unicode_str( ", line=", cur_size );
2114 static void dump_create_console_output_request( const struct create_console_output_request *req )
2116 fprintf( stderr, " handle_in=%04x", req->handle_in );
2117 fprintf( stderr, ", access=%08x", req->access );
2118 fprintf( stderr, ", attributes=%08x", req->attributes );
2119 fprintf( stderr, ", share=%08x", req->share );
2120 fprintf( stderr, ", fd=%d", req->fd );
2123 static void dump_create_console_output_reply( const struct create_console_output_reply *req )
2125 fprintf( stderr, " handle_out=%04x", req->handle_out );
2128 static void dump_set_console_output_info_request( const struct set_console_output_info_request *req )
2130 fprintf( stderr, " handle=%04x", req->handle );
2131 fprintf( stderr, ", mask=%d", req->mask );
2132 fprintf( stderr, ", cursor_size=%d", req->cursor_size );
2133 fprintf( stderr, ", cursor_visible=%d", req->cursor_visible );
2134 fprintf( stderr, ", cursor_x=%d", req->cursor_x );
2135 fprintf( stderr, ", cursor_y=%d", req->cursor_y );
2136 fprintf( stderr, ", width=%d", req->width );
2137 fprintf( stderr, ", height=%d", req->height );
2138 fprintf( stderr, ", attr=%d", req->attr );
2139 fprintf( stderr, ", popup_attr=%d", req->popup_attr );
2140 fprintf( stderr, ", win_left=%d", req->win_left );
2141 fprintf( stderr, ", win_top=%d", req->win_top );
2142 fprintf( stderr, ", win_right=%d", req->win_right );
2143 fprintf( stderr, ", win_bottom=%d", req->win_bottom );
2144 fprintf( stderr, ", max_width=%d", req->max_width );
2145 fprintf( stderr, ", max_height=%d", req->max_height );
2146 fprintf( stderr, ", font_width=%d", req->font_width );
2147 fprintf( stderr, ", font_height=%d", req->font_height );
2148 fprintf( stderr, ", font_weight=%d", req->font_weight );
2149 fprintf( stderr, ", font_pitch_family=%d", req->font_pitch_family );
2150 dump_varargs_uints( ", colors=", min(cur_size,64) );
2151 dump_varargs_unicode_str( ", face_name=", cur_size );
2154 static void dump_get_console_output_info_request( const struct get_console_output_info_request *req )
2156 fprintf( stderr, " handle=%04x", req->handle );
2159 static void dump_get_console_output_info_reply( const struct get_console_output_info_reply *req )
2161 fprintf( stderr, " cursor_size=%d", req->cursor_size );
2162 fprintf( stderr, ", cursor_visible=%d", req->cursor_visible );
2163 fprintf( stderr, ", cursor_x=%d", req->cursor_x );
2164 fprintf( stderr, ", cursor_y=%d", req->cursor_y );
2165 fprintf( stderr, ", width=%d", req->width );
2166 fprintf( stderr, ", height=%d", req->height );
2167 fprintf( stderr, ", attr=%d", req->attr );
2168 fprintf( stderr, ", popup_attr=%d", req->popup_attr );
2169 fprintf( stderr, ", win_left=%d", req->win_left );
2170 fprintf( stderr, ", win_top=%d", req->win_top );
2171 fprintf( stderr, ", win_right=%d", req->win_right );
2172 fprintf( stderr, ", win_bottom=%d", req->win_bottom );
2173 fprintf( stderr, ", max_width=%d", req->max_width );
2174 fprintf( stderr, ", max_height=%d", req->max_height );
2175 fprintf( stderr, ", font_width=%d", req->font_width );
2176 fprintf( stderr, ", font_height=%d", req->font_height );
2177 fprintf( stderr, ", font_weight=%d", req->font_weight );
2178 fprintf( stderr, ", font_pitch_family=%d", req->font_pitch_family );
2179 dump_varargs_uints( ", colors=", min(cur_size,64) );
2180 dump_varargs_unicode_str( ", face_name=", cur_size );
2183 static void dump_write_console_input_request( const struct write_console_input_request *req )
2185 fprintf( stderr, " handle=%04x", req->handle );
2186 dump_varargs_input_records( ", rec=", cur_size );
2189 static void dump_write_console_input_reply( const struct write_console_input_reply *req )
2191 fprintf( stderr, " written=%d", req->written );
2194 static void dump_read_console_input_request( const struct read_console_input_request *req )
2196 fprintf( stderr, " handle=%04x", req->handle );
2197 fprintf( stderr, ", flush=%d", req->flush );
2200 static void dump_read_console_input_reply( const struct read_console_input_reply *req )
2202 fprintf( stderr, " read=%d", req->read );
2203 dump_varargs_input_records( ", rec=", cur_size );
2206 static void dump_write_console_output_request( const struct write_console_output_request *req )
2208 fprintf( stderr, " handle=%04x", req->handle );
2209 fprintf( stderr, ", x=%d", req->x );
2210 fprintf( stderr, ", y=%d", req->y );
2211 fprintf( stderr, ", mode=%d", req->mode );
2212 fprintf( stderr, ", wrap=%d", req->wrap );
2213 dump_varargs_bytes( ", data=", cur_size );
2216 static void dump_write_console_output_reply( const struct write_console_output_reply *req )
2218 fprintf( stderr, " written=%d", req->written );
2219 fprintf( stderr, ", width=%d", req->width );
2220 fprintf( stderr, ", height=%d", req->height );
2223 static void dump_fill_console_output_request( const struct fill_console_output_request *req )
2225 fprintf( stderr, " handle=%04x", req->handle );
2226 fprintf( stderr, ", x=%d", req->x );
2227 fprintf( stderr, ", y=%d", req->y );
2228 fprintf( stderr, ", mode=%d", req->mode );
2229 fprintf( stderr, ", count=%d", req->count );
2230 fprintf( stderr, ", wrap=%d", req->wrap );
2231 dump_char_info( ", data=", &req->data );
2234 static void dump_fill_console_output_reply( const struct fill_console_output_reply *req )
2236 fprintf( stderr, " written=%d", req->written );
2239 static void dump_read_console_output_request( const struct read_console_output_request *req )
2241 fprintf( stderr, " handle=%04x", req->handle );
2242 fprintf( stderr, ", x=%d", req->x );
2243 fprintf( stderr, ", y=%d", req->y );
2244 fprintf( stderr, ", mode=%d", req->mode );
2245 fprintf( stderr, ", wrap=%d", req->wrap );
2248 static void dump_read_console_output_reply( const struct read_console_output_reply *req )
2250 fprintf( stderr, " width=%d", req->width );
2251 fprintf( stderr, ", height=%d", req->height );
2252 dump_varargs_bytes( ", data=", cur_size );
2255 static void dump_move_console_output_request( const struct move_console_output_request *req )
2257 fprintf( stderr, " handle=%04x", req->handle );
2258 fprintf( stderr, ", x_src=%d", req->x_src );
2259 fprintf( stderr, ", y_src=%d", req->y_src );
2260 fprintf( stderr, ", x_dst=%d", req->x_dst );
2261 fprintf( stderr, ", y_dst=%d", req->y_dst );
2262 fprintf( stderr, ", w=%d", req->w );
2263 fprintf( stderr, ", h=%d", req->h );
2266 static void dump_send_console_signal_request( const struct send_console_signal_request *req )
2268 fprintf( stderr, " signal=%d", req->signal );
2269 fprintf( stderr, ", group_id=%04x", req->group_id );
2272 static void dump_read_directory_changes_request( const struct read_directory_changes_request *req )
2274 fprintf( stderr, " filter=%08x", req->filter );
2275 fprintf( stderr, ", subtree=%d", req->subtree );
2276 fprintf( stderr, ", want_data=%d", req->want_data );
2277 dump_async_data( ", async=", &req->async );
2280 static void dump_read_change_request( const struct read_change_request *req )
2282 fprintf( stderr, " handle=%04x", req->handle );
2285 static void dump_read_change_reply( const struct read_change_reply *req )
2287 dump_varargs_filesystem_event( " events=", cur_size );
2290 static void dump_create_mapping_request( const struct create_mapping_request *req )
2292 fprintf( stderr, " access=%08x", req->access );
2293 fprintf( stderr, ", flags=%08x", req->flags );
2294 fprintf( stderr, ", file_access=%08x", req->file_access );
2295 dump_uint64( ", size=", &req->size );
2296 fprintf( stderr, ", file_handle=%04x", req->file_handle );
2297 dump_varargs_object_attributes( ", objattr=", cur_size );
2300 static void dump_create_mapping_reply( const struct create_mapping_reply *req )
2302 fprintf( stderr, " handle=%04x", req->handle );
2305 static void dump_open_mapping_request( const struct open_mapping_request *req )
2307 fprintf( stderr, " access=%08x", req->access );
2308 fprintf( stderr, ", attributes=%08x", req->attributes );
2309 fprintf( stderr, ", rootdir=%04x", req->rootdir );
2310 dump_varargs_unicode_str( ", name=", cur_size );
2313 static void dump_open_mapping_reply( const struct open_mapping_reply *req )
2315 fprintf( stderr, " handle=%04x", req->handle );
2318 static void dump_get_mapping_info_request( const struct get_mapping_info_request *req )
2320 fprintf( stderr, " handle=%04x", req->handle );
2321 fprintf( stderr, ", access=%08x", req->access );
2324 static void dump_get_mapping_info_reply( const struct get_mapping_info_reply *req )
2326 dump_uint64( " size=", &req->size );
2327 fprintf( stderr, ", flags=%08x", req->flags );
2328 fprintf( stderr, ", shared_file=%04x", req->shared_file );
2329 dump_varargs_pe_image_info( ", image=", cur_size );
2332 static void dump_map_view_request( const struct map_view_request *req )
2334 fprintf( stderr, " mapping=%04x", req->mapping );
2335 fprintf( stderr, ", access=%08x", req->access );
2336 dump_uint64( ", base=", &req->base );
2337 dump_uint64( ", size=", &req->size );
2338 dump_uint64( ", start=", &req->start );
2341 static void dump_unmap_view_request( const struct unmap_view_request *req )
2343 dump_uint64( " base=", &req->base );
2346 static void dump_get_mapping_committed_range_request( const struct get_mapping_committed_range_request *req )
2348 dump_uint64( " base=", &req->base );
2349 dump_uint64( ", offset=", &req->offset );
2352 static void dump_get_mapping_committed_range_reply( const struct get_mapping_committed_range_reply *req )
2354 dump_uint64( " size=", &req->size );
2355 fprintf( stderr, ", committed=%d", req->committed );
2358 static void dump_add_mapping_committed_range_request( const struct add_mapping_committed_range_request *req )
2360 dump_uint64( " base=", &req->base );
2361 dump_uint64( ", offset=", &req->offset );
2362 dump_uint64( ", size=", &req->size );
2365 static void dump_is_same_mapping_request( const struct is_same_mapping_request *req )
2367 dump_uint64( " base1=", &req->base1 );
2368 dump_uint64( ", base2=", &req->base2 );
2371 static void dump_create_snapshot_request( const struct create_snapshot_request *req )
2373 fprintf( stderr, " attributes=%08x", req->attributes );
2374 fprintf( stderr, ", flags=%08x", req->flags );
2377 static void dump_create_snapshot_reply( const struct create_snapshot_reply *req )
2379 fprintf( stderr, " handle=%04x", req->handle );
2382 static void dump_next_process_request( const struct next_process_request *req )
2384 fprintf( stderr, " handle=%04x", req->handle );
2385 fprintf( stderr, ", reset=%d", req->reset );
2388 static void dump_next_process_reply( const struct next_process_reply *req )
2390 fprintf( stderr, " count=%d", req->count );
2391 fprintf( stderr, ", pid=%04x", req->pid );
2392 fprintf( stderr, ", ppid=%04x", req->ppid );
2393 fprintf( stderr, ", threads=%d", req->threads );
2394 fprintf( stderr, ", priority=%d", req->priority );
2395 fprintf( stderr, ", handles=%d", req->handles );
2396 fprintf( stderr, ", unix_pid=%d", req->unix_pid );
2397 dump_varargs_unicode_str( ", filename=", cur_size );
2400 static void dump_next_thread_request( const struct next_thread_request *req )
2402 fprintf( stderr, " handle=%04x", req->handle );
2403 fprintf( stderr, ", reset=%d", req->reset );
2406 static void dump_next_thread_reply( const struct next_thread_reply *req )
2408 fprintf( stderr, " count=%d", req->count );
2409 fprintf( stderr, ", pid=%04x", req->pid );
2410 fprintf( stderr, ", tid=%04x", req->tid );
2411 fprintf( stderr, ", base_pri=%d", req->base_pri );
2412 fprintf( stderr, ", delta_pri=%d", req->delta_pri );
2415 static void dump_wait_debug_event_request( const struct wait_debug_event_request *req )
2417 fprintf( stderr, " get_handle=%d", req->get_handle );
2420 static void dump_wait_debug_event_reply( const struct wait_debug_event_reply *req )
2422 fprintf( stderr, " pid=%04x", req->pid );
2423 fprintf( stderr, ", tid=%04x", req->tid );
2424 fprintf( stderr, ", wait=%04x", req->wait );
2425 dump_varargs_debug_event( ", event=", cur_size );
2428 static void dump_queue_exception_event_request( const struct queue_exception_event_request *req )
2430 fprintf( stderr, " first=%d", req->first );
2431 fprintf( stderr, ", code=%08x", req->code );
2432 fprintf( stderr, ", flags=%08x", req->flags );
2433 dump_uint64( ", record=", &req->record );
2434 dump_uint64( ", address=", &req->address );
2435 fprintf( stderr, ", len=%u", req->len );
2436 dump_varargs_uints64( ", params=", min(cur_size,req->len) );
2439 static void dump_queue_exception_event_reply( const struct queue_exception_event_reply *req )
2441 fprintf( stderr, " handle=%04x", req->handle );
2444 static void dump_get_exception_status_request( const struct get_exception_status_request *req )
2446 fprintf( stderr, " handle=%04x", req->handle );
2449 static void dump_continue_debug_event_request( const struct continue_debug_event_request *req )
2451 fprintf( stderr, " pid=%04x", req->pid );
2452 fprintf( stderr, ", tid=%04x", req->tid );
2453 fprintf( stderr, ", status=%d", req->status );
2456 static void dump_debug_process_request( const struct debug_process_request *req )
2458 fprintf( stderr, " pid=%04x", req->pid );
2459 fprintf( stderr, ", attach=%d", req->attach );
2462 static void dump_set_debugger_kill_on_exit_request( const struct set_debugger_kill_on_exit_request *req )
2464 fprintf( stderr, " kill_on_exit=%d", req->kill_on_exit );
2467 static void dump_read_process_memory_request( const struct read_process_memory_request *req )
2469 fprintf( stderr, " handle=%04x", req->handle );
2470 dump_uint64( ", addr=", &req->addr );
2473 static void dump_read_process_memory_reply( const struct read_process_memory_reply *req )
2475 dump_varargs_bytes( " data=", cur_size );
2478 static void dump_write_process_memory_request( const struct write_process_memory_request *req )
2480 fprintf( stderr, " handle=%04x", req->handle );
2481 dump_uint64( ", addr=", &req->addr );
2482 dump_varargs_bytes( ", data=", cur_size );
2485 static void dump_create_key_request( const struct create_key_request *req )
2487 fprintf( stderr, " access=%08x", req->access );
2488 fprintf( stderr, ", options=%08x", req->options );
2489 dump_varargs_object_attributes( ", objattr=", cur_size );
2490 dump_varargs_unicode_str( ", class=", cur_size );
2493 static void dump_create_key_reply( const struct create_key_reply *req )
2495 fprintf( stderr, " hkey=%04x", req->hkey );
2496 fprintf( stderr, ", created=%d", req->created );
2499 static void dump_open_key_request( const struct open_key_request *req )
2501 fprintf( stderr, " parent=%04x", req->parent );
2502 fprintf( stderr, ", access=%08x", req->access );
2503 fprintf( stderr, ", attributes=%08x", req->attributes );
2504 dump_varargs_unicode_str( ", name=", cur_size );
2507 static void dump_open_key_reply( const struct open_key_reply *req )
2509 fprintf( stderr, " hkey=%04x", req->hkey );
2512 static void dump_delete_key_request( const struct delete_key_request *req )
2514 fprintf( stderr, " hkey=%04x", req->hkey );
2517 static void dump_flush_key_request( const struct flush_key_request *req )
2519 fprintf( stderr, " hkey=%04x", req->hkey );
2522 static void dump_enum_key_request( const struct enum_key_request *req )
2524 fprintf( stderr, " hkey=%04x", req->hkey );
2525 fprintf( stderr, ", index=%d", req->index );
2526 fprintf( stderr, ", info_class=%d", req->info_class );
2529 static void dump_enum_key_reply( const struct enum_key_reply *req )
2531 fprintf( stderr, " subkeys=%d", req->subkeys );
2532 fprintf( stderr, ", max_subkey=%d", req->max_subkey );
2533 fprintf( stderr, ", max_class=%d", req->max_class );
2534 fprintf( stderr, ", values=%d", req->values );
2535 fprintf( stderr, ", max_value=%d", req->max_value );
2536 fprintf( stderr, ", max_data=%d", req->max_data );
2537 dump_timeout( ", modif=", &req->modif );
2538 fprintf( stderr, ", total=%u", req->total );
2539 fprintf( stderr, ", namelen=%u", req->namelen );
2540 dump_varargs_unicode_str( ", name=", min(cur_size,req->namelen) );
2541 dump_varargs_unicode_str( ", class=", cur_size );
2544 static void dump_set_key_value_request( const struct set_key_value_request *req )
2546 fprintf( stderr, " hkey=%04x", req->hkey );
2547 fprintf( stderr, ", type=%d", req->type );
2548 fprintf( stderr, ", namelen=%u", req->namelen );
2549 dump_varargs_unicode_str( ", name=", min(cur_size,req->namelen) );
2550 dump_varargs_bytes( ", data=", cur_size );
2553 static void dump_get_key_value_request( const struct get_key_value_request *req )
2555 fprintf( stderr, " hkey=%04x", req->hkey );
2556 dump_varargs_unicode_str( ", name=", cur_size );
2559 static void dump_get_key_value_reply( const struct get_key_value_reply *req )
2561 fprintf( stderr, " type=%d", req->type );
2562 fprintf( stderr, ", total=%u", req->total );
2563 dump_varargs_bytes( ", data=", cur_size );
2566 static void dump_enum_key_value_request( const struct enum_key_value_request *req )
2568 fprintf( stderr, " hkey=%04x", req->hkey );
2569 fprintf( stderr, ", index=%d", req->index );
2570 fprintf( stderr, ", info_class=%d", req->info_class );
2573 static void dump_enum_key_value_reply( const struct enum_key_value_reply *req )
2575 fprintf( stderr, " type=%d", req->type );
2576 fprintf( stderr, ", total=%u", req->total );
2577 fprintf( stderr, ", namelen=%u", req->namelen );
2578 dump_varargs_unicode_str( ", name=", min(cur_size,req->namelen) );
2579 dump_varargs_bytes( ", data=", cur_size );
2582 static void dump_delete_key_value_request( const struct delete_key_value_request *req )
2584 fprintf( stderr, " hkey=%04x", req->hkey );
2585 dump_varargs_unicode_str( ", name=", cur_size );
2588 static void dump_load_registry_request( const struct load_registry_request *req )
2590 fprintf( stderr, " file=%04x", req->file );
2591 dump_varargs_object_attributes( ", objattr=", cur_size );
2594 static void dump_unload_registry_request( const struct unload_registry_request *req )
2596 fprintf( stderr, " hkey=%04x", req->hkey );
2599 static void dump_save_registry_request( const struct save_registry_request *req )
2601 fprintf( stderr, " hkey=%04x", req->hkey );
2602 fprintf( stderr, ", file=%04x", req->file );
2605 static void dump_set_registry_notification_request( const struct set_registry_notification_request *req )
2607 fprintf( stderr, " hkey=%04x", req->hkey );
2608 fprintf( stderr, ", event=%04x", req->event );
2609 fprintf( stderr, ", subtree=%d", req->subtree );
2610 fprintf( stderr, ", filter=%08x", req->filter );
2613 static void dump_create_timer_request( const struct create_timer_request *req )
2615 fprintf( stderr, " access=%08x", req->access );
2616 fprintf( stderr, ", manual=%d", req->manual );
2617 dump_varargs_object_attributes( ", objattr=", cur_size );
2620 static void dump_create_timer_reply( const struct create_timer_reply *req )
2622 fprintf( stderr, " handle=%04x", req->handle );
2625 static void dump_open_timer_request( const struct open_timer_request *req )
2627 fprintf( stderr, " access=%08x", req->access );
2628 fprintf( stderr, ", attributes=%08x", req->attributes );
2629 fprintf( stderr, ", rootdir=%04x", req->rootdir );
2630 dump_varargs_unicode_str( ", name=", cur_size );
2633 static void dump_open_timer_reply( const struct open_timer_reply *req )
2635 fprintf( stderr, " handle=%04x", req->handle );
2638 static void dump_set_timer_request( const struct set_timer_request *req )
2640 fprintf( stderr, " handle=%04x", req->handle );
2641 dump_timeout( ", expire=", &req->expire );
2642 dump_uint64( ", callback=", &req->callback );
2643 dump_uint64( ", arg=", &req->arg );
2644 fprintf( stderr, ", period=%d", req->period );
2647 static void dump_set_timer_reply( const struct set_timer_reply *req )
2649 fprintf( stderr, " signaled=%d", req->signaled );
2652 static void dump_cancel_timer_request( const struct cancel_timer_request *req )
2654 fprintf( stderr, " handle=%04x", req->handle );
2657 static void dump_cancel_timer_reply( const struct cancel_timer_reply *req )
2659 fprintf( stderr, " signaled=%d", req->signaled );
2662 static void dump_get_timer_info_request( const struct get_timer_info_request *req )
2664 fprintf( stderr, " handle=%04x", req->handle );
2667 static void dump_get_timer_info_reply( const struct get_timer_info_reply *req )
2669 dump_timeout( " when=", &req->when );
2670 fprintf( stderr, ", signaled=%d", req->signaled );
2673 static void dump_get_thread_context_request( const struct get_thread_context_request *req )
2675 fprintf( stderr, " handle=%04x", req->handle );
2676 fprintf( stderr, ", flags=%08x", req->flags );
2679 static void dump_get_thread_context_reply( const struct get_thread_context_reply *req )
2681 fprintf( stderr, " self=%d", req->self );
2682 fprintf( stderr, ", handle=%04x", req->handle );
2683 dump_varargs_context( ", context=", cur_size );
2686 static void dump_set_thread_context_request( const struct set_thread_context_request *req )
2688 fprintf( stderr, " handle=%04x", req->handle );
2689 dump_varargs_context( ", context=", cur_size );
2692 static void dump_set_thread_context_reply( const struct set_thread_context_reply *req )
2694 fprintf( stderr, " self=%d", req->self );
2697 static void dump_get_selector_entry_request( const struct get_selector_entry_request *req )
2699 fprintf( stderr, " handle=%04x", req->handle );
2700 fprintf( stderr, ", entry=%d", req->entry );
2703 static void dump_get_selector_entry_reply( const struct get_selector_entry_reply *req )
2705 fprintf( stderr, " base=%08x", req->base );
2706 fprintf( stderr, ", limit=%08x", req->limit );
2707 fprintf( stderr, ", flags=%02x", req->flags );
2710 static void dump_add_atom_request( const struct add_atom_request *req )
2712 fprintf( stderr, " table=%04x", req->table );
2713 dump_varargs_unicode_str( ", name=", cur_size );
2716 static void dump_add_atom_reply( const struct add_atom_reply *req )
2718 fprintf( stderr, " atom=%04x", req->atom );
2721 static void dump_delete_atom_request( const struct delete_atom_request *req )
2723 fprintf( stderr, " table=%04x", req->table );
2724 fprintf( stderr, ", atom=%04x", req->atom );
2727 static void dump_find_atom_request( const struct find_atom_request *req )
2729 fprintf( stderr, " table=%04x", req->table );
2730 dump_varargs_unicode_str( ", name=", cur_size );
2733 static void dump_find_atom_reply( const struct find_atom_reply *req )
2735 fprintf( stderr, " atom=%04x", req->atom );
2738 static void dump_get_atom_information_request( const struct get_atom_information_request *req )
2740 fprintf( stderr, " table=%04x", req->table );
2741 fprintf( stderr, ", atom=%04x", req->atom );
2744 static void dump_get_atom_information_reply( const struct get_atom_information_reply *req )
2746 fprintf( stderr, " count=%d", req->count );
2747 fprintf( stderr, ", pinned=%d", req->pinned );
2748 fprintf( stderr, ", total=%u", req->total );
2749 dump_varargs_unicode_str( ", name=", cur_size );
2752 static void dump_set_atom_information_request( const struct set_atom_information_request *req )
2754 fprintf( stderr, " table=%04x", req->table );
2755 fprintf( stderr, ", atom=%04x", req->atom );
2756 fprintf( stderr, ", pinned=%d", req->pinned );
2759 static void dump_empty_atom_table_request( const struct empty_atom_table_request *req )
2761 fprintf( stderr, " table=%04x", req->table );
2762 fprintf( stderr, ", if_pinned=%d", req->if_pinned );
2765 static void dump_init_atom_table_request( const struct init_atom_table_request *req )
2767 fprintf( stderr, " entries=%d", req->entries );
2770 static void dump_init_atom_table_reply( const struct init_atom_table_reply *req )
2772 fprintf( stderr, " table=%04x", req->table );
2775 static void dump_get_msg_queue_request( const struct get_msg_queue_request *req )
2779 static void dump_get_msg_queue_reply( const struct get_msg_queue_reply *req )
2781 fprintf( stderr, " handle=%04x", req->handle );
2784 static void dump_set_queue_fd_request( const struct set_queue_fd_request *req )
2786 fprintf( stderr, " handle=%04x", req->handle );
2789 static void dump_set_queue_mask_request( const struct set_queue_mask_request *req )
2791 fprintf( stderr, " wake_mask=%08x", req->wake_mask );
2792 fprintf( stderr, ", changed_mask=%08x", req->changed_mask );
2793 fprintf( stderr, ", skip_wait=%d", req->skip_wait );
2796 static void dump_set_queue_mask_reply( const struct set_queue_mask_reply *req )
2798 fprintf( stderr, " wake_bits=%08x", req->wake_bits );
2799 fprintf( stderr, ", changed_bits=%08x", req->changed_bits );
2802 static void dump_get_queue_status_request( const struct get_queue_status_request *req )
2804 fprintf( stderr, " clear_bits=%08x", req->clear_bits );
2807 static void dump_get_queue_status_reply( const struct get_queue_status_reply *req )
2809 fprintf( stderr, " wake_bits=%08x", req->wake_bits );
2810 fprintf( stderr, ", changed_bits=%08x", req->changed_bits );
2813 static void dump_get_process_idle_event_request( const struct get_process_idle_event_request *req )
2815 fprintf( stderr, " handle=%04x", req->handle );
2818 static void dump_get_process_idle_event_reply( const struct get_process_idle_event_reply *req )
2820 fprintf( stderr, " event=%04x", req->event );
2823 static void dump_send_message_request( const struct send_message_request *req )
2825 fprintf( stderr, " id=%04x", req->id );
2826 fprintf( stderr, ", type=%d", req->type );
2827 fprintf( stderr, ", flags=%d", req->flags );
2828 fprintf( stderr, ", win=%08x", req->win );
2829 fprintf( stderr, ", msg=%08x", req->msg );
2830 dump_uint64( ", wparam=", &req->wparam );
2831 dump_uint64( ", lparam=", &req->lparam );
2832 dump_timeout( ", timeout=", &req->timeout );
2833 dump_varargs_message_data( ", data=", cur_size );
2836 static void dump_post_quit_message_request( const struct post_quit_message_request *req )
2838 fprintf( stderr, " exit_code=%d", req->exit_code );
2841 static void dump_send_hardware_message_request( const struct send_hardware_message_request *req )
2843 fprintf( stderr, " win=%08x", req->win );
2844 dump_hw_input( ", input=", &req->input );
2845 fprintf( stderr, ", flags=%08x", req->flags );
2848 static void dump_send_hardware_message_reply( const struct send_hardware_message_reply *req )
2850 fprintf( stderr, " wait=%d", req->wait );
2851 fprintf( stderr, ", prev_x=%d", req->prev_x );
2852 fprintf( stderr, ", prev_y=%d", req->prev_y );
2853 fprintf( stderr, ", new_x=%d", req->new_x );
2854 fprintf( stderr, ", new_y=%d", req->new_y );
2855 dump_varargs_bytes( ", keystate=", cur_size );
2858 static void dump_get_message_request( const struct get_message_request *req )
2860 fprintf( stderr, " flags=%08x", req->flags );
2861 fprintf( stderr, ", get_win=%08x", req->get_win );
2862 fprintf( stderr, ", get_first=%08x", req->get_first );
2863 fprintf( stderr, ", get_last=%08x", req->get_last );
2864 fprintf( stderr, ", hw_id=%08x", req->hw_id );
2865 fprintf( stderr, ", wake_mask=%08x", req->wake_mask );
2866 fprintf( stderr, ", changed_mask=%08x", req->changed_mask );
2869 static void dump_get_message_reply( const struct get_message_reply *req )
2871 fprintf( stderr, " win=%08x", req->win );
2872 fprintf( stderr, ", msg=%08x", req->msg );
2873 dump_uint64( ", wparam=", &req->wparam );
2874 dump_uint64( ", lparam=", &req->lparam );
2875 fprintf( stderr, ", type=%d", req->type );
2876 fprintf( stderr, ", x=%d", req->x );
2877 fprintf( stderr, ", y=%d", req->y );
2878 fprintf( stderr, ", time=%08x", req->time );
2879 fprintf( stderr, ", active_hooks=%08x", req->active_hooks );
2880 fprintf( stderr, ", total=%u", req->total );
2881 dump_varargs_message_data( ", data=", cur_size );
2884 static void dump_reply_message_request( const struct reply_message_request *req )
2886 fprintf( stderr, " remove=%d", req->remove );
2887 dump_uint64( ", result=", &req->result );
2888 dump_varargs_bytes( ", data=", cur_size );
2891 static void dump_accept_hardware_message_request( const struct accept_hardware_message_request *req )
2893 fprintf( stderr, " hw_id=%08x", req->hw_id );
2894 fprintf( stderr, ", remove=%d", req->remove );
2897 static void dump_get_message_reply_request( const struct get_message_reply_request *req )
2899 fprintf( stderr, " cancel=%d", req->cancel );
2902 static void dump_get_message_reply_reply( const struct get_message_reply_reply *req )
2904 dump_uint64( " result=", &req->result );
2905 dump_varargs_bytes( ", data=", cur_size );
2908 static void dump_set_win_timer_request( const struct set_win_timer_request *req )
2910 fprintf( stderr, " win=%08x", req->win );
2911 fprintf( stderr, ", msg=%08x", req->msg );
2912 fprintf( stderr, ", rate=%08x", req->rate );
2913 dump_uint64( ", id=", &req->id );
2914 dump_uint64( ", lparam=", &req->lparam );
2917 static void dump_set_win_timer_reply( const struct set_win_timer_reply *req )
2919 dump_uint64( " id=", &req->id );
2922 static void dump_kill_win_timer_request( const struct kill_win_timer_request *req )
2924 fprintf( stderr, " win=%08x", req->win );
2925 dump_uint64( ", id=", &req->id );
2926 fprintf( stderr, ", msg=%08x", req->msg );
2929 static void dump_is_window_hung_request( const struct is_window_hung_request *req )
2931 fprintf( stderr, " win=%08x", req->win );
2934 static void dump_is_window_hung_reply( const struct is_window_hung_reply *req )
2936 fprintf( stderr, " is_hung=%d", req->is_hung );
2939 static void dump_get_serial_info_request( const struct get_serial_info_request *req )
2941 fprintf( stderr, " handle=%04x", req->handle );
2942 fprintf( stderr, ", flags=%d", req->flags );
2945 static void dump_get_serial_info_reply( const struct get_serial_info_reply *req )
2947 fprintf( stderr, " eventmask=%08x", req->eventmask );
2948 fprintf( stderr, ", cookie=%08x", req->cookie );
2949 fprintf( stderr, ", pending_write=%08x", req->pending_write );
2952 static void dump_set_serial_info_request( const struct set_serial_info_request *req )
2954 fprintf( stderr, " handle=%04x", req->handle );
2955 fprintf( stderr, ", flags=%d", req->flags );
2958 static void dump_register_async_request( const struct register_async_request *req )
2960 fprintf( stderr, " type=%d", req->type );
2961 dump_async_data( ", async=", &req->async );
2962 fprintf( stderr, ", count=%d", req->count );
2965 static void dump_cancel_async_request( const struct cancel_async_request *req )
2967 fprintf( stderr, " handle=%04x", req->handle );
2968 dump_uint64( ", iosb=", &req->iosb );
2969 fprintf( stderr, ", only_thread=%d", req->only_thread );
2972 static void dump_get_async_result_request( const struct get_async_result_request *req )
2974 dump_uint64( " user_arg=", &req->user_arg );
2977 static void dump_get_async_result_reply( const struct get_async_result_reply *req )
2979 fprintf( stderr, " size=%u", req->size );
2980 dump_varargs_bytes( ", out_data=", cur_size );
2983 static void dump_read_request( const struct read_request *req )
2985 dump_async_data( " async=", &req->async );
2986 dump_uint64( ", pos=", &req->pos );
2989 static void dump_read_reply( const struct read_reply *req )
2991 fprintf( stderr, " wait=%04x", req->wait );
2992 fprintf( stderr, ", options=%08x", req->options );
2993 dump_varargs_bytes( ", data=", cur_size );
2996 static void dump_write_request( const struct write_request *req )
2998 dump_async_data( " async=", &req->async );
2999 dump_uint64( ", pos=", &req->pos );
3000 dump_varargs_bytes( ", data=", cur_size );
3003 static void dump_write_reply( const struct write_reply *req )
3005 fprintf( stderr, " wait=%04x", req->wait );
3006 fprintf( stderr, ", options=%08x", req->options );
3007 fprintf( stderr, ", size=%u", req->size );
3010 static void dump_ioctl_request( const struct ioctl_request *req )
3012 dump_ioctl_code( " code=", &req->code );
3013 dump_async_data( ", async=", &req->async );
3014 dump_varargs_bytes( ", in_data=", cur_size );
3017 static void dump_ioctl_reply( const struct ioctl_reply *req )
3019 fprintf( stderr, " wait=%04x", req->wait );
3020 fprintf( stderr, ", options=%08x", req->options );
3021 dump_varargs_bytes( ", out_data=", cur_size );
3024 static void dump_set_irp_result_request( const struct set_irp_result_request *req )
3026 fprintf( stderr, " handle=%04x", req->handle );
3027 fprintf( stderr, ", status=%08x", req->status );
3028 fprintf( stderr, ", size=%u", req->size );
3029 dump_varargs_bytes( ", data=", cur_size );
3032 static void dump_create_named_pipe_request( const struct create_named_pipe_request *req )
3034 fprintf( stderr, " access=%08x", req->access );
3035 fprintf( stderr, ", options=%08x", req->options );
3036 fprintf( stderr, ", sharing=%08x", req->sharing );
3037 fprintf( stderr, ", maxinstances=%08x", req->maxinstances );
3038 fprintf( stderr, ", outsize=%08x", req->outsize );
3039 fprintf( stderr, ", insize=%08x", req->insize );
3040 dump_timeout( ", timeout=", &req->timeout );
3041 fprintf( stderr, ", flags=%08x", req->flags );
3042 dump_varargs_object_attributes( ", objattr=", cur_size );
3045 static void dump_create_named_pipe_reply( const struct create_named_pipe_reply *req )
3047 fprintf( stderr, " handle=%04x", req->handle );
3050 static void dump_set_named_pipe_info_request( const struct set_named_pipe_info_request *req )
3052 fprintf( stderr, " handle=%04x", req->handle );
3053 fprintf( stderr, ", flags=%08x", req->flags );
3056 static void dump_create_window_request( const struct create_window_request *req )
3058 fprintf( stderr, " parent=%08x", req->parent );
3059 fprintf( stderr, ", owner=%08x", req->owner );
3060 fprintf( stderr, ", atom=%04x", req->atom );
3061 dump_uint64( ", instance=", &req->instance );
3062 fprintf( stderr, ", dpi=%d", req->dpi );
3063 fprintf( stderr, ", awareness=%d", req->awareness );
3064 dump_varargs_unicode_str( ", class=", cur_size );
3067 static void dump_create_window_reply( const struct create_window_reply *req )
3069 fprintf( stderr, " handle=%08x", req->handle );
3070 fprintf( stderr, ", parent=%08x", req->parent );
3071 fprintf( stderr, ", owner=%08x", req->owner );
3072 fprintf( stderr, ", extra=%d", req->extra );
3073 dump_uint64( ", class_ptr=", &req->class_ptr );
3074 fprintf( stderr, ", dpi=%d", req->dpi );
3075 fprintf( stderr, ", awareness=%d", req->awareness );
3078 static void dump_destroy_window_request( const struct destroy_window_request *req )
3080 fprintf( stderr, " handle=%08x", req->handle );
3083 static void dump_get_desktop_window_request( const struct get_desktop_window_request *req )
3085 fprintf( stderr, " force=%d", req->force );
3088 static void dump_get_desktop_window_reply( const struct get_desktop_window_reply *req )
3090 fprintf( stderr, " top_window=%08x", req->top_window );
3091 fprintf( stderr, ", msg_window=%08x", req->msg_window );
3094 static void dump_set_window_owner_request( const struct set_window_owner_request *req )
3096 fprintf( stderr, " handle=%08x", req->handle );
3097 fprintf( stderr, ", owner=%08x", req->owner );
3100 static void dump_set_window_owner_reply( const struct set_window_owner_reply *req )
3102 fprintf( stderr, " full_owner=%08x", req->full_owner );
3103 fprintf( stderr, ", prev_owner=%08x", req->prev_owner );
3106 static void dump_get_window_info_request( const struct get_window_info_request *req )
3108 fprintf( stderr, " handle=%08x", req->handle );
3111 static void dump_get_window_info_reply( const struct get_window_info_reply *req )
3113 fprintf( stderr, " full_handle=%08x", req->full_handle );
3114 fprintf( stderr, ", last_active=%08x", req->last_active );
3115 fprintf( stderr, ", pid=%04x", req->pid );
3116 fprintf( stderr, ", tid=%04x", req->tid );
3117 fprintf( stderr, ", atom=%04x", req->atom );
3118 fprintf( stderr, ", is_unicode=%d", req->is_unicode );
3119 fprintf( stderr, ", dpi=%d", req->dpi );
3120 fprintf( stderr, ", awareness=%d", req->awareness );
3123 static void dump_set_window_info_request( const struct set_window_info_request *req )
3125 fprintf( stderr, " flags=%04x", req->flags );
3126 fprintf( stderr, ", is_unicode=%d", req->is_unicode );
3127 fprintf( stderr, ", handle=%08x", req->handle );
3128 fprintf( stderr, ", style=%08x", req->style );
3129 fprintf( stderr, ", ex_style=%08x", req->ex_style );
3130 fprintf( stderr, ", id=%08x", req->id );
3131 dump_uint64( ", instance=", &req->instance );
3132 dump_uint64( ", user_data=", &req->user_data );
3133 fprintf( stderr, ", extra_offset=%d", req->extra_offset );
3134 fprintf( stderr, ", extra_size=%u", req->extra_size );
3135 dump_uint64( ", extra_value=", &req->extra_value );
3138 static void dump_set_window_info_reply( const struct set_window_info_reply *req )
3140 fprintf( stderr, " old_style=%08x", req->old_style );
3141 fprintf( stderr, ", old_ex_style=%08x", req->old_ex_style );
3142 dump_uint64( ", old_instance=", &req->old_instance );
3143 dump_uint64( ", old_user_data=", &req->old_user_data );
3144 dump_uint64( ", old_extra_value=", &req->old_extra_value );
3145 fprintf( stderr, ", old_id=%08x", req->old_id );
3148 static void dump_set_parent_request( const struct set_parent_request *req )
3150 fprintf( stderr, " handle=%08x", req->handle );
3151 fprintf( stderr, ", parent=%08x", req->parent );
3154 static void dump_set_parent_reply( const struct set_parent_reply *req )
3156 fprintf( stderr, " old_parent=%08x", req->old_parent );
3157 fprintf( stderr, ", full_parent=%08x", req->full_parent );
3158 fprintf( stderr, ", dpi=%d", req->dpi );
3159 fprintf( stderr, ", awareness=%d", req->awareness );
3162 static void dump_get_window_parents_request( const struct get_window_parents_request *req )
3164 fprintf( stderr, " handle=%08x", req->handle );
3167 static void dump_get_window_parents_reply( const struct get_window_parents_reply *req )
3169 fprintf( stderr, " count=%d", req->count );
3170 dump_varargs_user_handles( ", parents=", cur_size );
3173 static void dump_get_window_children_request( const struct get_window_children_request *req )
3175 fprintf( stderr, " desktop=%04x", req->desktop );
3176 fprintf( stderr, ", parent=%08x", req->parent );
3177 fprintf( stderr, ", atom=%04x", req->atom );
3178 fprintf( stderr, ", tid=%04x", req->tid );
3179 dump_varargs_unicode_str( ", class=", cur_size );
3182 static void dump_get_window_children_reply( const struct get_window_children_reply *req )
3184 fprintf( stderr, " count=%d", req->count );
3185 dump_varargs_user_handles( ", children=", cur_size );
3188 static void dump_get_window_children_from_point_request( const struct get_window_children_from_point_request *req )
3190 fprintf( stderr, " parent=%08x", req->parent );
3191 fprintf( stderr, ", x=%d", req->x );
3192 fprintf( stderr, ", y=%d", req->y );
3193 fprintf( stderr, ", dpi=%d", req->dpi );
3196 static void dump_get_window_children_from_point_reply( const struct get_window_children_from_point_reply *req )
3198 fprintf( stderr, " count=%d", req->count );
3199 dump_varargs_user_handles( ", children=", cur_size );
3202 static void dump_get_window_tree_request( const struct get_window_tree_request *req )
3204 fprintf( stderr, " handle=%08x", req->handle );
3207 static void dump_get_window_tree_reply( const struct get_window_tree_reply *req )
3209 fprintf( stderr, " parent=%08x", req->parent );
3210 fprintf( stderr, ", owner=%08x", req->owner );
3211 fprintf( stderr, ", next_sibling=%08x", req->next_sibling );
3212 fprintf( stderr, ", prev_sibling=%08x", req->prev_sibling );
3213 fprintf( stderr, ", first_sibling=%08x", req->first_sibling );
3214 fprintf( stderr, ", last_sibling=%08x", req->last_sibling );
3215 fprintf( stderr, ", first_child=%08x", req->first_child );
3216 fprintf( stderr, ", last_child=%08x", req->last_child );
3219 static void dump_set_window_pos_request( const struct set_window_pos_request *req )
3221 fprintf( stderr, " swp_flags=%04x", req->swp_flags );
3222 fprintf( stderr, ", paint_flags=%04x", req->paint_flags );
3223 fprintf( stderr, ", handle=%08x", req->handle );
3224 fprintf( stderr, ", previous=%08x", req->previous );
3225 dump_rectangle( ", window=", &req->window );
3226 dump_rectangle( ", client=", &req->client );
3227 dump_varargs_rectangles( ", valid=", cur_size );
3230 static void dump_set_window_pos_reply( const struct set_window_pos_reply *req )
3232 fprintf( stderr, " new_style=%08x", req->new_style );
3233 fprintf( stderr, ", new_ex_style=%08x", req->new_ex_style );
3234 fprintf( stderr, ", surface_win=%08x", req->surface_win );
3235 fprintf( stderr, ", needs_update=%d", req->needs_update );
3238 static void dump_get_window_rectangles_request( const struct get_window_rectangles_request *req )
3240 fprintf( stderr, " handle=%08x", req->handle );
3241 fprintf( stderr, ", relative=%d", req->relative );
3242 fprintf( stderr, ", dpi=%d", req->dpi );
3245 static void dump_get_window_rectangles_reply( const struct get_window_rectangles_reply *req )
3247 dump_rectangle( " window=", &req->window );
3248 dump_rectangle( ", client=", &req->client );
3251 static void dump_get_window_text_request( const struct get_window_text_request *req )
3253 fprintf( stderr, " handle=%08x", req->handle );
3256 static void dump_get_window_text_reply( const struct get_window_text_reply *req )
3258 fprintf( stderr, " length=%u", req->length );
3259 dump_varargs_unicode_str( ", text=", cur_size );
3262 static void dump_set_window_text_request( const struct set_window_text_request *req )
3264 fprintf( stderr, " handle=%08x", req->handle );
3265 dump_varargs_unicode_str( ", text=", cur_size );
3268 static void dump_get_windows_offset_request( const struct get_windows_offset_request *req )
3270 fprintf( stderr, " from=%08x", req->from );
3271 fprintf( stderr, ", to=%08x", req->to );
3272 fprintf( stderr, ", dpi=%d", req->dpi );
3275 static void dump_get_windows_offset_reply( const struct get_windows_offset_reply *req )
3277 fprintf( stderr, " x=%d", req->x );
3278 fprintf( stderr, ", y=%d", req->y );
3279 fprintf( stderr, ", mirror=%d", req->mirror );
3282 static void dump_get_visible_region_request( const struct get_visible_region_request *req )
3284 fprintf( stderr, " window=%08x", req->window );
3285 fprintf( stderr, ", flags=%08x", req->flags );
3288 static void dump_get_visible_region_reply( const struct get_visible_region_reply *req )
3290 fprintf( stderr, " top_win=%08x", req->top_win );
3291 dump_rectangle( ", top_rect=", &req->top_rect );
3292 dump_rectangle( ", win_rect=", &req->win_rect );
3293 fprintf( stderr, ", paint_flags=%08x", req->paint_flags );
3294 fprintf( stderr, ", total_size=%u", req->total_size );
3295 dump_varargs_rectangles( ", region=", cur_size );
3298 static void dump_get_surface_region_request( const struct get_surface_region_request *req )
3300 fprintf( stderr, " window=%08x", req->window );
3303 static void dump_get_surface_region_reply( const struct get_surface_region_reply *req )
3305 dump_rectangle( " visible_rect=", &req->visible_rect );
3306 fprintf( stderr, ", total_size=%u", req->total_size );
3307 dump_varargs_rectangles( ", region=", cur_size );
3310 static void dump_get_window_region_request( const struct get_window_region_request *req )
3312 fprintf( stderr, " window=%08x", req->window );
3315 static void dump_get_window_region_reply( const struct get_window_region_reply *req )
3317 fprintf( stderr, " total_size=%u", req->total_size );
3318 dump_varargs_rectangles( ", region=", cur_size );
3321 static void dump_set_window_region_request( const struct set_window_region_request *req )
3323 fprintf( stderr, " window=%08x", req->window );
3324 fprintf( stderr, ", redraw=%d", req->redraw );
3325 dump_varargs_rectangles( ", region=", cur_size );
3328 static void dump_get_update_region_request( const struct get_update_region_request *req )
3330 fprintf( stderr, " window=%08x", req->window );
3331 fprintf( stderr, ", from_child=%08x", req->from_child );
3332 fprintf( stderr, ", flags=%08x", req->flags );
3335 static void dump_get_update_region_reply( const struct get_update_region_reply *req )
3337 fprintf( stderr, " child=%08x", req->child );
3338 fprintf( stderr, ", flags=%08x", req->flags );
3339 fprintf( stderr, ", total_size=%u", req->total_size );
3340 dump_varargs_rectangles( ", region=", cur_size );
3343 static void dump_update_window_zorder_request( const struct update_window_zorder_request *req )
3345 fprintf( stderr, " window=%08x", req->window );
3346 dump_rectangle( ", rect=", &req->rect );
3349 static void dump_redraw_window_request( const struct redraw_window_request *req )
3351 fprintf( stderr, " window=%08x", req->window );
3352 fprintf( stderr, ", flags=%08x", req->flags );
3353 dump_varargs_rectangles( ", region=", cur_size );
3356 static void dump_set_window_property_request( const struct set_window_property_request *req )
3358 fprintf( stderr, " window=%08x", req->window );
3359 dump_uint64( ", data=", &req->data );
3360 fprintf( stderr, ", atom=%04x", req->atom );
3361 dump_varargs_unicode_str( ", name=", cur_size );
3364 static void dump_remove_window_property_request( const struct remove_window_property_request *req )
3366 fprintf( stderr, " window=%08x", req->window );
3367 fprintf( stderr, ", atom=%04x", req->atom );
3368 dump_varargs_unicode_str( ", name=", cur_size );
3371 static void dump_remove_window_property_reply( const struct remove_window_property_reply *req )
3373 dump_uint64( " data=", &req->data );
3376 static void dump_get_window_property_request( const struct get_window_property_request *req )
3378 fprintf( stderr, " window=%08x", req->window );
3379 fprintf( stderr, ", atom=%04x", req->atom );
3380 dump_varargs_unicode_str( ", name=", cur_size );
3383 static void dump_get_window_property_reply( const struct get_window_property_reply *req )
3385 dump_uint64( " data=", &req->data );
3388 static void dump_get_window_properties_request( const struct get_window_properties_request *req )
3390 fprintf( stderr, " window=%08x", req->window );
3393 static void dump_get_window_properties_reply( const struct get_window_properties_reply *req )
3395 fprintf( stderr, " total=%d", req->total );
3396 dump_varargs_properties( ", props=", cur_size );
3399 static void dump_create_winstation_request( const struct create_winstation_request *req )
3401 fprintf( stderr, " flags=%08x", req->flags );
3402 fprintf( stderr, ", access=%08x", req->access );
3403 fprintf( stderr, ", attributes=%08x", req->attributes );
3404 fprintf( stderr, ", rootdir=%04x", req->rootdir );
3405 dump_varargs_unicode_str( ", name=", cur_size );
3408 static void dump_create_winstation_reply( const struct create_winstation_reply *req )
3410 fprintf( stderr, " handle=%04x", req->handle );
3413 static void dump_open_winstation_request( const struct open_winstation_request *req )
3415 fprintf( stderr, " access=%08x", req->access );
3416 fprintf( stderr, ", attributes=%08x", req->attributes );
3417 fprintf( stderr, ", rootdir=%04x", req->rootdir );
3418 dump_varargs_unicode_str( ", name=", cur_size );
3421 static void dump_open_winstation_reply( const struct open_winstation_reply *req )
3423 fprintf( stderr, " handle=%04x", req->handle );
3426 static void dump_close_winstation_request( const struct close_winstation_request *req )
3428 fprintf( stderr, " handle=%04x", req->handle );
3431 static void dump_get_process_winstation_request( const struct get_process_winstation_request *req )
3435 static void dump_get_process_winstation_reply( const struct get_process_winstation_reply *req )
3437 fprintf( stderr, " handle=%04x", req->handle );
3440 static void dump_set_process_winstation_request( const struct set_process_winstation_request *req )
3442 fprintf( stderr, " handle=%04x", req->handle );
3445 static void dump_enum_winstation_request( const struct enum_winstation_request *req )
3447 fprintf( stderr, " index=%08x", req->index );
3450 static void dump_enum_winstation_reply( const struct enum_winstation_reply *req )
3452 fprintf( stderr, " next=%08x", req->next );
3453 dump_varargs_unicode_str( ", name=", cur_size );
3456 static void dump_create_desktop_request( const struct create_desktop_request *req )
3458 fprintf( stderr, " flags=%08x", req->flags );
3459 fprintf( stderr, ", access=%08x", req->access );
3460 fprintf( stderr, ", attributes=%08x", req->attributes );
3461 dump_varargs_unicode_str( ", name=", cur_size );
3464 static void dump_create_desktop_reply( const struct create_desktop_reply *req )
3466 fprintf( stderr, " handle=%04x", req->handle );
3469 static void dump_open_desktop_request( const struct open_desktop_request *req )
3471 fprintf( stderr, " winsta=%04x", req->winsta );
3472 fprintf( stderr, ", flags=%08x", req->flags );
3473 fprintf( stderr, ", access=%08x", req->access );
3474 fprintf( stderr, ", attributes=%08x", req->attributes );
3475 dump_varargs_unicode_str( ", name=", cur_size );
3478 static void dump_open_desktop_reply( const struct open_desktop_reply *req )
3480 fprintf( stderr, " handle=%04x", req->handle );
3483 static void dump_open_input_desktop_request( const struct open_input_desktop_request *req )
3485 fprintf( stderr, " flags=%08x", req->flags );
3486 fprintf( stderr, ", access=%08x", req->access );
3487 fprintf( stderr, ", attributes=%08x", req->attributes );
3490 static void dump_open_input_desktop_reply( const struct open_input_desktop_reply *req )
3492 fprintf( stderr, " handle=%04x", req->handle );
3495 static void dump_close_desktop_request( const struct close_desktop_request *req )
3497 fprintf( stderr, " handle=%04x", req->handle );
3500 static void dump_get_thread_desktop_request( const struct get_thread_desktop_request *req )
3502 fprintf( stderr, " tid=%04x", req->tid );
3505 static void dump_get_thread_desktop_reply( const struct get_thread_desktop_reply *req )
3507 fprintf( stderr, " handle=%04x", req->handle );
3510 static void dump_set_thread_desktop_request( const struct set_thread_desktop_request *req )
3512 fprintf( stderr, " handle=%04x", req->handle );
3515 static void dump_enum_desktop_request( const struct enum_desktop_request *req )
3517 fprintf( stderr, " winstation=%04x", req->winstation );
3518 fprintf( stderr, ", index=%08x", req->index );
3521 static void dump_enum_desktop_reply( const struct enum_desktop_reply *req )
3523 fprintf( stderr, " next=%08x", req->next );
3524 dump_varargs_unicode_str( ", name=", cur_size );
3527 static void dump_set_user_object_info_request( const struct set_user_object_info_request *req )
3529 fprintf( stderr, " handle=%04x", req->handle );
3530 fprintf( stderr, ", flags=%08x", req->flags );
3531 fprintf( stderr, ", obj_flags=%08x", req->obj_flags );
3534 static void dump_set_user_object_info_reply( const struct set_user_object_info_reply *req )
3536 fprintf( stderr, " is_desktop=%d", req->is_desktop );
3537 fprintf( stderr, ", old_obj_flags=%08x", req->old_obj_flags );
3538 dump_varargs_unicode_str( ", name=", cur_size );
3541 static void dump_register_hotkey_request( const struct register_hotkey_request *req )
3543 fprintf( stderr, " window=%08x", req->window );
3544 fprintf( stderr, ", id=%d", req->id );
3545 fprintf( stderr, ", flags=%08x", req->flags );
3546 fprintf( stderr, ", vkey=%08x", req->vkey );
3549 static void dump_register_hotkey_reply( const struct register_hotkey_reply *req )
3551 fprintf( stderr, " replaced=%d", req->replaced );
3552 fprintf( stderr, ", flags=%08x", req->flags );
3553 fprintf( stderr, ", vkey=%08x", req->vkey );
3556 static void dump_unregister_hotkey_request( const struct unregister_hotkey_request *req )
3558 fprintf( stderr, " window=%08x", req->window );
3559 fprintf( stderr, ", id=%d", req->id );
3562 static void dump_unregister_hotkey_reply( const struct unregister_hotkey_reply *req )
3564 fprintf( stderr, " flags=%08x", req->flags );
3565 fprintf( stderr, ", vkey=%08x", req->vkey );
3568 static void dump_attach_thread_input_request( const struct attach_thread_input_request *req )
3570 fprintf( stderr, " tid_from=%04x", req->tid_from );
3571 fprintf( stderr, ", tid_to=%04x", req->tid_to );
3572 fprintf( stderr, ", attach=%d", req->attach );
3575 static void dump_get_thread_input_request( const struct get_thread_input_request *req )
3577 fprintf( stderr, " tid=%04x", req->tid );
3580 static void dump_get_thread_input_reply( const struct get_thread_input_reply *req )
3582 fprintf( stderr, " focus=%08x", req->focus );
3583 fprintf( stderr, ", capture=%08x", req->capture );
3584 fprintf( stderr, ", active=%08x", req->active );
3585 fprintf( stderr, ", foreground=%08x", req->foreground );
3586 fprintf( stderr, ", menu_owner=%08x", req->menu_owner );
3587 fprintf( stderr, ", move_size=%08x", req->move_size );
3588 fprintf( stderr, ", caret=%08x", req->caret );
3589 fprintf( stderr, ", cursor=%08x", req->cursor );
3590 fprintf( stderr, ", show_count=%d", req->show_count );
3591 dump_rectangle( ", rect=", &req->rect );
3594 static void dump_get_last_input_time_request( const struct get_last_input_time_request *req )
3598 static void dump_get_last_input_time_reply( const struct get_last_input_time_reply *req )
3600 fprintf( stderr, " time=%08x", req->time );
3603 static void dump_get_key_state_request( const struct get_key_state_request *req )
3605 fprintf( stderr, " tid=%04x", req->tid );
3606 fprintf( stderr, ", key=%d", req->key );
3609 static void dump_get_key_state_reply( const struct get_key_state_reply *req )
3611 fprintf( stderr, " state=%02x", req->state );
3612 dump_varargs_bytes( ", keystate=", cur_size );
3615 static void dump_set_key_state_request( const struct set_key_state_request *req )
3617 fprintf( stderr, " tid=%04x", req->tid );
3618 fprintf( stderr, ", async=%d", req->async );
3619 dump_varargs_bytes( ", keystate=", cur_size );
3622 static void dump_set_foreground_window_request( const struct set_foreground_window_request *req )
3624 fprintf( stderr, " handle=%08x", req->handle );
3627 static void dump_set_foreground_window_reply( const struct set_foreground_window_reply *req )
3629 fprintf( stderr, " previous=%08x", req->previous );
3630 fprintf( stderr, ", send_msg_old=%d", req->send_msg_old );
3631 fprintf( stderr, ", send_msg_new=%d", req->send_msg_new );
3634 static void dump_set_focus_window_request( const struct set_focus_window_request *req )
3636 fprintf( stderr, " handle=%08x", req->handle );
3639 static void dump_set_focus_window_reply( const struct set_focus_window_reply *req )
3641 fprintf( stderr, " previous=%08x", req->previous );
3644 static void dump_set_active_window_request( const struct set_active_window_request *req )
3646 fprintf( stderr, " handle=%08x", req->handle );
3649 static void dump_set_active_window_reply( const struct set_active_window_reply *req )
3651 fprintf( stderr, " previous=%08x", req->previous );
3654 static void dump_set_capture_window_request( const struct set_capture_window_request *req )
3656 fprintf( stderr, " handle=%08x", req->handle );
3657 fprintf( stderr, ", flags=%08x", req->flags );
3660 static void dump_set_capture_window_reply( const struct set_capture_window_reply *req )
3662 fprintf( stderr, " previous=%08x", req->previous );
3663 fprintf( stderr, ", full_handle=%08x", req->full_handle );
3666 static void dump_set_caret_window_request( const struct set_caret_window_request *req )
3668 fprintf( stderr, " handle=%08x", req->handle );
3669 fprintf( stderr, ", width=%d", req->width );
3670 fprintf( stderr, ", height=%d", req->height );
3673 static void dump_set_caret_window_reply( const struct set_caret_window_reply *req )
3675 fprintf( stderr, " previous=%08x", req->previous );
3676 dump_rectangle( ", old_rect=", &req->old_rect );
3677 fprintf( stderr, ", old_hide=%d", req->old_hide );
3678 fprintf( stderr, ", old_state=%d", req->old_state );
3681 static void dump_set_caret_info_request( const struct set_caret_info_request *req )
3683 fprintf( stderr, " flags=%08x", req->flags );
3684 fprintf( stderr, ", handle=%08x", req->handle );
3685 fprintf( stderr, ", x=%d", req->x );
3686 fprintf( stderr, ", y=%d", req->y );
3687 fprintf( stderr, ", hide=%d", req->hide );
3688 fprintf( stderr, ", state=%d", req->state );
3691 static void dump_set_caret_info_reply( const struct set_caret_info_reply *req )
3693 fprintf( stderr, " full_handle=%08x", req->full_handle );
3694 dump_rectangle( ", old_rect=", &req->old_rect );
3695 fprintf( stderr, ", old_hide=%d", req->old_hide );
3696 fprintf( stderr, ", old_state=%d", req->old_state );
3699 static void dump_set_hook_request( const struct set_hook_request *req )
3701 fprintf( stderr, " id=%d", req->id );
3702 fprintf( stderr, ", pid=%04x", req->pid );
3703 fprintf( stderr, ", tid=%04x", req->tid );
3704 fprintf( stderr, ", event_min=%d", req->event_min );
3705 fprintf( stderr, ", event_max=%d", req->event_max );
3706 dump_uint64( ", proc=", &req->proc );
3707 fprintf( stderr, ", flags=%d", req->flags );
3708 fprintf( stderr, ", unicode=%d", req->unicode );
3709 dump_varargs_unicode_str( ", module=", cur_size );
3712 static void dump_set_hook_reply( const struct set_hook_reply *req )
3714 fprintf( stderr, " handle=%08x", req->handle );
3715 fprintf( stderr, ", active_hooks=%08x", req->active_hooks );
3718 static void dump_remove_hook_request( const struct remove_hook_request *req )
3720 fprintf( stderr, " handle=%08x", req->handle );
3721 dump_uint64( ", proc=", &req->proc );
3722 fprintf( stderr, ", id=%d", req->id );
3725 static void dump_remove_hook_reply( const struct remove_hook_reply *req )
3727 fprintf( stderr, " active_hooks=%08x", req->active_hooks );
3730 static void dump_start_hook_chain_request( const struct start_hook_chain_request *req )
3732 fprintf( stderr, " id=%d", req->id );
3733 fprintf( stderr, ", event=%d", req->event );
3734 fprintf( stderr, ", window=%08x", req->window );
3735 fprintf( stderr, ", object_id=%d", req->object_id );
3736 fprintf( stderr, ", child_id=%d", req->child_id );
3739 static void dump_start_hook_chain_reply( const struct start_hook_chain_reply *req )
3741 fprintf( stderr, " handle=%08x", req->handle );
3742 fprintf( stderr, ", pid=%04x", req->pid );
3743 fprintf( stderr, ", tid=%04x", req->tid );
3744 fprintf( stderr, ", unicode=%d", req->unicode );
3745 dump_uint64( ", proc=", &req->proc );
3746 fprintf( stderr, ", active_hooks=%08x", req->active_hooks );
3747 dump_varargs_unicode_str( ", module=", cur_size );
3750 static void dump_finish_hook_chain_request( const struct finish_hook_chain_request *req )
3752 fprintf( stderr, " id=%d", req->id );
3755 static void dump_get_hook_info_request( const struct get_hook_info_request *req )
3757 fprintf( stderr, " handle=%08x", req->handle );
3758 fprintf( stderr, ", get_next=%d", req->get_next );
3759 fprintf( stderr, ", event=%d", req->event );
3760 fprintf( stderr, ", window=%08x", req->window );
3761 fprintf( stderr, ", object_id=%d", req->object_id );
3762 fprintf( stderr, ", child_id=%d", req->child_id );
3765 static void dump_get_hook_info_reply( const struct get_hook_info_reply *req )
3767 fprintf( stderr, " handle=%08x", req->handle );
3768 fprintf( stderr, ", id=%d", req->id );
3769 fprintf( stderr, ", pid=%04x", req->pid );
3770 fprintf( stderr, ", tid=%04x", req->tid );
3771 dump_uint64( ", proc=", &req->proc );
3772 fprintf( stderr, ", unicode=%d", req->unicode );
3773 dump_varargs_unicode_str( ", module=", cur_size );
3776 static void dump_create_class_request( const struct create_class_request *req )
3778 fprintf( stderr, " local=%d", req->local );
3779 fprintf( stderr, ", atom=%04x", req->atom );
3780 fprintf( stderr, ", style=%08x", req->style );
3781 dump_uint64( ", instance=", &req->instance );
3782 fprintf( stderr, ", extra=%d", req->extra );
3783 fprintf( stderr, ", win_extra=%d", req->win_extra );
3784 dump_uint64( ", client_ptr=", &req->client_ptr );
3785 fprintf( stderr, ", name_offset=%u", req->name_offset );
3786 dump_varargs_unicode_str( ", name=", cur_size );
3789 static void dump_create_class_reply( const struct create_class_reply *req )
3791 fprintf( stderr, " atom=%04x", req->atom );
3794 static void dump_destroy_class_request( const struct destroy_class_request *req )
3796 fprintf( stderr, " atom=%04x", req->atom );
3797 dump_uint64( ", instance=", &req->instance );
3798 dump_varargs_unicode_str( ", name=", cur_size );
3801 static void dump_destroy_class_reply( const struct destroy_class_reply *req )
3803 dump_uint64( " client_ptr=", &req->client_ptr );
3806 static void dump_set_class_info_request( const struct set_class_info_request *req )
3808 fprintf( stderr, " window=%08x", req->window );
3809 fprintf( stderr, ", flags=%08x", req->flags );
3810 fprintf( stderr, ", atom=%04x", req->atom );
3811 fprintf( stderr, ", style=%08x", req->style );
3812 fprintf( stderr, ", win_extra=%d", req->win_extra );
3813 dump_uint64( ", instance=", &req->instance );
3814 fprintf( stderr, ", extra_offset=%d", req->extra_offset );
3815 fprintf( stderr, ", extra_size=%u", req->extra_size );
3816 dump_uint64( ", extra_value=", &req->extra_value );
3819 static void dump_set_class_info_reply( const struct set_class_info_reply *req )
3821 fprintf( stderr, " old_atom=%04x", req->old_atom );
3822 fprintf( stderr, ", base_atom=%04x", req->base_atom );
3823 dump_uint64( ", old_instance=", &req->old_instance );
3824 dump_uint64( ", old_extra_value=", &req->old_extra_value );
3825 fprintf( stderr, ", old_style=%08x", req->old_style );
3826 fprintf( stderr, ", old_extra=%d", req->old_extra );
3827 fprintf( stderr, ", old_win_extra=%d", req->old_win_extra );
3830 static void dump_open_clipboard_request( const struct open_clipboard_request *req )
3832 fprintf( stderr, " window=%08x", req->window );
3835 static void dump_open_clipboard_reply( const struct open_clipboard_reply *req )
3837 fprintf( stderr, " owner=%08x", req->owner );
3840 static void dump_close_clipboard_request( const struct close_clipboard_request *req )
3844 static void dump_close_clipboard_reply( const struct close_clipboard_reply *req )
3846 fprintf( stderr, " viewer=%08x", req->viewer );
3847 fprintf( stderr, ", owner=%08x", req->owner );
3850 static void dump_empty_clipboard_request( const struct empty_clipboard_request *req )
3854 static void dump_set_clipboard_data_request( const struct set_clipboard_data_request *req )
3856 fprintf( stderr, " format=%08x", req->format );
3857 fprintf( stderr, ", lcid=%08x", req->lcid );
3858 dump_varargs_bytes( ", data=", cur_size );
3861 static void dump_set_clipboard_data_reply( const struct set_clipboard_data_reply *req )
3863 fprintf( stderr, " seqno=%08x", req->seqno );
3866 static void dump_get_clipboard_data_request( const struct get_clipboard_data_request *req )
3868 fprintf( stderr, " format=%08x", req->format );
3869 fprintf( stderr, ", render=%d", req->render );
3870 fprintf( stderr, ", cached=%d", req->cached );
3871 fprintf( stderr, ", seqno=%08x", req->seqno );
3874 static void dump_get_clipboard_data_reply( const struct get_clipboard_data_reply *req )
3876 fprintf( stderr, " from=%08x", req->from );
3877 fprintf( stderr, ", owner=%08x", req->owner );
3878 fprintf( stderr, ", seqno=%08x", req->seqno );
3879 fprintf( stderr, ", total=%u", req->total );
3880 dump_varargs_bytes( ", data=", cur_size );
3883 static void dump_get_clipboard_formats_request( const struct get_clipboard_formats_request *req )
3885 fprintf( stderr, " format=%08x", req->format );
3888 static void dump_get_clipboard_formats_reply( const struct get_clipboard_formats_reply *req )
3890 fprintf( stderr, " count=%08x", req->count );
3891 dump_varargs_uints( ", formats=", cur_size );
3894 static void dump_enum_clipboard_formats_request( const struct enum_clipboard_formats_request *req )
3896 fprintf( stderr, " previous=%08x", req->previous );
3899 static void dump_enum_clipboard_formats_reply( const struct enum_clipboard_formats_reply *req )
3901 fprintf( stderr, " format=%08x", req->format );
3904 static void dump_release_clipboard_request( const struct release_clipboard_request *req )
3906 fprintf( stderr, " owner=%08x", req->owner );
3909 static void dump_release_clipboard_reply( const struct release_clipboard_reply *req )
3911 fprintf( stderr, " viewer=%08x", req->viewer );
3912 fprintf( stderr, ", owner=%08x", req->owner );
3915 static void dump_get_clipboard_info_request( const struct get_clipboard_info_request *req )
3919 static void dump_get_clipboard_info_reply( const struct get_clipboard_info_reply *req )
3921 fprintf( stderr, " window=%08x", req->window );
3922 fprintf( stderr, ", owner=%08x", req->owner );
3923 fprintf( stderr, ", viewer=%08x", req->viewer );
3924 fprintf( stderr, ", seqno=%08x", req->seqno );
3927 static void dump_set_clipboard_viewer_request( const struct set_clipboard_viewer_request *req )
3929 fprintf( stderr, " viewer=%08x", req->viewer );
3930 fprintf( stderr, ", previous=%08x", req->previous );
3933 static void dump_set_clipboard_viewer_reply( const struct set_clipboard_viewer_reply *req )
3935 fprintf( stderr, " old_viewer=%08x", req->old_viewer );
3936 fprintf( stderr, ", owner=%08x", req->owner );
3939 static void dump_add_clipboard_listener_request( const struct add_clipboard_listener_request *req )
3941 fprintf( stderr, " window=%08x", req->window );
3944 static void dump_remove_clipboard_listener_request( const struct remove_clipboard_listener_request *req )
3946 fprintf( stderr, " window=%08x", req->window );
3949 static void dump_open_token_request( const struct open_token_request *req )
3951 fprintf( stderr, " handle=%04x", req->handle );
3952 fprintf( stderr, ", access=%08x", req->access );
3953 fprintf( stderr, ", attributes=%08x", req->attributes );
3954 fprintf( stderr, ", flags=%08x", req->flags );
3957 static void dump_open_token_reply( const struct open_token_reply *req )
3959 fprintf( stderr, " token=%04x", req->token );
3962 static void dump_set_global_windows_request( const struct set_global_windows_request *req )
3964 fprintf( stderr, " flags=%08x", req->flags );
3965 fprintf( stderr, ", shell_window=%08x", req->shell_window );
3966 fprintf( stderr, ", shell_listview=%08x", req->shell_listview );
3967 fprintf( stderr, ", progman_window=%08x", req->progman_window );
3968 fprintf( stderr, ", taskman_window=%08x", req->taskman_window );
3971 static void dump_set_global_windows_reply( const struct set_global_windows_reply *req )
3973 fprintf( stderr, " old_shell_window=%08x", req->old_shell_window );
3974 fprintf( stderr, ", old_shell_listview=%08x", req->old_shell_listview );
3975 fprintf( stderr, ", old_progman_window=%08x", req->old_progman_window );
3976 fprintf( stderr, ", old_taskman_window=%08x", req->old_taskman_window );
3979 static void dump_adjust_token_privileges_request( const struct adjust_token_privileges_request *req )
3981 fprintf( stderr, " handle=%04x", req->handle );
3982 fprintf( stderr, ", disable_all=%d", req->disable_all );
3983 fprintf( stderr, ", get_modified_state=%d", req->get_modified_state );
3984 dump_varargs_LUID_AND_ATTRIBUTES( ", privileges=", cur_size );
3987 static void dump_adjust_token_privileges_reply( const struct adjust_token_privileges_reply *req )
3989 fprintf( stderr, " len=%08x", req->len );
3990 dump_varargs_LUID_AND_ATTRIBUTES( ", privileges=", cur_size );
3993 static void dump_get_token_privileges_request( const struct get_token_privileges_request *req )
3995 fprintf( stderr, " handle=%04x", req->handle );
3998 static void dump_get_token_privileges_reply( const struct get_token_privileges_reply *req )
4000 fprintf( stderr, " len=%08x", req->len );
4001 dump_varargs_LUID_AND_ATTRIBUTES( ", privileges=", cur_size );
4004 static void dump_check_token_privileges_request( const struct check_token_privileges_request *req )
4006 fprintf( stderr, " handle=%04x", req->handle );
4007 fprintf( stderr, ", all_required=%d", req->all_required );
4008 dump_varargs_LUID_AND_ATTRIBUTES( ", privileges=", cur_size );
4011 static void dump_check_token_privileges_reply( const struct check_token_privileges_reply *req )
4013 fprintf( stderr, " has_privileges=%d", req->has_privileges );
4014 dump_varargs_LUID_AND_ATTRIBUTES( ", privileges=", cur_size );
4017 static void dump_duplicate_token_request( const struct duplicate_token_request *req )
4019 fprintf( stderr, " handle=%04x", req->handle );
4020 fprintf( stderr, ", access=%08x", req->access );
4021 fprintf( stderr, ", primary=%d", req->primary );
4022 fprintf( stderr, ", impersonation_level=%d", req->impersonation_level );
4023 dump_varargs_object_attributes( ", objattr=", cur_size );
4026 static void dump_duplicate_token_reply( const struct duplicate_token_reply *req )
4028 fprintf( stderr, " new_handle=%04x", req->new_handle );
4031 static void dump_access_check_request( const struct access_check_request *req )
4033 fprintf( stderr, " handle=%04x", req->handle );
4034 fprintf( stderr, ", desired_access=%08x", req->desired_access );
4035 fprintf( stderr, ", mapping_read=%08x", req->mapping_read );
4036 fprintf( stderr, ", mapping_write=%08x", req->mapping_write );
4037 fprintf( stderr, ", mapping_execute=%08x", req->mapping_execute );
4038 fprintf( stderr, ", mapping_all=%08x", req->mapping_all );
4039 dump_varargs_security_descriptor( ", sd=", cur_size );
4042 static void dump_access_check_reply( const struct access_check_reply *req )
4044 fprintf( stderr, " access_granted=%08x", req->access_granted );
4045 fprintf( stderr, ", access_status=%08x", req->access_status );
4046 fprintf( stderr, ", privileges_len=%08x", req->privileges_len );
4047 dump_varargs_LUID_AND_ATTRIBUTES( ", privileges=", cur_size );
4050 static void dump_get_token_sid_request( const struct get_token_sid_request *req )
4052 fprintf( stderr, " handle=%04x", req->handle );
4053 fprintf( stderr, ", which_sid=%08x", req->which_sid );
4056 static void dump_get_token_sid_reply( const struct get_token_sid_reply *req )
4058 fprintf( stderr, " sid_len=%u", req->sid_len );
4059 dump_varargs_SID( ", sid=", cur_size );
4062 static void dump_get_token_groups_request( const struct get_token_groups_request *req )
4064 fprintf( stderr, " handle=%04x", req->handle );
4067 static void dump_get_token_groups_reply( const struct get_token_groups_reply *req )
4069 fprintf( stderr, " user_len=%u", req->user_len );
4070 dump_varargs_token_groups( ", user=", cur_size );
4073 static void dump_get_token_default_dacl_request( const struct get_token_default_dacl_request *req )
4075 fprintf( stderr, " handle=%04x", req->handle );
4078 static void dump_get_token_default_dacl_reply( const struct get_token_default_dacl_reply *req )
4080 fprintf( stderr, " acl_len=%u", req->acl_len );
4081 dump_varargs_ACL( ", acl=", cur_size );
4084 static void dump_set_token_default_dacl_request( const struct set_token_default_dacl_request *req )
4086 fprintf( stderr, " handle=%04x", req->handle );
4087 dump_varargs_ACL( ", acl=", cur_size );
4090 static void dump_set_security_object_request( const struct set_security_object_request *req )
4092 fprintf( stderr, " handle=%04x", req->handle );
4093 fprintf( stderr, ", security_info=%08x", req->security_info );
4094 dump_varargs_security_descriptor( ", sd=", cur_size );
4097 static void dump_get_security_object_request( const struct get_security_object_request *req )
4099 fprintf( stderr, " handle=%04x", req->handle );
4100 fprintf( stderr, ", security_info=%08x", req->security_info );
4103 static void dump_get_security_object_reply( const struct get_security_object_reply *req )
4105 fprintf( stderr, " sd_len=%08x", req->sd_len );
4106 dump_varargs_security_descriptor( ", sd=", cur_size );
4109 static void dump_get_system_handles_request( const struct get_system_handles_request *req )
4113 static void dump_get_system_handles_reply( const struct get_system_handles_reply *req )
4115 fprintf( stderr, " count=%08x", req->count );
4116 dump_varargs_handle_infos( ", data=", cur_size );
4119 static void dump_create_mailslot_request( const struct create_mailslot_request *req )
4121 fprintf( stderr, " access=%08x", req->access );
4122 dump_timeout( ", read_timeout=", &req->read_timeout );
4123 fprintf( stderr, ", max_msgsize=%08x", req->max_msgsize );
4124 dump_varargs_object_attributes( ", objattr=", cur_size );
4127 static void dump_create_mailslot_reply( const struct create_mailslot_reply *req )
4129 fprintf( stderr, " handle=%04x", req->handle );
4132 static void dump_set_mailslot_info_request( const struct set_mailslot_info_request *req )
4134 fprintf( stderr, " handle=%04x", req->handle );
4135 dump_timeout( ", read_timeout=", &req->read_timeout );
4136 fprintf( stderr, ", flags=%08x", req->flags );
4139 static void dump_set_mailslot_info_reply( const struct set_mailslot_info_reply *req )
4141 dump_timeout( " read_timeout=", &req->read_timeout );
4142 fprintf( stderr, ", max_msgsize=%08x", req->max_msgsize );
4145 static void dump_create_directory_request( const struct create_directory_request *req )
4147 fprintf( stderr, " access=%08x", req->access );
4148 dump_varargs_object_attributes( ", objattr=", cur_size );
4151 static void dump_create_directory_reply( const struct create_directory_reply *req )
4153 fprintf( stderr, " handle=%04x", req->handle );
4156 static void dump_open_directory_request( const struct open_directory_request *req )
4158 fprintf( stderr, " access=%08x", req->access );
4159 fprintf( stderr, ", attributes=%08x", req->attributes );
4160 fprintf( stderr, ", rootdir=%04x", req->rootdir );
4161 dump_varargs_unicode_str( ", directory_name=", cur_size );
4164 static void dump_open_directory_reply( const struct open_directory_reply *req )
4166 fprintf( stderr, " handle=%04x", req->handle );
4169 static void dump_get_directory_entry_request( const struct get_directory_entry_request *req )
4171 fprintf( stderr, " handle=%04x", req->handle );
4172 fprintf( stderr, ", index=%08x", req->index );
4175 static void dump_get_directory_entry_reply( const struct get_directory_entry_reply *req )
4177 fprintf( stderr, " name_len=%u", req->name_len );
4178 dump_varargs_unicode_str( ", name=", min(cur_size,req->name_len) );
4179 dump_varargs_unicode_str( ", type=", cur_size );
4182 static void dump_create_symlink_request( const struct create_symlink_request *req )
4184 fprintf( stderr, " access=%08x", req->access );
4185 dump_varargs_object_attributes( ", objattr=", cur_size );
4186 dump_varargs_unicode_str( ", target_name=", cur_size );
4189 static void dump_create_symlink_reply( const struct create_symlink_reply *req )
4191 fprintf( stderr, " handle=%04x", req->handle );
4194 static void dump_open_symlink_request( const struct open_symlink_request *req )
4196 fprintf( stderr, " access=%08x", req->access );
4197 fprintf( stderr, ", attributes=%08x", req->attributes );
4198 fprintf( stderr, ", rootdir=%04x", req->rootdir );
4199 dump_varargs_unicode_str( ", name=", cur_size );
4202 static void dump_open_symlink_reply( const struct open_symlink_reply *req )
4204 fprintf( stderr, " handle=%04x", req->handle );
4207 static void dump_query_symlink_request( const struct query_symlink_request *req )
4209 fprintf( stderr, " handle=%04x", req->handle );
4212 static void dump_query_symlink_reply( const struct query_symlink_reply *req )
4214 fprintf( stderr, " total=%u", req->total );
4215 dump_varargs_unicode_str( ", target_name=", cur_size );
4218 static void dump_get_object_info_request( const struct get_object_info_request *req )
4220 fprintf( stderr, " handle=%04x", req->handle );
4223 static void dump_get_object_info_reply( const struct get_object_info_reply *req )
4225 fprintf( stderr, " access=%08x", req->access );
4226 fprintf( stderr, ", ref_count=%08x", req->ref_count );
4227 fprintf( stderr, ", handle_count=%08x", req->handle_count );
4228 fprintf( stderr, ", total=%u", req->total );
4229 dump_varargs_unicode_str( ", name=", cur_size );
4232 static void dump_get_object_type_request( const struct get_object_type_request *req )
4234 fprintf( stderr, " handle=%04x", req->handle );
4237 static void dump_get_object_type_reply( const struct get_object_type_reply *req )
4239 fprintf( stderr, " total=%u", req->total );
4240 dump_varargs_unicode_str( ", type=", cur_size );
4243 static void dump_unlink_object_request( const struct unlink_object_request *req )
4245 fprintf( stderr, " handle=%04x", req->handle );
4248 static void dump_get_token_impersonation_level_request( const struct get_token_impersonation_level_request *req )
4250 fprintf( stderr, " handle=%04x", req->handle );
4253 static void dump_get_token_impersonation_level_reply( const struct get_token_impersonation_level_reply *req )
4255 fprintf( stderr, " impersonation_level=%d", req->impersonation_level );
4258 static void dump_allocate_locally_unique_id_request( const struct allocate_locally_unique_id_request *req )
4262 static void dump_allocate_locally_unique_id_reply( const struct allocate_locally_unique_id_reply *req )
4264 dump_luid( " luid=", &req->luid );
4267 static void dump_create_device_manager_request( const struct create_device_manager_request *req )
4269 fprintf( stderr, " access=%08x", req->access );
4270 fprintf( stderr, ", attributes=%08x", req->attributes );
4273 static void dump_create_device_manager_reply( const struct create_device_manager_reply *req )
4275 fprintf( stderr, " handle=%04x", req->handle );
4278 static void dump_create_device_request( const struct create_device_request *req )
4280 fprintf( stderr, " rootdir=%04x", req->rootdir );
4281 dump_uint64( ", user_ptr=", &req->user_ptr );
4282 fprintf( stderr, ", manager=%04x", req->manager );
4283 dump_varargs_unicode_str( ", name=", cur_size );
4286 static void dump_delete_device_request( const struct delete_device_request *req )
4288 fprintf( stderr, " manager=%04x", req->manager );
4289 dump_uint64( ", device=", &req->device );
4292 static void dump_get_next_device_request_request( const struct get_next_device_request_request *req )
4294 fprintf( stderr, " manager=%04x", req->manager );
4295 fprintf( stderr, ", prev=%04x", req->prev );
4296 fprintf( stderr, ", status=%08x", req->status );
4297 dump_uint64( ", user_ptr=", &req->user_ptr );
4300 static void dump_get_next_device_request_reply( const struct get_next_device_request_reply *req )
4302 dump_irp_params( " params=", &req->params );
4303 fprintf( stderr, ", next=%04x", req->next );
4304 fprintf( stderr, ", client_tid=%04x", req->client_tid );
4305 dump_uint64( ", client_thread=", &req->client_thread );
4306 fprintf( stderr, ", in_size=%u", req->in_size );
4307 dump_varargs_bytes( ", next_data=", cur_size );
4310 static void dump_get_kernel_object_ptr_request( const struct get_kernel_object_ptr_request *req )
4312 fprintf( stderr, " manager=%04x", req->manager );
4313 fprintf( stderr, ", handle=%04x", req->handle );
4316 static void dump_get_kernel_object_ptr_reply( const struct get_kernel_object_ptr_reply *req )
4318 dump_uint64( " user_ptr=", &req->user_ptr );
4321 static void dump_set_kernel_object_ptr_request( const struct set_kernel_object_ptr_request *req )
4323 fprintf( stderr, " manager=%04x", req->manager );
4324 fprintf( stderr, ", handle=%04x", req->handle );
4325 dump_uint64( ", user_ptr=", &req->user_ptr );
4328 static void dump_grab_kernel_object_request( const struct grab_kernel_object_request *req )
4330 fprintf( stderr, " manager=%04x", req->manager );
4331 dump_uint64( ", user_ptr=", &req->user_ptr );
4334 static void dump_release_kernel_object_request( const struct release_kernel_object_request *req )
4336 fprintf( stderr, " manager=%04x", req->manager );
4337 dump_uint64( ", user_ptr=", &req->user_ptr );
4340 static void dump_get_kernel_object_handle_request( const struct get_kernel_object_handle_request *req )
4342 fprintf( stderr, " manager=%04x", req->manager );
4343 dump_uint64( ", user_ptr=", &req->user_ptr );
4344 fprintf( stderr, ", access=%08x", req->access );
4347 static void dump_get_kernel_object_handle_reply( const struct get_kernel_object_handle_reply *req )
4349 fprintf( stderr, " handle=%04x", req->handle );
4352 static void dump_make_process_system_request( const struct make_process_system_request *req )
4356 static void dump_make_process_system_reply( const struct make_process_system_reply *req )
4358 fprintf( stderr, " event=%04x", req->event );
4361 static void dump_get_token_statistics_request( const struct get_token_statistics_request *req )
4363 fprintf( stderr, " handle=%04x", req->handle );
4366 static void dump_get_token_statistics_reply( const struct get_token_statistics_reply *req )
4368 dump_luid( " token_id=", &req->token_id );
4369 dump_luid( ", modified_id=", &req->modified_id );
4370 fprintf( stderr, ", primary=%d", req->primary );
4371 fprintf( stderr, ", impersonation_level=%d", req->impersonation_level );
4372 fprintf( stderr, ", group_count=%d", req->group_count );
4373 fprintf( stderr, ", privilege_count=%d", req->privilege_count );
4376 static void dump_create_completion_request( const struct create_completion_request *req )
4378 fprintf( stderr, " access=%08x", req->access );
4379 fprintf( stderr, ", concurrent=%08x", req->concurrent );
4380 dump_varargs_object_attributes( ", objattr=", cur_size );
4383 static void dump_create_completion_reply( const struct create_completion_reply *req )
4385 fprintf( stderr, " handle=%04x", req->handle );
4388 static void dump_open_completion_request( const struct open_completion_request *req )
4390 fprintf( stderr, " access=%08x", req->access );
4391 fprintf( stderr, ", attributes=%08x", req->attributes );
4392 fprintf( stderr, ", rootdir=%04x", req->rootdir );
4393 dump_varargs_unicode_str( ", filename=", cur_size );
4396 static void dump_open_completion_reply( const struct open_completion_reply *req )
4398 fprintf( stderr, " handle=%04x", req->handle );
4401 static void dump_add_completion_request( const struct add_completion_request *req )
4403 fprintf( stderr, " handle=%04x", req->handle );
4404 dump_uint64( ", ckey=", &req->ckey );
4405 dump_uint64( ", cvalue=", &req->cvalue );
4406 dump_uint64( ", information=", &req->information );
4407 fprintf( stderr, ", status=%08x", req->status );
4410 static void dump_remove_completion_request( const struct remove_completion_request *req )
4412 fprintf( stderr, " handle=%04x", req->handle );
4415 static void dump_remove_completion_reply( const struct remove_completion_reply *req )
4417 dump_uint64( " ckey=", &req->ckey );
4418 dump_uint64( ", cvalue=", &req->cvalue );
4419 dump_uint64( ", information=", &req->information );
4420 fprintf( stderr, ", status=%08x", req->status );
4423 static void dump_query_completion_request( const struct query_completion_request *req )
4425 fprintf( stderr, " handle=%04x", req->handle );
4428 static void dump_query_completion_reply( const struct query_completion_reply *req )
4430 fprintf( stderr, " depth=%08x", req->depth );
4433 static void dump_set_completion_info_request( const struct set_completion_info_request *req )
4435 fprintf( stderr, " handle=%04x", req->handle );
4436 dump_uint64( ", ckey=", &req->ckey );
4437 fprintf( stderr, ", chandle=%04x", req->chandle );
4440 static void dump_add_fd_completion_request( const struct add_fd_completion_request *req )
4442 fprintf( stderr, " handle=%04x", req->handle );
4443 dump_uint64( ", cvalue=", &req->cvalue );
4444 dump_uint64( ", information=", &req->information );
4445 fprintf( stderr, ", status=%08x", req->status );
4446 fprintf( stderr, ", async=%d", req->async );
4449 static void dump_set_fd_completion_mode_request( const struct set_fd_completion_mode_request *req )
4451 fprintf( stderr, " handle=%04x", req->handle );
4452 fprintf( stderr, ", flags=%08x", req->flags );
4455 static void dump_set_fd_disp_info_request( const struct set_fd_disp_info_request *req )
4457 fprintf( stderr, " handle=%04x", req->handle );
4458 fprintf( stderr, ", unlink=%d", req->unlink );
4461 static void dump_set_fd_name_info_request( const struct set_fd_name_info_request *req )
4463 fprintf( stderr, " handle=%04x", req->handle );
4464 fprintf( stderr, ", rootdir=%04x", req->rootdir );
4465 fprintf( stderr, ", link=%d", req->link );
4466 fprintf( stderr, ", replace=%d", req->replace );
4467 dump_varargs_string( ", filename=", cur_size );
4470 static void dump_get_window_layered_info_request( const struct get_window_layered_info_request *req )
4472 fprintf( stderr, " handle=%08x", req->handle );
4475 static void dump_get_window_layered_info_reply( const struct get_window_layered_info_reply *req )
4477 fprintf( stderr, " color_key=%08x", req->color_key );
4478 fprintf( stderr, ", alpha=%08x", req->alpha );
4479 fprintf( stderr, ", flags=%08x", req->flags );
4482 static void dump_set_window_layered_info_request( const struct set_window_layered_info_request *req )
4484 fprintf( stderr, " handle=%08x", req->handle );
4485 fprintf( stderr, ", color_key=%08x", req->color_key );
4486 fprintf( stderr, ", alpha=%08x", req->alpha );
4487 fprintf( stderr, ", flags=%08x", req->flags );
4490 static void dump_alloc_user_handle_request( const struct alloc_user_handle_request *req )
4494 static void dump_alloc_user_handle_reply( const struct alloc_user_handle_reply *req )
4496 fprintf( stderr, " handle=%08x", req->handle );
4499 static void dump_free_user_handle_request( const struct free_user_handle_request *req )
4501 fprintf( stderr, " handle=%08x", req->handle );
4504 static void dump_set_cursor_request( const struct set_cursor_request *req )
4506 fprintf( stderr, " flags=%08x", req->flags );
4507 fprintf( stderr, ", handle=%08x", req->handle );
4508 fprintf( stderr, ", show_count=%d", req->show_count );
4509 fprintf( stderr, ", x=%d", req->x );
4510 fprintf( stderr, ", y=%d", req->y );
4511 dump_rectangle( ", clip=", &req->clip );
4512 fprintf( stderr, ", clip_msg=%08x", req->clip_msg );
4515 static void dump_set_cursor_reply( const struct set_cursor_reply *req )
4517 fprintf( stderr, " prev_handle=%08x", req->prev_handle );
4518 fprintf( stderr, ", prev_count=%d", req->prev_count );
4519 fprintf( stderr, ", prev_x=%d", req->prev_x );
4520 fprintf( stderr, ", prev_y=%d", req->prev_y );
4521 fprintf( stderr, ", new_x=%d", req->new_x );
4522 fprintf( stderr, ", new_y=%d", req->new_y );
4523 dump_rectangle( ", new_clip=", &req->new_clip );
4524 fprintf( stderr, ", last_change=%08x", req->last_change );
4527 static void dump_update_rawinput_devices_request( const struct update_rawinput_devices_request *req )
4529 dump_varargs_rawinput_devices( " devices=", cur_size );
4532 static void dump_create_job_request( const struct create_job_request *req )
4534 fprintf( stderr, " access=%08x", req->access );
4535 dump_varargs_object_attributes( ", objattr=", cur_size );
4538 static void dump_create_job_reply( const struct create_job_reply *req )
4540 fprintf( stderr, " handle=%04x", req->handle );
4543 static void dump_open_job_request( const struct open_job_request *req )
4545 fprintf( stderr, " access=%08x", req->access );
4546 fprintf( stderr, ", attributes=%08x", req->attributes );
4547 fprintf( stderr, ", rootdir=%04x", req->rootdir );
4548 dump_varargs_unicode_str( ", name=", cur_size );
4551 static void dump_open_job_reply( const struct open_job_reply *req )
4553 fprintf( stderr, " handle=%04x", req->handle );
4556 static void dump_assign_job_request( const struct assign_job_request *req )
4558 fprintf( stderr, " job=%04x", req->job );
4559 fprintf( stderr, ", process=%04x", req->process );
4562 static void dump_process_in_job_request( const struct process_in_job_request *req )
4564 fprintf( stderr, " job=%04x", req->job );
4565 fprintf( stderr, ", process=%04x", req->process );
4568 static void dump_set_job_limits_request( const struct set_job_limits_request *req )
4570 fprintf( stderr, " handle=%04x", req->handle );
4571 fprintf( stderr, ", limit_flags=%08x", req->limit_flags );
4574 static void dump_set_job_completion_port_request( const struct set_job_completion_port_request *req )
4576 fprintf( stderr, " job=%04x", req->job );
4577 fprintf( stderr, ", port=%04x", req->port );
4578 dump_uint64( ", key=", &req->key );
4581 static void dump_terminate_job_request( const struct terminate_job_request *req )
4583 fprintf( stderr, " handle=%04x", req->handle );
4584 fprintf( stderr, ", status=%d", req->status );
4587 static void dump_suspend_process_request( const struct suspend_process_request *req )
4589 fprintf( stderr, " handle=%04x", req->handle );
4592 static void dump_resume_process_request( const struct resume_process_request *req )
4594 fprintf( stderr, " handle=%04x", req->handle );
4597 static const dump_func req_dumpers[REQ_NB_REQUESTS] = {
4598 (dump_func)dump_new_process_request,
4599 (dump_func)dump_exec_process_request,
4600 (dump_func)dump_get_new_process_info_request,
4601 (dump_func)dump_new_thread_request,
4602 (dump_func)dump_get_startup_info_request,
4603 (dump_func)dump_init_process_done_request,
4604 (dump_func)dump_init_thread_request,
4605 (dump_func)dump_terminate_process_request,
4606 (dump_func)dump_terminate_thread_request,
4607 (dump_func)dump_get_process_info_request,
4608 (dump_func)dump_get_process_vm_counters_request,
4609 (dump_func)dump_set_process_info_request,
4610 (dump_func)dump_get_thread_info_request,
4611 (dump_func)dump_get_thread_times_request,
4612 (dump_func)dump_set_thread_info_request,
4613 (dump_func)dump_get_dll_info_request,
4614 (dump_func)dump_suspend_thread_request,
4615 (dump_func)dump_resume_thread_request,
4616 (dump_func)dump_load_dll_request,
4617 (dump_func)dump_unload_dll_request,
4618 (dump_func)dump_queue_apc_request,
4619 (dump_func)dump_get_apc_result_request,
4620 (dump_func)dump_close_handle_request,
4621 (dump_func)dump_set_handle_info_request,
4622 (dump_func)dump_dup_handle_request,
4623 (dump_func)dump_open_process_request,
4624 (dump_func)dump_open_thread_request,
4625 (dump_func)dump_select_request,
4626 (dump_func)dump_create_event_request,
4627 (dump_func)dump_event_op_request,
4628 (dump_func)dump_query_event_request,
4629 (dump_func)dump_open_event_request,
4630 (dump_func)dump_create_keyed_event_request,
4631 (dump_func)dump_open_keyed_event_request,
4632 (dump_func)dump_create_mutex_request,
4633 (dump_func)dump_release_mutex_request,
4634 (dump_func)dump_open_mutex_request,
4635 (dump_func)dump_query_mutex_request,
4636 (dump_func)dump_create_semaphore_request,
4637 (dump_func)dump_release_semaphore_request,
4638 (dump_func)dump_query_semaphore_request,
4639 (dump_func)dump_open_semaphore_request,
4640 (dump_func)dump_create_file_request,
4641 (dump_func)dump_open_file_object_request,
4642 (dump_func)dump_alloc_file_handle_request,
4643 (dump_func)dump_get_handle_unix_name_request,
4644 (dump_func)dump_get_handle_fd_request,
4645 (dump_func)dump_get_directory_cache_entry_request,
4646 (dump_func)dump_flush_request,
4647 (dump_func)dump_get_file_info_request,
4648 (dump_func)dump_get_volume_info_request,
4649 (dump_func)dump_lock_file_request,
4650 (dump_func)dump_unlock_file_request,
4651 (dump_func)dump_create_socket_request,
4652 (dump_func)dump_accept_socket_request,
4653 (dump_func)dump_accept_into_socket_request,
4654 (dump_func)dump_set_socket_event_request,
4655 (dump_func)dump_get_socket_event_request,
4656 (dump_func)dump_get_socket_info_request,
4657 (dump_func)dump_enable_socket_event_request,
4658 (dump_func)dump_set_socket_deferred_request,
4659 (dump_func)dump_alloc_console_request,
4660 (dump_func)dump_free_console_request,
4661 (dump_func)dump_get_console_renderer_events_request,
4662 (dump_func)dump_open_console_request,
4663 (dump_func)dump_attach_console_request,
4664 (dump_func)dump_get_console_wait_event_request,
4665 (dump_func)dump_get_console_mode_request,
4666 (dump_func)dump_set_console_mode_request,
4667 (dump_func)dump_set_console_input_info_request,
4668 (dump_func)dump_get_console_input_info_request,
4669 (dump_func)dump_append_console_input_history_request,
4670 (dump_func)dump_get_console_input_history_request,
4671 (dump_func)dump_create_console_output_request,
4672 (dump_func)dump_set_console_output_info_request,
4673 (dump_func)dump_get_console_output_info_request,
4674 (dump_func)dump_write_console_input_request,
4675 (dump_func)dump_read_console_input_request,
4676 (dump_func)dump_write_console_output_request,
4677 (dump_func)dump_fill_console_output_request,
4678 (dump_func)dump_read_console_output_request,
4679 (dump_func)dump_move_console_output_request,
4680 (dump_func)dump_send_console_signal_request,
4681 (dump_func)dump_read_directory_changes_request,
4682 (dump_func)dump_read_change_request,
4683 (dump_func)dump_create_mapping_request,
4684 (dump_func)dump_open_mapping_request,
4685 (dump_func)dump_get_mapping_info_request,
4686 (dump_func)dump_map_view_request,
4687 (dump_func)dump_unmap_view_request,
4688 (dump_func)dump_get_mapping_committed_range_request,
4689 (dump_func)dump_add_mapping_committed_range_request,
4690 (dump_func)dump_is_same_mapping_request,
4691 (dump_func)dump_create_snapshot_request,
4692 (dump_func)dump_next_process_request,
4693 (dump_func)dump_next_thread_request,
4694 (dump_func)dump_wait_debug_event_request,
4695 (dump_func)dump_queue_exception_event_request,
4696 (dump_func)dump_get_exception_status_request,
4697 (dump_func)dump_continue_debug_event_request,
4698 (dump_func)dump_debug_process_request,
4699 (dump_func)dump_set_debugger_kill_on_exit_request,
4700 (dump_func)dump_read_process_memory_request,
4701 (dump_func)dump_write_process_memory_request,
4702 (dump_func)dump_create_key_request,
4703 (dump_func)dump_open_key_request,
4704 (dump_func)dump_delete_key_request,
4705 (dump_func)dump_flush_key_request,
4706 (dump_func)dump_enum_key_request,
4707 (dump_func)dump_set_key_value_request,
4708 (dump_func)dump_get_key_value_request,
4709 (dump_func)dump_enum_key_value_request,
4710 (dump_func)dump_delete_key_value_request,
4711 (dump_func)dump_load_registry_request,
4712 (dump_func)dump_unload_registry_request,
4713 (dump_func)dump_save_registry_request,
4714 (dump_func)dump_set_registry_notification_request,
4715 (dump_func)dump_create_timer_request,
4716 (dump_func)dump_open_timer_request,
4717 (dump_func)dump_set_timer_request,
4718 (dump_func)dump_cancel_timer_request,
4719 (dump_func)dump_get_timer_info_request,
4720 (dump_func)dump_get_thread_context_request,
4721 (dump_func)dump_set_thread_context_request,
4722 (dump_func)dump_get_selector_entry_request,
4723 (dump_func)dump_add_atom_request,
4724 (dump_func)dump_delete_atom_request,
4725 (dump_func)dump_find_atom_request,
4726 (dump_func)dump_get_atom_information_request,
4727 (dump_func)dump_set_atom_information_request,
4728 (dump_func)dump_empty_atom_table_request,
4729 (dump_func)dump_init_atom_table_request,
4730 (dump_func)dump_get_msg_queue_request,
4731 (dump_func)dump_set_queue_fd_request,
4732 (dump_func)dump_set_queue_mask_request,
4733 (dump_func)dump_get_queue_status_request,
4734 (dump_func)dump_get_process_idle_event_request,
4735 (dump_func)dump_send_message_request,
4736 (dump_func)dump_post_quit_message_request,
4737 (dump_func)dump_send_hardware_message_request,
4738 (dump_func)dump_get_message_request,
4739 (dump_func)dump_reply_message_request,
4740 (dump_func)dump_accept_hardware_message_request,
4741 (dump_func)dump_get_message_reply_request,
4742 (dump_func)dump_set_win_timer_request,
4743 (dump_func)dump_kill_win_timer_request,
4744 (dump_func)dump_is_window_hung_request,
4745 (dump_func)dump_get_serial_info_request,
4746 (dump_func)dump_set_serial_info_request,
4747 (dump_func)dump_register_async_request,
4748 (dump_func)dump_cancel_async_request,
4749 (dump_func)dump_get_async_result_request,
4750 (dump_func)dump_read_request,
4751 (dump_func)dump_write_request,
4752 (dump_func)dump_ioctl_request,
4753 (dump_func)dump_set_irp_result_request,
4754 (dump_func)dump_create_named_pipe_request,
4755 (dump_func)dump_set_named_pipe_info_request,
4756 (dump_func)dump_create_window_request,
4757 (dump_func)dump_destroy_window_request,
4758 (dump_func)dump_get_desktop_window_request,
4759 (dump_func)dump_set_window_owner_request,
4760 (dump_func)dump_get_window_info_request,
4761 (dump_func)dump_set_window_info_request,
4762 (dump_func)dump_set_parent_request,
4763 (dump_func)dump_get_window_parents_request,
4764 (dump_func)dump_get_window_children_request,
4765 (dump_func)dump_get_window_children_from_point_request,
4766 (dump_func)dump_get_window_tree_request,
4767 (dump_func)dump_set_window_pos_request,
4768 (dump_func)dump_get_window_rectangles_request,
4769 (dump_func)dump_get_window_text_request,
4770 (dump_func)dump_set_window_text_request,
4771 (dump_func)dump_get_windows_offset_request,
4772 (dump_func)dump_get_visible_region_request,
4773 (dump_func)dump_get_surface_region_request,
4774 (dump_func)dump_get_window_region_request,
4775 (dump_func)dump_set_window_region_request,
4776 (dump_func)dump_get_update_region_request,
4777 (dump_func)dump_update_window_zorder_request,
4778 (dump_func)dump_redraw_window_request,
4779 (dump_func)dump_set_window_property_request,
4780 (dump_func)dump_remove_window_property_request,
4781 (dump_func)dump_get_window_property_request,
4782 (dump_func)dump_get_window_properties_request,
4783 (dump_func)dump_create_winstation_request,
4784 (dump_func)dump_open_winstation_request,
4785 (dump_func)dump_close_winstation_request,
4786 (dump_func)dump_get_process_winstation_request,
4787 (dump_func)dump_set_process_winstation_request,
4788 (dump_func)dump_enum_winstation_request,
4789 (dump_func)dump_create_desktop_request,
4790 (dump_func)dump_open_desktop_request,
4791 (dump_func)dump_open_input_desktop_request,
4792 (dump_func)dump_close_desktop_request,
4793 (dump_func)dump_get_thread_desktop_request,
4794 (dump_func)dump_set_thread_desktop_request,
4795 (dump_func)dump_enum_desktop_request,
4796 (dump_func)dump_set_user_object_info_request,
4797 (dump_func)dump_register_hotkey_request,
4798 (dump_func)dump_unregister_hotkey_request,
4799 (dump_func)dump_attach_thread_input_request,
4800 (dump_func)dump_get_thread_input_request,
4801 (dump_func)dump_get_last_input_time_request,
4802 (dump_func)dump_get_key_state_request,
4803 (dump_func)dump_set_key_state_request,
4804 (dump_func)dump_set_foreground_window_request,
4805 (dump_func)dump_set_focus_window_request,
4806 (dump_func)dump_set_active_window_request,
4807 (dump_func)dump_set_capture_window_request,
4808 (dump_func)dump_set_caret_window_request,
4809 (dump_func)dump_set_caret_info_request,
4810 (dump_func)dump_set_hook_request,
4811 (dump_func)dump_remove_hook_request,
4812 (dump_func)dump_start_hook_chain_request,
4813 (dump_func)dump_finish_hook_chain_request,
4814 (dump_func)dump_get_hook_info_request,
4815 (dump_func)dump_create_class_request,
4816 (dump_func)dump_destroy_class_request,
4817 (dump_func)dump_set_class_info_request,
4818 (dump_func)dump_open_clipboard_request,
4819 (dump_func)dump_close_clipboard_request,
4820 (dump_func)dump_empty_clipboard_request,
4821 (dump_func)dump_set_clipboard_data_request,
4822 (dump_func)dump_get_clipboard_data_request,
4823 (dump_func)dump_get_clipboard_formats_request,
4824 (dump_func)dump_enum_clipboard_formats_request,
4825 (dump_func)dump_release_clipboard_request,
4826 (dump_func)dump_get_clipboard_info_request,
4827 (dump_func)dump_set_clipboard_viewer_request,
4828 (dump_func)dump_add_clipboard_listener_request,
4829 (dump_func)dump_remove_clipboard_listener_request,
4830 (dump_func)dump_open_token_request,
4831 (dump_func)dump_set_global_windows_request,
4832 (dump_func)dump_adjust_token_privileges_request,
4833 (dump_func)dump_get_token_privileges_request,
4834 (dump_func)dump_check_token_privileges_request,
4835 (dump_func)dump_duplicate_token_request,
4836 (dump_func)dump_access_check_request,
4837 (dump_func)dump_get_token_sid_request,
4838 (dump_func)dump_get_token_groups_request,
4839 (dump_func)dump_get_token_default_dacl_request,
4840 (dump_func)dump_set_token_default_dacl_request,
4841 (dump_func)dump_set_security_object_request,
4842 (dump_func)dump_get_security_object_request,
4843 (dump_func)dump_get_system_handles_request,
4844 (dump_func)dump_create_mailslot_request,
4845 (dump_func)dump_set_mailslot_info_request,
4846 (dump_func)dump_create_directory_request,
4847 (dump_func)dump_open_directory_request,
4848 (dump_func)dump_get_directory_entry_request,
4849 (dump_func)dump_create_symlink_request,
4850 (dump_func)dump_open_symlink_request,
4851 (dump_func)dump_query_symlink_request,
4852 (dump_func)dump_get_object_info_request,
4853 (dump_func)dump_get_object_type_request,
4854 (dump_func)dump_unlink_object_request,
4855 (dump_func)dump_get_token_impersonation_level_request,
4856 (dump_func)dump_allocate_locally_unique_id_request,
4857 (dump_func)dump_create_device_manager_request,
4858 (dump_func)dump_create_device_request,
4859 (dump_func)dump_delete_device_request,
4860 (dump_func)dump_get_next_device_request_request,
4861 (dump_func)dump_get_kernel_object_ptr_request,
4862 (dump_func)dump_set_kernel_object_ptr_request,
4863 (dump_func)dump_grab_kernel_object_request,
4864 (dump_func)dump_release_kernel_object_request,
4865 (dump_func)dump_get_kernel_object_handle_request,
4866 (dump_func)dump_make_process_system_request,
4867 (dump_func)dump_get_token_statistics_request,
4868 (dump_func)dump_create_completion_request,
4869 (dump_func)dump_open_completion_request,
4870 (dump_func)dump_add_completion_request,
4871 (dump_func)dump_remove_completion_request,
4872 (dump_func)dump_query_completion_request,
4873 (dump_func)dump_set_completion_info_request,
4874 (dump_func)dump_add_fd_completion_request,
4875 (dump_func)dump_set_fd_completion_mode_request,
4876 (dump_func)dump_set_fd_disp_info_request,
4877 (dump_func)dump_set_fd_name_info_request,
4878 (dump_func)dump_get_window_layered_info_request,
4879 (dump_func)dump_set_window_layered_info_request,
4880 (dump_func)dump_alloc_user_handle_request,
4881 (dump_func)dump_free_user_handle_request,
4882 (dump_func)dump_set_cursor_request,
4883 (dump_func)dump_update_rawinput_devices_request,
4884 (dump_func)dump_create_job_request,
4885 (dump_func)dump_open_job_request,
4886 (dump_func)dump_assign_job_request,
4887 (dump_func)dump_process_in_job_request,
4888 (dump_func)dump_set_job_limits_request,
4889 (dump_func)dump_set_job_completion_port_request,
4890 (dump_func)dump_terminate_job_request,
4891 (dump_func)dump_suspend_process_request,
4892 (dump_func)dump_resume_process_request,
4895 static const dump_func reply_dumpers[REQ_NB_REQUESTS] = {
4896 (dump_func)dump_new_process_reply,
4897 NULL,
4898 (dump_func)dump_get_new_process_info_reply,
4899 (dump_func)dump_new_thread_reply,
4900 (dump_func)dump_get_startup_info_reply,
4901 (dump_func)dump_init_process_done_reply,
4902 (dump_func)dump_init_thread_reply,
4903 (dump_func)dump_terminate_process_reply,
4904 (dump_func)dump_terminate_thread_reply,
4905 (dump_func)dump_get_process_info_reply,
4906 (dump_func)dump_get_process_vm_counters_reply,
4907 NULL,
4908 (dump_func)dump_get_thread_info_reply,
4909 (dump_func)dump_get_thread_times_reply,
4910 NULL,
4911 (dump_func)dump_get_dll_info_reply,
4912 (dump_func)dump_suspend_thread_reply,
4913 (dump_func)dump_resume_thread_reply,
4914 NULL,
4915 NULL,
4916 (dump_func)dump_queue_apc_reply,
4917 (dump_func)dump_get_apc_result_reply,
4918 NULL,
4919 (dump_func)dump_set_handle_info_reply,
4920 (dump_func)dump_dup_handle_reply,
4921 (dump_func)dump_open_process_reply,
4922 (dump_func)dump_open_thread_reply,
4923 (dump_func)dump_select_reply,
4924 (dump_func)dump_create_event_reply,
4925 (dump_func)dump_event_op_reply,
4926 (dump_func)dump_query_event_reply,
4927 (dump_func)dump_open_event_reply,
4928 (dump_func)dump_create_keyed_event_reply,
4929 (dump_func)dump_open_keyed_event_reply,
4930 (dump_func)dump_create_mutex_reply,
4931 (dump_func)dump_release_mutex_reply,
4932 (dump_func)dump_open_mutex_reply,
4933 (dump_func)dump_query_mutex_reply,
4934 (dump_func)dump_create_semaphore_reply,
4935 (dump_func)dump_release_semaphore_reply,
4936 (dump_func)dump_query_semaphore_reply,
4937 (dump_func)dump_open_semaphore_reply,
4938 (dump_func)dump_create_file_reply,
4939 (dump_func)dump_open_file_object_reply,
4940 (dump_func)dump_alloc_file_handle_reply,
4941 (dump_func)dump_get_handle_unix_name_reply,
4942 (dump_func)dump_get_handle_fd_reply,
4943 (dump_func)dump_get_directory_cache_entry_reply,
4944 (dump_func)dump_flush_reply,
4945 (dump_func)dump_get_file_info_reply,
4946 (dump_func)dump_get_volume_info_reply,
4947 (dump_func)dump_lock_file_reply,
4948 NULL,
4949 (dump_func)dump_create_socket_reply,
4950 (dump_func)dump_accept_socket_reply,
4951 NULL,
4952 NULL,
4953 (dump_func)dump_get_socket_event_reply,
4954 (dump_func)dump_get_socket_info_reply,
4955 NULL,
4956 NULL,
4957 (dump_func)dump_alloc_console_reply,
4958 NULL,
4959 (dump_func)dump_get_console_renderer_events_reply,
4960 (dump_func)dump_open_console_reply,
4961 (dump_func)dump_attach_console_reply,
4962 (dump_func)dump_get_console_wait_event_reply,
4963 (dump_func)dump_get_console_mode_reply,
4964 NULL,
4965 NULL,
4966 (dump_func)dump_get_console_input_info_reply,
4967 NULL,
4968 (dump_func)dump_get_console_input_history_reply,
4969 (dump_func)dump_create_console_output_reply,
4970 NULL,
4971 (dump_func)dump_get_console_output_info_reply,
4972 (dump_func)dump_write_console_input_reply,
4973 (dump_func)dump_read_console_input_reply,
4974 (dump_func)dump_write_console_output_reply,
4975 (dump_func)dump_fill_console_output_reply,
4976 (dump_func)dump_read_console_output_reply,
4977 NULL,
4978 NULL,
4979 NULL,
4980 (dump_func)dump_read_change_reply,
4981 (dump_func)dump_create_mapping_reply,
4982 (dump_func)dump_open_mapping_reply,
4983 (dump_func)dump_get_mapping_info_reply,
4984 NULL,
4985 NULL,
4986 (dump_func)dump_get_mapping_committed_range_reply,
4987 NULL,
4988 NULL,
4989 (dump_func)dump_create_snapshot_reply,
4990 (dump_func)dump_next_process_reply,
4991 (dump_func)dump_next_thread_reply,
4992 (dump_func)dump_wait_debug_event_reply,
4993 (dump_func)dump_queue_exception_event_reply,
4994 NULL,
4995 NULL,
4996 NULL,
4997 NULL,
4998 (dump_func)dump_read_process_memory_reply,
4999 NULL,
5000 (dump_func)dump_create_key_reply,
5001 (dump_func)dump_open_key_reply,
5002 NULL,
5003 NULL,
5004 (dump_func)dump_enum_key_reply,
5005 NULL,
5006 (dump_func)dump_get_key_value_reply,
5007 (dump_func)dump_enum_key_value_reply,
5008 NULL,
5009 NULL,
5010 NULL,
5011 NULL,
5012 NULL,
5013 (dump_func)dump_create_timer_reply,
5014 (dump_func)dump_open_timer_reply,
5015 (dump_func)dump_set_timer_reply,
5016 (dump_func)dump_cancel_timer_reply,
5017 (dump_func)dump_get_timer_info_reply,
5018 (dump_func)dump_get_thread_context_reply,
5019 (dump_func)dump_set_thread_context_reply,
5020 (dump_func)dump_get_selector_entry_reply,
5021 (dump_func)dump_add_atom_reply,
5022 NULL,
5023 (dump_func)dump_find_atom_reply,
5024 (dump_func)dump_get_atom_information_reply,
5025 NULL,
5026 NULL,
5027 (dump_func)dump_init_atom_table_reply,
5028 (dump_func)dump_get_msg_queue_reply,
5029 NULL,
5030 (dump_func)dump_set_queue_mask_reply,
5031 (dump_func)dump_get_queue_status_reply,
5032 (dump_func)dump_get_process_idle_event_reply,
5033 NULL,
5034 NULL,
5035 (dump_func)dump_send_hardware_message_reply,
5036 (dump_func)dump_get_message_reply,
5037 NULL,
5038 NULL,
5039 (dump_func)dump_get_message_reply_reply,
5040 (dump_func)dump_set_win_timer_reply,
5041 NULL,
5042 (dump_func)dump_is_window_hung_reply,
5043 (dump_func)dump_get_serial_info_reply,
5044 NULL,
5045 NULL,
5046 NULL,
5047 (dump_func)dump_get_async_result_reply,
5048 (dump_func)dump_read_reply,
5049 (dump_func)dump_write_reply,
5050 (dump_func)dump_ioctl_reply,
5051 NULL,
5052 (dump_func)dump_create_named_pipe_reply,
5053 NULL,
5054 (dump_func)dump_create_window_reply,
5055 NULL,
5056 (dump_func)dump_get_desktop_window_reply,
5057 (dump_func)dump_set_window_owner_reply,
5058 (dump_func)dump_get_window_info_reply,
5059 (dump_func)dump_set_window_info_reply,
5060 (dump_func)dump_set_parent_reply,
5061 (dump_func)dump_get_window_parents_reply,
5062 (dump_func)dump_get_window_children_reply,
5063 (dump_func)dump_get_window_children_from_point_reply,
5064 (dump_func)dump_get_window_tree_reply,
5065 (dump_func)dump_set_window_pos_reply,
5066 (dump_func)dump_get_window_rectangles_reply,
5067 (dump_func)dump_get_window_text_reply,
5068 NULL,
5069 (dump_func)dump_get_windows_offset_reply,
5070 (dump_func)dump_get_visible_region_reply,
5071 (dump_func)dump_get_surface_region_reply,
5072 (dump_func)dump_get_window_region_reply,
5073 NULL,
5074 (dump_func)dump_get_update_region_reply,
5075 NULL,
5076 NULL,
5077 NULL,
5078 (dump_func)dump_remove_window_property_reply,
5079 (dump_func)dump_get_window_property_reply,
5080 (dump_func)dump_get_window_properties_reply,
5081 (dump_func)dump_create_winstation_reply,
5082 (dump_func)dump_open_winstation_reply,
5083 NULL,
5084 (dump_func)dump_get_process_winstation_reply,
5085 NULL,
5086 (dump_func)dump_enum_winstation_reply,
5087 (dump_func)dump_create_desktop_reply,
5088 (dump_func)dump_open_desktop_reply,
5089 (dump_func)dump_open_input_desktop_reply,
5090 NULL,
5091 (dump_func)dump_get_thread_desktop_reply,
5092 NULL,
5093 (dump_func)dump_enum_desktop_reply,
5094 (dump_func)dump_set_user_object_info_reply,
5095 (dump_func)dump_register_hotkey_reply,
5096 (dump_func)dump_unregister_hotkey_reply,
5097 NULL,
5098 (dump_func)dump_get_thread_input_reply,
5099 (dump_func)dump_get_last_input_time_reply,
5100 (dump_func)dump_get_key_state_reply,
5101 NULL,
5102 (dump_func)dump_set_foreground_window_reply,
5103 (dump_func)dump_set_focus_window_reply,
5104 (dump_func)dump_set_active_window_reply,
5105 (dump_func)dump_set_capture_window_reply,
5106 (dump_func)dump_set_caret_window_reply,
5107 (dump_func)dump_set_caret_info_reply,
5108 (dump_func)dump_set_hook_reply,
5109 (dump_func)dump_remove_hook_reply,
5110 (dump_func)dump_start_hook_chain_reply,
5111 NULL,
5112 (dump_func)dump_get_hook_info_reply,
5113 (dump_func)dump_create_class_reply,
5114 (dump_func)dump_destroy_class_reply,
5115 (dump_func)dump_set_class_info_reply,
5116 (dump_func)dump_open_clipboard_reply,
5117 (dump_func)dump_close_clipboard_reply,
5118 NULL,
5119 (dump_func)dump_set_clipboard_data_reply,
5120 (dump_func)dump_get_clipboard_data_reply,
5121 (dump_func)dump_get_clipboard_formats_reply,
5122 (dump_func)dump_enum_clipboard_formats_reply,
5123 (dump_func)dump_release_clipboard_reply,
5124 (dump_func)dump_get_clipboard_info_reply,
5125 (dump_func)dump_set_clipboard_viewer_reply,
5126 NULL,
5127 NULL,
5128 (dump_func)dump_open_token_reply,
5129 (dump_func)dump_set_global_windows_reply,
5130 (dump_func)dump_adjust_token_privileges_reply,
5131 (dump_func)dump_get_token_privileges_reply,
5132 (dump_func)dump_check_token_privileges_reply,
5133 (dump_func)dump_duplicate_token_reply,
5134 (dump_func)dump_access_check_reply,
5135 (dump_func)dump_get_token_sid_reply,
5136 (dump_func)dump_get_token_groups_reply,
5137 (dump_func)dump_get_token_default_dacl_reply,
5138 NULL,
5139 NULL,
5140 (dump_func)dump_get_security_object_reply,
5141 (dump_func)dump_get_system_handles_reply,
5142 (dump_func)dump_create_mailslot_reply,
5143 (dump_func)dump_set_mailslot_info_reply,
5144 (dump_func)dump_create_directory_reply,
5145 (dump_func)dump_open_directory_reply,
5146 (dump_func)dump_get_directory_entry_reply,
5147 (dump_func)dump_create_symlink_reply,
5148 (dump_func)dump_open_symlink_reply,
5149 (dump_func)dump_query_symlink_reply,
5150 (dump_func)dump_get_object_info_reply,
5151 (dump_func)dump_get_object_type_reply,
5152 NULL,
5153 (dump_func)dump_get_token_impersonation_level_reply,
5154 (dump_func)dump_allocate_locally_unique_id_reply,
5155 (dump_func)dump_create_device_manager_reply,
5156 NULL,
5157 NULL,
5158 (dump_func)dump_get_next_device_request_reply,
5159 (dump_func)dump_get_kernel_object_ptr_reply,
5160 NULL,
5161 NULL,
5162 NULL,
5163 (dump_func)dump_get_kernel_object_handle_reply,
5164 (dump_func)dump_make_process_system_reply,
5165 (dump_func)dump_get_token_statistics_reply,
5166 (dump_func)dump_create_completion_reply,
5167 (dump_func)dump_open_completion_reply,
5168 NULL,
5169 (dump_func)dump_remove_completion_reply,
5170 (dump_func)dump_query_completion_reply,
5171 NULL,
5172 NULL,
5173 NULL,
5174 NULL,
5175 NULL,
5176 (dump_func)dump_get_window_layered_info_reply,
5177 NULL,
5178 (dump_func)dump_alloc_user_handle_reply,
5179 NULL,
5180 (dump_func)dump_set_cursor_reply,
5181 NULL,
5182 (dump_func)dump_create_job_reply,
5183 (dump_func)dump_open_job_reply,
5184 NULL,
5185 NULL,
5186 NULL,
5187 NULL,
5188 NULL,
5189 NULL,
5190 NULL,
5193 static const char * const req_names[REQ_NB_REQUESTS] = {
5194 "new_process",
5195 "exec_process",
5196 "get_new_process_info",
5197 "new_thread",
5198 "get_startup_info",
5199 "init_process_done",
5200 "init_thread",
5201 "terminate_process",
5202 "terminate_thread",
5203 "get_process_info",
5204 "get_process_vm_counters",
5205 "set_process_info",
5206 "get_thread_info",
5207 "get_thread_times",
5208 "set_thread_info",
5209 "get_dll_info",
5210 "suspend_thread",
5211 "resume_thread",
5212 "load_dll",
5213 "unload_dll",
5214 "queue_apc",
5215 "get_apc_result",
5216 "close_handle",
5217 "set_handle_info",
5218 "dup_handle",
5219 "open_process",
5220 "open_thread",
5221 "select",
5222 "create_event",
5223 "event_op",
5224 "query_event",
5225 "open_event",
5226 "create_keyed_event",
5227 "open_keyed_event",
5228 "create_mutex",
5229 "release_mutex",
5230 "open_mutex",
5231 "query_mutex",
5232 "create_semaphore",
5233 "release_semaphore",
5234 "query_semaphore",
5235 "open_semaphore",
5236 "create_file",
5237 "open_file_object",
5238 "alloc_file_handle",
5239 "get_handle_unix_name",
5240 "get_handle_fd",
5241 "get_directory_cache_entry",
5242 "flush",
5243 "get_file_info",
5244 "get_volume_info",
5245 "lock_file",
5246 "unlock_file",
5247 "create_socket",
5248 "accept_socket",
5249 "accept_into_socket",
5250 "set_socket_event",
5251 "get_socket_event",
5252 "get_socket_info",
5253 "enable_socket_event",
5254 "set_socket_deferred",
5255 "alloc_console",
5256 "free_console",
5257 "get_console_renderer_events",
5258 "open_console",
5259 "attach_console",
5260 "get_console_wait_event",
5261 "get_console_mode",
5262 "set_console_mode",
5263 "set_console_input_info",
5264 "get_console_input_info",
5265 "append_console_input_history",
5266 "get_console_input_history",
5267 "create_console_output",
5268 "set_console_output_info",
5269 "get_console_output_info",
5270 "write_console_input",
5271 "read_console_input",
5272 "write_console_output",
5273 "fill_console_output",
5274 "read_console_output",
5275 "move_console_output",
5276 "send_console_signal",
5277 "read_directory_changes",
5278 "read_change",
5279 "create_mapping",
5280 "open_mapping",
5281 "get_mapping_info",
5282 "map_view",
5283 "unmap_view",
5284 "get_mapping_committed_range",
5285 "add_mapping_committed_range",
5286 "is_same_mapping",
5287 "create_snapshot",
5288 "next_process",
5289 "next_thread",
5290 "wait_debug_event",
5291 "queue_exception_event",
5292 "get_exception_status",
5293 "continue_debug_event",
5294 "debug_process",
5295 "set_debugger_kill_on_exit",
5296 "read_process_memory",
5297 "write_process_memory",
5298 "create_key",
5299 "open_key",
5300 "delete_key",
5301 "flush_key",
5302 "enum_key",
5303 "set_key_value",
5304 "get_key_value",
5305 "enum_key_value",
5306 "delete_key_value",
5307 "load_registry",
5308 "unload_registry",
5309 "save_registry",
5310 "set_registry_notification",
5311 "create_timer",
5312 "open_timer",
5313 "set_timer",
5314 "cancel_timer",
5315 "get_timer_info",
5316 "get_thread_context",
5317 "set_thread_context",
5318 "get_selector_entry",
5319 "add_atom",
5320 "delete_atom",
5321 "find_atom",
5322 "get_atom_information",
5323 "set_atom_information",
5324 "empty_atom_table",
5325 "init_atom_table",
5326 "get_msg_queue",
5327 "set_queue_fd",
5328 "set_queue_mask",
5329 "get_queue_status",
5330 "get_process_idle_event",
5331 "send_message",
5332 "post_quit_message",
5333 "send_hardware_message",
5334 "get_message",
5335 "reply_message",
5336 "accept_hardware_message",
5337 "get_message_reply",
5338 "set_win_timer",
5339 "kill_win_timer",
5340 "is_window_hung",
5341 "get_serial_info",
5342 "set_serial_info",
5343 "register_async",
5344 "cancel_async",
5345 "get_async_result",
5346 "read",
5347 "write",
5348 "ioctl",
5349 "set_irp_result",
5350 "create_named_pipe",
5351 "set_named_pipe_info",
5352 "create_window",
5353 "destroy_window",
5354 "get_desktop_window",
5355 "set_window_owner",
5356 "get_window_info",
5357 "set_window_info",
5358 "set_parent",
5359 "get_window_parents",
5360 "get_window_children",
5361 "get_window_children_from_point",
5362 "get_window_tree",
5363 "set_window_pos",
5364 "get_window_rectangles",
5365 "get_window_text",
5366 "set_window_text",
5367 "get_windows_offset",
5368 "get_visible_region",
5369 "get_surface_region",
5370 "get_window_region",
5371 "set_window_region",
5372 "get_update_region",
5373 "update_window_zorder",
5374 "redraw_window",
5375 "set_window_property",
5376 "remove_window_property",
5377 "get_window_property",
5378 "get_window_properties",
5379 "create_winstation",
5380 "open_winstation",
5381 "close_winstation",
5382 "get_process_winstation",
5383 "set_process_winstation",
5384 "enum_winstation",
5385 "create_desktop",
5386 "open_desktop",
5387 "open_input_desktop",
5388 "close_desktop",
5389 "get_thread_desktop",
5390 "set_thread_desktop",
5391 "enum_desktop",
5392 "set_user_object_info",
5393 "register_hotkey",
5394 "unregister_hotkey",
5395 "attach_thread_input",
5396 "get_thread_input",
5397 "get_last_input_time",
5398 "get_key_state",
5399 "set_key_state",
5400 "set_foreground_window",
5401 "set_focus_window",
5402 "set_active_window",
5403 "set_capture_window",
5404 "set_caret_window",
5405 "set_caret_info",
5406 "set_hook",
5407 "remove_hook",
5408 "start_hook_chain",
5409 "finish_hook_chain",
5410 "get_hook_info",
5411 "create_class",
5412 "destroy_class",
5413 "set_class_info",
5414 "open_clipboard",
5415 "close_clipboard",
5416 "empty_clipboard",
5417 "set_clipboard_data",
5418 "get_clipboard_data",
5419 "get_clipboard_formats",
5420 "enum_clipboard_formats",
5421 "release_clipboard",
5422 "get_clipboard_info",
5423 "set_clipboard_viewer",
5424 "add_clipboard_listener",
5425 "remove_clipboard_listener",
5426 "open_token",
5427 "set_global_windows",
5428 "adjust_token_privileges",
5429 "get_token_privileges",
5430 "check_token_privileges",
5431 "duplicate_token",
5432 "access_check",
5433 "get_token_sid",
5434 "get_token_groups",
5435 "get_token_default_dacl",
5436 "set_token_default_dacl",
5437 "set_security_object",
5438 "get_security_object",
5439 "get_system_handles",
5440 "create_mailslot",
5441 "set_mailslot_info",
5442 "create_directory",
5443 "open_directory",
5444 "get_directory_entry",
5445 "create_symlink",
5446 "open_symlink",
5447 "query_symlink",
5448 "get_object_info",
5449 "get_object_type",
5450 "unlink_object",
5451 "get_token_impersonation_level",
5452 "allocate_locally_unique_id",
5453 "create_device_manager",
5454 "create_device",
5455 "delete_device",
5456 "get_next_device_request",
5457 "get_kernel_object_ptr",
5458 "set_kernel_object_ptr",
5459 "grab_kernel_object",
5460 "release_kernel_object",
5461 "get_kernel_object_handle",
5462 "make_process_system",
5463 "get_token_statistics",
5464 "create_completion",
5465 "open_completion",
5466 "add_completion",
5467 "remove_completion",
5468 "query_completion",
5469 "set_completion_info",
5470 "add_fd_completion",
5471 "set_fd_completion_mode",
5472 "set_fd_disp_info",
5473 "set_fd_name_info",
5474 "get_window_layered_info",
5475 "set_window_layered_info",
5476 "alloc_user_handle",
5477 "free_user_handle",
5478 "set_cursor",
5479 "update_rawinput_devices",
5480 "create_job",
5481 "open_job",
5482 "assign_job",
5483 "process_in_job",
5484 "set_job_limits",
5485 "set_job_completion_port",
5486 "terminate_job",
5487 "suspend_process",
5488 "resume_process",
5491 static const struct
5493 const char *name;
5494 unsigned int value;
5495 } status_names[] =
5497 { "ABANDONED_WAIT_0", STATUS_ABANDONED_WAIT_0 },
5498 { "ACCESS_DENIED", STATUS_ACCESS_DENIED },
5499 { "ACCESS_VIOLATION", STATUS_ACCESS_VIOLATION },
5500 { "ADDRESS_ALREADY_ASSOCIATED", STATUS_ADDRESS_ALREADY_ASSOCIATED },
5501 { "ALERTED", STATUS_ALERTED },
5502 { "ALIAS_EXISTS", STATUS_ALIAS_EXISTS },
5503 { "BAD_DEVICE_TYPE", STATUS_BAD_DEVICE_TYPE },
5504 { "BAD_IMPERSONATION_LEVEL", STATUS_BAD_IMPERSONATION_LEVEL },
5505 { "BUFFER_OVERFLOW", STATUS_BUFFER_OVERFLOW },
5506 { "BUFFER_TOO_SMALL", STATUS_BUFFER_TOO_SMALL },
5507 { "CANCELLED", STATUS_CANCELLED },
5508 { "CANNOT_DELETE", STATUS_CANNOT_DELETE },
5509 { "CANT_OPEN_ANONYMOUS", STATUS_CANT_OPEN_ANONYMOUS },
5510 { "CANT_WAIT", STATUS_CANT_WAIT },
5511 { "CHILD_MUST_BE_VOLATILE", STATUS_CHILD_MUST_BE_VOLATILE },
5512 { "CONNECTION_ABORTED", STATUS_CONNECTION_ABORTED },
5513 { "CONNECTION_DISCONNECTED", STATUS_CONNECTION_DISCONNECTED },
5514 { "CONNECTION_REFUSED", STATUS_CONNECTION_REFUSED },
5515 { "CONNECTION_RESET", STATUS_CONNECTION_RESET },
5516 { "DEBUGGER_INACTIVE", STATUS_DEBUGGER_INACTIVE },
5517 { "DEVICE_BUSY", STATUS_DEVICE_BUSY },
5518 { "DIRECTORY_NOT_EMPTY", STATUS_DIRECTORY_NOT_EMPTY },
5519 { "DISK_FULL", STATUS_DISK_FULL },
5520 { "DLL_NOT_FOUND", STATUS_DLL_NOT_FOUND },
5521 { "ERROR_CLASS_ALREADY_EXISTS", 0xc0010000 | ERROR_CLASS_ALREADY_EXISTS },
5522 { "ERROR_CLASS_DOES_NOT_EXIST", 0xc0010000 | ERROR_CLASS_DOES_NOT_EXIST },
5523 { "ERROR_CLASS_HAS_WINDOWS", 0xc0010000 | ERROR_CLASS_HAS_WINDOWS },
5524 { "ERROR_CLIPBOARD_NOT_OPEN", 0xc0010000 | ERROR_CLIPBOARD_NOT_OPEN },
5525 { "ERROR_HOTKEY_ALREADY_REGISTERED", 0xc0010000 | ERROR_HOTKEY_ALREADY_REGISTERED },
5526 { "ERROR_HOTKEY_NOT_REGISTERED", 0xc0010000 | ERROR_HOTKEY_NOT_REGISTERED },
5527 { "ERROR_INVALID_CURSOR_HANDLE", 0xc0010000 | ERROR_INVALID_CURSOR_HANDLE },
5528 { "ERROR_INVALID_INDEX", 0xc0010000 | ERROR_INVALID_INDEX },
5529 { "ERROR_INVALID_WINDOW_HANDLE", 0xc0010000 | ERROR_INVALID_WINDOW_HANDLE },
5530 { "ERROR_NO_MORE_USER_HANDLES", 0xc0010000 | ERROR_NO_MORE_USER_HANDLES },
5531 { "ERROR_WINDOW_OF_OTHER_THREAD", 0xc0010000 | ERROR_WINDOW_OF_OTHER_THREAD },
5532 { "FILE_DELETED", STATUS_FILE_DELETED },
5533 { "FILE_IS_A_DIRECTORY", STATUS_FILE_IS_A_DIRECTORY },
5534 { "FILE_LOCK_CONFLICT", STATUS_FILE_LOCK_CONFLICT },
5535 { "GENERIC_NOT_MAPPED", STATUS_GENERIC_NOT_MAPPED },
5536 { "HANDLES_CLOSED", STATUS_HANDLES_CLOSED },
5537 { "HANDLE_NOT_CLOSABLE", STATUS_HANDLE_NOT_CLOSABLE },
5538 { "HOST_UNREACHABLE", STATUS_HOST_UNREACHABLE },
5539 { "ILLEGAL_FUNCTION", STATUS_ILLEGAL_FUNCTION },
5540 { "INFO_LENGTH_MISMATCH", STATUS_INFO_LENGTH_MISMATCH },
5541 { "INSTANCE_NOT_AVAILABLE", STATUS_INSTANCE_NOT_AVAILABLE },
5542 { "INSUFFICIENT_RESOURCES", STATUS_INSUFFICIENT_RESOURCES },
5543 { "INVALID_CID", STATUS_INVALID_CID },
5544 { "INVALID_DEVICE_REQUEST", STATUS_INVALID_DEVICE_REQUEST },
5545 { "INVALID_FILE_FOR_SECTION", STATUS_INVALID_FILE_FOR_SECTION },
5546 { "INVALID_HANDLE", STATUS_INVALID_HANDLE },
5547 { "INVALID_IMAGE_FORMAT", STATUS_INVALID_IMAGE_FORMAT },
5548 { "INVALID_IMAGE_NE_FORMAT", STATUS_INVALID_IMAGE_NE_FORMAT },
5549 { "INVALID_IMAGE_NOT_MZ", STATUS_INVALID_IMAGE_NOT_MZ },
5550 { "INVALID_IMAGE_PROTECT", STATUS_INVALID_IMAGE_PROTECT },
5551 { "INVALID_IMAGE_WIN_16", STATUS_INVALID_IMAGE_WIN_16 },
5552 { "INVALID_IMAGE_WIN_64", STATUS_INVALID_IMAGE_WIN_64 },
5553 { "INVALID_LOCK_SEQUENCE", STATUS_INVALID_LOCK_SEQUENCE },
5554 { "INVALID_OWNER", STATUS_INVALID_OWNER },
5555 { "INVALID_PARAMETER", STATUS_INVALID_PARAMETER },
5556 { "INVALID_PIPE_STATE", STATUS_INVALID_PIPE_STATE },
5557 { "INVALID_READ_MODE", STATUS_INVALID_READ_MODE },
5558 { "INVALID_SECURITY_DESCR", STATUS_INVALID_SECURITY_DESCR },
5559 { "IO_TIMEOUT", STATUS_IO_TIMEOUT },
5560 { "KERNEL_APC", STATUS_KERNEL_APC },
5561 { "KEY_DELETED", STATUS_KEY_DELETED },
5562 { "MAPPED_FILE_SIZE_ZERO", STATUS_MAPPED_FILE_SIZE_ZERO },
5563 { "MORE_PROCESSING_REQUIRED", STATUS_MORE_PROCESSING_REQUIRED },
5564 { "MUTANT_NOT_OWNED", STATUS_MUTANT_NOT_OWNED },
5565 { "NAME_TOO_LONG", STATUS_NAME_TOO_LONG },
5566 { "NETWORK_BUSY", STATUS_NETWORK_BUSY },
5567 { "NETWORK_UNREACHABLE", STATUS_NETWORK_UNREACHABLE },
5568 { "NOT_ALL_ASSIGNED", STATUS_NOT_ALL_ASSIGNED },
5569 { "NOT_A_DIRECTORY", STATUS_NOT_A_DIRECTORY },
5570 { "NOT_FOUND", STATUS_NOT_FOUND },
5571 { "NOT_IMPLEMENTED", STATUS_NOT_IMPLEMENTED },
5572 { "NOT_MAPPED_VIEW", STATUS_NOT_MAPPED_VIEW },
5573 { "NOT_REGISTRY_FILE", STATUS_NOT_REGISTRY_FILE },
5574 { "NOT_SAME_DEVICE", STATUS_NOT_SAME_DEVICE },
5575 { "NOT_SUPPORTED", STATUS_NOT_SUPPORTED },
5576 { "NO_DATA_DETECTED", STATUS_NO_DATA_DETECTED },
5577 { "NO_IMPERSONATION_TOKEN", STATUS_NO_IMPERSONATION_TOKEN },
5578 { "NO_MEMORY", STATUS_NO_MEMORY },
5579 { "NO_MORE_ENTRIES", STATUS_NO_MORE_ENTRIES },
5580 { "NO_MORE_FILES", STATUS_NO_MORE_FILES },
5581 { "NO_SUCH_DEVICE", STATUS_NO_SUCH_DEVICE },
5582 { "NO_SUCH_FILE", STATUS_NO_SUCH_FILE },
5583 { "NO_TOKEN", STATUS_NO_TOKEN },
5584 { "OBJECT_NAME_COLLISION", STATUS_OBJECT_NAME_COLLISION },
5585 { "OBJECT_NAME_EXISTS", STATUS_OBJECT_NAME_EXISTS },
5586 { "OBJECT_NAME_INVALID", STATUS_OBJECT_NAME_INVALID },
5587 { "OBJECT_NAME_NOT_FOUND", STATUS_OBJECT_NAME_NOT_FOUND },
5588 { "OBJECT_PATH_INVALID", STATUS_OBJECT_PATH_INVALID },
5589 { "OBJECT_PATH_NOT_FOUND", STATUS_OBJECT_PATH_NOT_FOUND },
5590 { "OBJECT_PATH_SYNTAX_BAD", STATUS_OBJECT_PATH_SYNTAX_BAD },
5591 { "OBJECT_TYPE_MISMATCH", STATUS_OBJECT_TYPE_MISMATCH },
5592 { "PENDING", STATUS_PENDING },
5593 { "PIPE_BROKEN", STATUS_PIPE_BROKEN },
5594 { "PIPE_BUSY", STATUS_PIPE_BUSY },
5595 { "PIPE_CLOSING", STATUS_PIPE_CLOSING },
5596 { "PIPE_CONNECTED", STATUS_PIPE_CONNECTED },
5597 { "PIPE_DISCONNECTED", STATUS_PIPE_DISCONNECTED },
5598 { "PIPE_EMPTY", STATUS_PIPE_EMPTY },
5599 { "PIPE_LISTENING", STATUS_PIPE_LISTENING },
5600 { "PIPE_NOT_AVAILABLE", STATUS_PIPE_NOT_AVAILABLE },
5601 { "PRIVILEGE_NOT_HELD", STATUS_PRIVILEGE_NOT_HELD },
5602 { "PROCESS_IN_JOB", STATUS_PROCESS_IN_JOB },
5603 { "PROCESS_IS_TERMINATING", STATUS_PROCESS_IS_TERMINATING },
5604 { "PROCESS_NOT_IN_JOB", STATUS_PROCESS_NOT_IN_JOB },
5605 { "REPARSE_POINT_NOT_RESOLVED", STATUS_REPARSE_POINT_NOT_RESOLVED },
5606 { "SECTION_TOO_BIG", STATUS_SECTION_TOO_BIG },
5607 { "SEMAPHORE_LIMIT_EXCEEDED", STATUS_SEMAPHORE_LIMIT_EXCEEDED },
5608 { "SHARING_VIOLATION", STATUS_SHARING_VIOLATION },
5609 { "SHUTDOWN_IN_PROGRESS", STATUS_SHUTDOWN_IN_PROGRESS },
5610 { "SUSPEND_COUNT_EXCEEDED", STATUS_SUSPEND_COUNT_EXCEEDED },
5611 { "THREAD_IS_TERMINATING", STATUS_THREAD_IS_TERMINATING },
5612 { "TIMEOUT", STATUS_TIMEOUT },
5613 { "TOO_MANY_OPENED_FILES", STATUS_TOO_MANY_OPENED_FILES },
5614 { "UNSUCCESSFUL", STATUS_UNSUCCESSFUL },
5615 { "USER_APC", STATUS_USER_APC },
5616 { "USER_MAPPED_FILE", STATUS_USER_MAPPED_FILE },
5617 { "VOLUME_DISMOUNTED", STATUS_VOLUME_DISMOUNTED },
5618 { "WAS_LOCKED", STATUS_WAS_LOCKED },
5619 { "WSAEACCES", 0xc0010000 | WSAEACCES },
5620 { "WSAEADDRINUSE", 0xc0010000 | WSAEADDRINUSE },
5621 { "WSAEADDRNOTAVAIL", 0xc0010000 | WSAEADDRNOTAVAIL },
5622 { "WSAEAFNOSUPPORT", 0xc0010000 | WSAEAFNOSUPPORT },
5623 { "WSAEALREADY", 0xc0010000 | WSAEALREADY },
5624 { "WSAEBADF", 0xc0010000 | WSAEBADF },
5625 { "WSAECONNABORTED", 0xc0010000 | WSAECONNABORTED },
5626 { "WSAECONNREFUSED", 0xc0010000 | WSAECONNREFUSED },
5627 { "WSAECONNRESET", 0xc0010000 | WSAECONNRESET },
5628 { "WSAEDESTADDRREQ", 0xc0010000 | WSAEDESTADDRREQ },
5629 { "WSAEDQUOT", 0xc0010000 | WSAEDQUOT },
5630 { "WSAEFAULT", 0xc0010000 | WSAEFAULT },
5631 { "WSAEHOSTDOWN", 0xc0010000 | WSAEHOSTDOWN },
5632 { "WSAEHOSTUNREACH", 0xc0010000 | WSAEHOSTUNREACH },
5633 { "WSAEINPROGRESS", 0xc0010000 | WSAEINPROGRESS },
5634 { "WSAEINTR", 0xc0010000 | WSAEINTR },
5635 { "WSAEINVAL", 0xc0010000 | WSAEINVAL },
5636 { "WSAEISCONN", 0xc0010000 | WSAEISCONN },
5637 { "WSAELOOP", 0xc0010000 | WSAELOOP },
5638 { "WSAEMFILE", 0xc0010000 | WSAEMFILE },
5639 { "WSAEMSGSIZE", 0xc0010000 | WSAEMSGSIZE },
5640 { "WSAENAMETOOLONG", 0xc0010000 | WSAENAMETOOLONG },
5641 { "WSAENETDOWN", 0xc0010000 | WSAENETDOWN },
5642 { "WSAENETRESET", 0xc0010000 | WSAENETRESET },
5643 { "WSAENETUNREACH", 0xc0010000 | WSAENETUNREACH },
5644 { "WSAENOBUFS", 0xc0010000 | WSAENOBUFS },
5645 { "WSAENOPROTOOPT", 0xc0010000 | WSAENOPROTOOPT },
5646 { "WSAENOTCONN", 0xc0010000 | WSAENOTCONN },
5647 { "WSAENOTEMPTY", 0xc0010000 | WSAENOTEMPTY },
5648 { "WSAENOTSOCK", 0xc0010000 | WSAENOTSOCK },
5649 { "WSAEOPNOTSUPP", 0xc0010000 | WSAEOPNOTSUPP },
5650 { "WSAEPFNOSUPPORT", 0xc0010000 | WSAEPFNOSUPPORT },
5651 { "WSAEPROCLIM", 0xc0010000 | WSAEPROCLIM },
5652 { "WSAEPROTONOSUPPORT", 0xc0010000 | WSAEPROTONOSUPPORT },
5653 { "WSAEPROTOTYPE", 0xc0010000 | WSAEPROTOTYPE },
5654 { "WSAEREMOTE", 0xc0010000 | WSAEREMOTE },
5655 { "WSAESHUTDOWN", 0xc0010000 | WSAESHUTDOWN },
5656 { "WSAESOCKTNOSUPPORT", 0xc0010000 | WSAESOCKTNOSUPPORT },
5657 { "WSAESTALE", 0xc0010000 | WSAESTALE },
5658 { "WSAETIMEDOUT", 0xc0010000 | WSAETIMEDOUT },
5659 { "WSAETOOMANYREFS", 0xc0010000 | WSAETOOMANYREFS },
5660 { "WSAEUSERS", 0xc0010000 | WSAEUSERS },
5661 { "WSAEWOULDBLOCK", 0xc0010000 | WSAEWOULDBLOCK },
5662 { NULL, 0 }
5665 /* ### make_requests end ### */
5666 /* Everything above this line is generated automatically by tools/make_requests */
5668 static const char *get_status_name( unsigned int status )
5670 int i;
5671 static char buffer[10];
5673 if (status)
5675 for (i = 0; status_names[i].name; i++)
5676 if (status_names[i].value == status) return status_names[i].name;
5678 sprintf( buffer, "%x", status );
5679 return buffer;
5682 void trace_request(void)
5684 enum request req = current->req.request_header.req;
5685 if (req < REQ_NB_REQUESTS)
5687 fprintf( stderr, "%04x: %s(", current->id, req_names[req] );
5688 if (req_dumpers[req])
5690 cur_data = get_req_data();
5691 cur_size = get_req_data_size();
5692 req_dumpers[req]( &current->req );
5694 fprintf( stderr, " )\n" );
5696 else fprintf( stderr, "%04x: %d(?)\n", current->id, req );
5699 void trace_reply( enum request req, const union generic_reply *reply )
5701 if (req < REQ_NB_REQUESTS)
5703 fprintf( stderr, "%04x: %s() = %s",
5704 current->id, req_names[req], get_status_name(current->error) );
5705 if (reply_dumpers[req])
5707 fprintf( stderr, " {" );
5708 cur_data = current->reply_data;
5709 cur_size = reply->reply_header.reply_size;
5710 reply_dumpers[req]( reply );
5711 fprintf( stderr, " }" );
5713 fputc( '\n', stderr );
5715 else fprintf( stderr, "%04x: %d() = %s\n",
5716 current->id, req, get_status_name(current->error) );