shlwapi: Uninitialized variable fix (Coverity).
[wine/wine64.git] / server / trace.c
blob0c0798efa763f42085231deef4f50159332c442f
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 "file.h"
40 #include "request.h"
41 #include "unicode.h"
43 static const void *cur_data;
44 static data_size_t cur_size;
46 static const char *get_status_name( unsigned int status );
48 /* utility functions */
50 inline static void remove_data( data_size_t size )
52 cur_data = (const char *)cur_data + size;
53 cur_size -= size;
56 static void dump_uints( const int *ptr, int len )
58 fputc( '{', stderr );
59 while (len > 0)
61 fprintf( stderr, "%08x", *ptr++ );
62 if (--len) fputc( ',', stderr );
64 fputc( '}', stderr );
67 static void dump_abs_time( const abs_time_t *time )
69 int secs, usecs;
71 if (!time->sec && !time->usec)
73 fprintf( stderr, "0" );
74 return;
76 secs = time->sec - current_time.tv_sec;
77 if ((usecs = time->usec - current_time.tv_usec) < 0)
79 usecs += 1000000;
80 secs--;
82 if (secs > 0 || (secs == 0 && usecs >= 0))
83 fprintf( stderr, "%d.%06d (+%d.%06d)", time->sec, time->usec, secs, usecs );
84 else
85 fprintf( stderr, "%d.%06d (-%d.%06d)", time->sec, time->usec, abs(secs+1), 1000000-usecs );
88 static void dump_rectangle( const rectangle_t *rect )
90 fprintf( stderr, "{%d,%d;%d,%d}",
91 rect->left, rect->top, rect->right, rect->bottom );
94 static void dump_char_info( const char_info_t *info )
96 fprintf( stderr, "{'" );
97 dump_strW( &info->ch, 1, stderr, "\'\'" );
98 fprintf( stderr, "',%04x}", info->attr );
101 static void dump_apc_call( const apc_call_t *call )
103 fputc( '{', stderr );
104 switch(call->type)
106 case APC_NONE:
107 fprintf( stderr, "APC_NONE" );
108 break;
109 case APC_USER:
110 fprintf( stderr, "APC_USER,args={%lx,%lx,%lx}",
111 call->user.args[0], call->user.args[1], call->user.args[2] );
112 break;
113 case APC_TIMER:
114 fprintf( stderr, "APC_TIMER,time=" );
115 dump_abs_time( &call->timer.time );
116 fprintf( stderr, ",arg=%p", call->timer.arg );
117 break;
118 case APC_ASYNC_IO:
119 fprintf( stderr, "APC_ASYNC_IO,user=%p,sb=%p,status=%s",
120 call->async_io.user, call->async_io.sb, get_status_name(call->async_io.status) );
121 break;
122 case APC_VIRTUAL_ALLOC:
123 fprintf( stderr, "APC_VIRTUAL_ALLOC,addr=%p,size=%lu,zero_bits=%u,op_type=%x,prot=%x",
124 call->virtual_alloc.addr, call->virtual_alloc.size,
125 call->virtual_alloc.zero_bits, call->virtual_alloc.op_type,
126 call->virtual_alloc.prot );
127 break;
128 case APC_VIRTUAL_FREE:
129 fprintf( stderr, "APC_VIRTUAL_FREE,addr=%p,size=%lu,op_type=%x",
130 call->virtual_free.addr, call->virtual_free.size,
131 call->virtual_free.op_type );
132 break;
133 case APC_VIRTUAL_QUERY:
134 fprintf( stderr, "APC_VIRTUAL_QUERY,addr=%p", call->virtual_query.addr );
135 break;
136 case APC_VIRTUAL_PROTECT:
137 fprintf( stderr, "APC_VIRTUAL_PROTECT,addr=%p,size=%lu,prot=%x",
138 call->virtual_protect.addr, call->virtual_protect.size,
139 call->virtual_protect.prot );
140 break;
141 case APC_VIRTUAL_FLUSH:
142 fprintf( stderr, "APC_VIRTUAL_FLUSH,addr=%p,size=%lu",
143 call->virtual_flush.addr, call->virtual_flush.size );
144 break;
145 case APC_VIRTUAL_LOCK:
146 fprintf( stderr, "APC_VIRTUAL_LOCK,addr=%p,size=%lu",
147 call->virtual_lock.addr, call->virtual_lock.size );
148 break;
149 case APC_VIRTUAL_UNLOCK:
150 fprintf( stderr, "APC_VIRTUAL_UNLOCK,addr=%p,size=%lu",
151 call->virtual_unlock.addr, call->virtual_unlock.size );
152 break;
153 case APC_MAP_VIEW:
154 fprintf( stderr, "APC_MAP_VIEW,handle=%p,addr=%p,size=%lu,offset=%x%08x,zero_bits=%u,alloc_type=%x,prot=%x",
155 call->map_view.handle, call->map_view.addr, call->map_view.size,
156 call->map_view.offset_high, call->map_view.offset_low, call->map_view.zero_bits,
157 call->map_view.alloc_type, call->map_view.prot );
158 break;
159 case APC_UNMAP_VIEW:
160 fprintf( stderr, "APC_UNMAP_VIEW,addr=%p", call->unmap_view.addr );
161 break;
162 case APC_CREATE_THREAD:
163 fprintf( stderr, "APC_CREATE_THREAD,func=%p,arg=%p,reserve=%lx,commit=%lx,suspend=%u",
164 call->create_thread.func, call->create_thread.arg,
165 call->create_thread.reserve, call->create_thread.commit,
166 call->create_thread.suspend );
167 break;
168 default:
169 fprintf( stderr, "type=%u", call->type );
170 break;
172 fputc( '}', stderr );
175 static void dump_apc_result( const apc_result_t *result )
177 fputc( '{', stderr );
178 switch(result->type)
180 case APC_NONE:
181 break;
182 case APC_VIRTUAL_ALLOC:
183 fprintf( stderr, "APC_VIRTUAL_ALLOC,status=%s,addr=%p,size=%lu",
184 get_status_name( result->virtual_alloc.status ),
185 result->virtual_alloc.addr, result->virtual_alloc.size );
186 break;
187 case APC_VIRTUAL_FREE:
188 fprintf( stderr, "APC_VIRTUAL_FREE,status=%s,addr=%p,size=%lu",
189 get_status_name( result->virtual_free.status ),
190 result->virtual_free.addr, result->virtual_free.size );
191 break;
192 case APC_VIRTUAL_QUERY:
193 fprintf( stderr, "APC_VIRTUAL_QUERY,status=%s,base=%p,alloc_base=%p,size=%lu,state=%x,prot=%x,alloc_prot=%x,alloc_type=%x",
194 get_status_name( result->virtual_query.status ),
195 result->virtual_query.base, result->virtual_query.alloc_base,
196 result->virtual_query.size, result->virtual_query.state,
197 result->virtual_query.prot, result->virtual_query.alloc_prot,
198 result->virtual_query.alloc_type );
199 break;
200 case APC_VIRTUAL_PROTECT:
201 fprintf( stderr, "APC_VIRTUAL_PROTECT,status=%s,addr=%p,size=%lu,prot=%x",
202 get_status_name( result->virtual_protect.status ),
203 result->virtual_protect.addr, result->virtual_protect.size,
204 result->virtual_protect.prot );
205 break;
206 case APC_VIRTUAL_FLUSH:
207 fprintf( stderr, "APC_VIRTUAL_FLUSH,status=%s,addr=%p,size=%lu",
208 get_status_name( result->virtual_flush.status ),
209 result->virtual_flush.addr, result->virtual_flush.size );
210 break;
211 case APC_VIRTUAL_LOCK:
212 fprintf( stderr, "APC_VIRTUAL_LOCK,status=%s,addr=%p,size=%lu",
213 get_status_name( result->virtual_lock.status ),
214 result->virtual_lock.addr, result->virtual_lock.size );
215 break;
216 case APC_VIRTUAL_UNLOCK:
217 fprintf( stderr, "APC_VIRTUAL_UNLOCK,status=%s,addr=%p,size=%lu",
218 get_status_name( result->virtual_unlock.status ),
219 result->virtual_unlock.addr, result->virtual_unlock.size );
220 break;
221 case APC_MAP_VIEW:
222 fprintf( stderr, "APC_MAP_VIEW,status=%s,addr=%p,size=%lu",
223 get_status_name( result->map_view.status ),
224 result->map_view.addr, result->map_view.size );
225 break;
226 case APC_UNMAP_VIEW:
227 fprintf( stderr, "APC_UNMAP_VIEW,status=%s",
228 get_status_name( result->unmap_view.status ) );
229 break;
230 case APC_CREATE_THREAD:
231 fprintf( stderr, "APC_CREATE_THREAD,status=%s,tid=%04x,handle=%p",
232 get_status_name( result->create_thread.status ),
233 result->create_thread.tid, result->create_thread.handle );
234 break;
235 default:
236 fprintf( stderr, "type=%u", result->type );
237 break;
239 fputc( '}', stderr );
242 static void dump_context( const CONTEXT *context )
244 #ifdef __i386__
245 fprintf( stderr, "{flags=%08x,eax=%08x,ebx=%08x,ecx=%08x,edx=%08x,esi=%08x,edi=%08x,"
246 "ebp=%08x,eip=%08x,esp=%08x,eflags=%08x,cs=%04x,ds=%04x,es=%04x,"
247 "fs=%04x,gs=%04x,dr0=%08x,dr1=%08x,dr2=%08x,dr3=%08x,dr6=%08x,dr7=%08x,",
248 context->ContextFlags, context->Eax, context->Ebx, context->Ecx, context->Edx,
249 context->Esi, context->Edi, context->Ebp, context->Eip, context->Esp, context->EFlags,
250 context->SegCs, context->SegDs, context->SegEs, context->SegFs, context->SegGs,
251 context->Dr0, context->Dr1, context->Dr2, context->Dr3, context->Dr6, context->Dr7 );
252 fprintf( stderr, "float=" );
253 dump_uints( (const int *)&context->FloatSave, sizeof(context->FloatSave) / sizeof(int) );
254 fprintf( stderr, "}" );
255 #else
256 dump_uints( (const int *)context, sizeof(*context) / sizeof(int) );
257 #endif
260 static void dump_exc_record( const EXCEPTION_RECORD *rec )
262 unsigned int i;
263 fprintf( stderr, "{code=%x,flags=%x,rec=%p,addr=%p,params={",
264 rec->ExceptionCode, rec->ExceptionFlags, rec->ExceptionRecord,
265 rec->ExceptionAddress );
266 for (i = 0; i < min(rec->NumberParameters,EXCEPTION_MAXIMUM_PARAMETERS); i++)
268 if (i) fputc( ',', stderr );
269 fprintf( stderr, "%lx", rec->ExceptionInformation[i] );
271 fputc( '}', stderr );
274 static void dump_varargs_ints( data_size_t size )
276 const int *data = cur_data;
277 data_size_t len = size / sizeof(*data);
279 fputc( '{', stderr );
280 while (len > 0)
282 fprintf( stderr, "%d", *data++ );
283 if (--len) fputc( ',', stderr );
285 fputc( '}', stderr );
286 remove_data( size );
289 static void dump_varargs_handles( data_size_t size )
291 const obj_handle_t *data = cur_data;
292 data_size_t len = size / sizeof(*data);
294 fputc( '{', stderr );
295 while (len > 0)
297 fprintf( stderr, "%p", *data++ );
298 if (--len) fputc( ',', stderr );
300 fputc( '}', stderr );
301 remove_data( size );
304 static void dump_varargs_user_handles( data_size_t size )
306 const user_handle_t *data = cur_data;
307 data_size_t len = size / sizeof(*data);
309 fputc( '{', stderr );
310 while (len > 0)
312 fprintf( stderr, "%p", *data++ );
313 if (--len) fputc( ',', stderr );
315 fputc( '}', stderr );
316 remove_data( size );
319 static void dump_varargs_bytes( data_size_t size )
321 const unsigned char *data = cur_data;
322 data_size_t len = size;
324 fputc( '{', stderr );
325 while (len > 0)
327 fprintf( stderr, "%02x", *data++ );
328 if (--len) fputc( ',', stderr );
330 fputc( '}', stderr );
331 remove_data( size );
334 static void dump_varargs_string( data_size_t size )
336 fprintf( stderr, "\"%.*s\"", (int)size, (const char *)cur_data );
337 remove_data( size );
340 static void dump_varargs_unicode_str( data_size_t size )
342 fprintf( stderr, "L\"" );
343 dump_strW( cur_data, size / sizeof(WCHAR), stderr, "\"\"" );
344 fputc( '\"', stderr );
345 remove_data( size );
348 static void dump_varargs_context( data_size_t size )
350 if (!size)
352 fprintf( stderr, "{}" );
353 return;
355 dump_context( cur_data );
356 remove_data( size );
359 static void dump_varargs_exc_event( data_size_t size )
361 const CONTEXT *ptr = cur_data;
363 if (!size)
365 fprintf( stderr, "{}" );
366 return;
368 fprintf( stderr, "{context=" );
369 dump_context( ptr );
370 fprintf( stderr, ",rec=" );
371 dump_exc_record( (const EXCEPTION_RECORD *)(ptr + 1) );
372 fputc( '}', stderr );
373 remove_data( size );
376 static void dump_varargs_debug_event( data_size_t size )
378 const debug_event_t *event = cur_data;
380 if (!size)
382 fprintf( stderr, "{}" );
383 return;
385 switch(event->code)
387 case EXCEPTION_DEBUG_EVENT:
388 fprintf( stderr, "{exception," );
389 dump_exc_record( &event->info.exception.record );
390 fprintf( stderr, ",first=%d}", event->info.exception.first );
391 break;
392 case CREATE_THREAD_DEBUG_EVENT:
393 fprintf( stderr, "{create_thread,thread=%p,teb=%p,start=%p}",
394 event->info.create_thread.handle, event->info.create_thread.teb,
395 event->info.create_thread.start );
396 break;
397 case CREATE_PROCESS_DEBUG_EVENT:
398 fprintf( stderr, "{create_process,file=%p,process=%p,thread=%p,base=%p,offset=%d,"
399 "size=%d,teb=%p,start=%p,name=%p,unicode=%d}",
400 event->info.create_process.file, event->info.create_process.process,
401 event->info.create_process.thread, event->info.create_process.base,
402 event->info.create_process.dbg_offset, event->info.create_process.dbg_size,
403 event->info.create_process.teb, event->info.create_process.start,
404 event->info.create_process.name, event->info.create_process.unicode );
405 break;
406 case EXIT_THREAD_DEBUG_EVENT:
407 fprintf( stderr, "{exit_thread,code=%d}", event->info.exit.exit_code );
408 break;
409 case EXIT_PROCESS_DEBUG_EVENT:
410 fprintf( stderr, "{exit_process,code=%d}", event->info.exit.exit_code );
411 break;
412 case LOAD_DLL_DEBUG_EVENT:
413 fprintf( stderr, "{load_dll,file=%p,base=%p,offset=%d,size=%d,name=%p,unicode=%d}",
414 event->info.load_dll.handle, event->info.load_dll.base,
415 event->info.load_dll.dbg_offset, event->info.load_dll.dbg_size,
416 event->info.load_dll.name, event->info.load_dll.unicode );
417 break;
418 case UNLOAD_DLL_DEBUG_EVENT:
419 fprintf( stderr, "{unload_dll,base=%p}", event->info.unload_dll.base );
420 break;
421 case OUTPUT_DEBUG_STRING_EVENT:
422 fprintf( stderr, "{output_string,data=%p,unicode=%d,len=%d}",
423 event->info.output_string.string, event->info.output_string.unicode,
424 event->info.output_string.length );
425 break;
426 case RIP_EVENT:
427 fprintf( stderr, "{rip,err=%d,type=%d}",
428 event->info.rip_info.error, event->info.rip_info.type );
429 break;
430 case 0: /* zero is the code returned on timeouts */
431 fprintf( stderr, "{}" );
432 break;
433 default:
434 fprintf( stderr, "{code=??? (%d)}", event->code );
435 break;
437 remove_data( size );
440 /* dump a unicode string contained in a buffer; helper for dump_varargs_startup_info */
441 static void dump_inline_unicode_string( const UNICODE_STRING *str, const void *data, data_size_t size )
443 size_t length = str->Length;
444 size_t offset = (size_t)str->Buffer;
446 if (offset >= size) return;
447 if (offset + length > size) length = size - offset;
448 dump_strW( (const WCHAR *)data + offset/sizeof(WCHAR), length/sizeof(WCHAR), stderr, "\"\"" );
451 static void dump_varargs_startup_info( data_size_t size )
453 const RTL_USER_PROCESS_PARAMETERS *ptr = cur_data;
454 RTL_USER_PROCESS_PARAMETERS params;
456 if (size < sizeof(params.Size))
458 fprintf( stderr, "{}" );
459 return;
461 if (size > ptr->Size) size = ptr->Size;
462 memset( &params, 0, sizeof(params) );
463 memcpy( &params, ptr, min( size, sizeof(params) ));
465 fprintf( stderr, "{AllocationSize=%x,", params.AllocationSize );
466 fprintf( stderr, "Size=%x,", params.Size );
467 fprintf( stderr, "Flags=%x,", params.Flags );
468 fprintf( stderr, "DebugFlags=%x,", params.DebugFlags );
469 fprintf( stderr, "ConsoleHandle=%p,", params.ConsoleHandle );
470 fprintf( stderr, "ConsoleFlags=%x,", params.ConsoleFlags );
471 fprintf( stderr, "hStdInput=%p,", params.hStdInput );
472 fprintf( stderr, "hStdOutput=%p,", params.hStdOutput );
473 fprintf( stderr, "hStdError=%p,", params.hStdError );
474 fprintf( stderr, "CurrentDirectory.Handle=%p,", params.CurrentDirectory.Handle );
475 fprintf( stderr, "dwX=%d,", params.dwX );
476 fprintf( stderr, "dwY=%d,", params.dwY );
477 fprintf( stderr, "dwXSize=%d,", params.dwXSize );
478 fprintf( stderr, "dwYSize=%d,", params.dwYSize );
479 fprintf( stderr, "dwXCountChars=%d,", params.dwXCountChars );
480 fprintf( stderr, "dwYCountChars=%d,", params.dwYCountChars );
481 fprintf( stderr, "dwFillAttribute=%x,", params.dwFillAttribute );
482 fprintf( stderr, "dwFlags=%x,", params.dwFlags );
483 fprintf( stderr, "wShowWindow=%x,", params.wShowWindow );
484 fprintf( stderr, "CurrentDirectory.DosPath=L\"" );
485 dump_inline_unicode_string( &params.CurrentDirectory.DosPath, cur_data, size );
486 fprintf( stderr, "\",DllPath=L\"" );
487 dump_inline_unicode_string( &params.DllPath, cur_data, size );
488 fprintf( stderr, "\",ImagePathName=L\"" );
489 dump_inline_unicode_string( &params.ImagePathName, cur_data, size );
490 fprintf( stderr, "\",CommandLine=L\"" );
491 dump_inline_unicode_string( &params.CommandLine, cur_data, size );
492 fprintf( stderr, "\",WindowTitle=L\"" );
493 dump_inline_unicode_string( &params.WindowTitle, cur_data, size );
494 fprintf( stderr, "\",Desktop=L\"" );
495 dump_inline_unicode_string( &params.Desktop, cur_data, size );
496 fprintf( stderr, "\",ShellInfo=L\"" );
497 dump_inline_unicode_string( &params.ShellInfo, cur_data, size );
498 fprintf( stderr, "\",RuntimeInfo=L\"" );
499 dump_inline_unicode_string( &params.RuntimeInfo, cur_data, size );
500 fprintf( stderr, "\"}" );
501 remove_data( size );
504 static void dump_varargs_input_records( data_size_t size )
506 const INPUT_RECORD *rec = cur_data;
507 data_size_t len = size / sizeof(*rec);
509 fputc( '{', stderr );
510 while (len > 0)
512 fprintf( stderr, "{%04x,...}", rec->EventType );
513 rec++;
514 if (--len) fputc( ',', stderr );
516 fputc( '}', stderr );
517 remove_data( size );
520 static void dump_varargs_rectangles( data_size_t size )
522 const rectangle_t *rect = cur_data;
523 data_size_t len = size / sizeof(*rect);
525 fputc( '{', stderr );
526 while (len > 0)
528 dump_rectangle( rect++ );
529 if (--len) fputc( ',', stderr );
531 fputc( '}', stderr );
532 remove_data( size );
535 static void dump_varargs_message_data( data_size_t size )
537 /* FIXME: dump the structured data */
538 dump_varargs_bytes( size );
541 static void dump_varargs_properties( data_size_t size )
543 const property_data_t *prop = cur_data;
544 data_size_t len = size / sizeof(*prop);
546 fputc( '{', stderr );
547 while (len > 0)
549 fprintf( stderr, "{atom=%04x,str=%d,handle=%p}",
550 prop->atom, prop->string, prop->handle );
551 prop++;
552 if (--len) fputc( ',', stderr );
554 fputc( '}', stderr );
555 remove_data( size );
558 static void dump_varargs_LUID_AND_ATTRIBUTES( data_size_t size )
560 const LUID_AND_ATTRIBUTES *lat = cur_data;
561 data_size_t len = size / sizeof(*lat);
563 fputc( '{', stderr );
564 while (len > 0)
566 fprintf( stderr, "{luid=%08x%08x,attr=%x}",
567 lat->Luid.HighPart, lat->Luid.LowPart, lat->Attributes );
568 lat++;
569 if (--len) fputc( ',', stderr );
571 fputc( '}', stderr );
572 remove_data( size );
575 static void dump_inline_sid( const SID *sid, data_size_t size )
577 DWORD i;
579 /* security check */
580 if ((FIELD_OFFSET(SID, SubAuthority[0]) > size) ||
581 (FIELD_OFFSET(SID, SubAuthority[sid->SubAuthorityCount]) > size))
583 fprintf( stderr, "<invalid sid>" );
584 return;
587 fputc( '{', stderr );
588 fprintf( stderr, "S-%u-%u", sid->Revision, MAKELONG(
589 MAKEWORD( sid->IdentifierAuthority.Value[5],
590 sid->IdentifierAuthority.Value[4] ),
591 MAKEWORD( sid->IdentifierAuthority.Value[3],
592 sid->IdentifierAuthority.Value[2] ) ) );
593 for (i = 0; i < sid->SubAuthorityCount; i++)
594 fprintf( stderr, "-%u", sid->SubAuthority[i] );
595 fputc( '}', stderr );
598 static void dump_varargs_SID( data_size_t size )
600 const SID *sid = cur_data;
601 dump_inline_sid( sid, size );
602 remove_data( size );
605 static void dump_inline_acl( const ACL *acl, data_size_t size )
607 const ACE_HEADER *ace;
608 ULONG i;
609 fputc( '{', stderr );
611 if (size)
613 if (size < sizeof(ACL))
615 fprintf( stderr, "<invalid acl>}\n" );
616 return;
618 size -= sizeof(ACL);
619 ace = (const ACE_HEADER *)(acl + 1);
620 for (i = 0; i < acl->AceCount; i++)
622 const SID *sid = NULL;
623 data_size_t sid_size = 0;
625 if (size < sizeof(ACE_HEADER))
626 return;
627 if (size < ace->AceSize)
628 return;
629 size -= ace->AceSize;
630 if (i != 0) fputc( ',', stderr );
631 fprintf( stderr, "{AceType=" );
632 switch (ace->AceType)
634 case ACCESS_DENIED_ACE_TYPE:
635 sid = (const SID *)&((const ACCESS_DENIED_ACE *)ace)->SidStart;
636 sid_size = ace->AceSize - FIELD_OFFSET(ACCESS_DENIED_ACE, SidStart);
637 fprintf( stderr, "ACCESS_DENIED_ACE_TYPE,Mask=%x",
638 ((const ACCESS_DENIED_ACE *)ace)->Mask );
639 break;
640 case ACCESS_ALLOWED_ACE_TYPE:
641 sid = (const SID *)&((const ACCESS_ALLOWED_ACE *)ace)->SidStart;
642 sid_size = ace->AceSize - FIELD_OFFSET(ACCESS_ALLOWED_ACE, SidStart);
643 fprintf( stderr, "ACCESS_ALLOWED_ACE_TYPE,Mask=%x",
644 ((const ACCESS_ALLOWED_ACE *)ace)->Mask );
645 break;
646 case SYSTEM_AUDIT_ACE_TYPE:
647 sid = (const SID *)&((const SYSTEM_AUDIT_ACE *)ace)->SidStart;
648 sid_size = ace->AceSize - FIELD_OFFSET(SYSTEM_AUDIT_ACE, SidStart);
649 fprintf( stderr, "SYSTEM_AUDIT_ACE_TYPE,Mask=%x",
650 ((const SYSTEM_AUDIT_ACE *)ace)->Mask );
651 break;
652 case SYSTEM_ALARM_ACE_TYPE:
653 sid = (const SID *)&((const SYSTEM_ALARM_ACE *)ace)->SidStart;
654 sid_size = ace->AceSize - FIELD_OFFSET(SYSTEM_ALARM_ACE, SidStart);
655 fprintf( stderr, "SYSTEM_ALARM_ACE_TYPE,Mask=%x",
656 ((const SYSTEM_ALARM_ACE *)ace)->Mask );
657 break;
658 default:
659 fprintf( stderr, "unknown<%d>", ace->AceType );
660 break;
662 fprintf( stderr, ",AceFlags=%x,Sid=", ace->AceFlags );
663 if (sid)
664 dump_inline_sid( sid, sid_size );
665 ace = (const ACE_HEADER *)((const char *)ace + ace->AceSize);
666 fputc( '}', stderr );
669 fputc( '}', stderr );
672 static void dump_inline_security_descriptor( const struct security_descriptor *sd, data_size_t size )
674 fputc( '{', stderr );
675 if (size >= sizeof(struct security_descriptor))
677 size_t offset = sizeof(struct security_descriptor);
678 fprintf( stderr, "control=%08x", sd->control );
679 fprintf( stderr, ",owner=" );
680 if ((sd->owner_len > FIELD_OFFSET(SID, SubAuthority[255])) || (offset + sd->owner_len > size))
681 return;
682 dump_inline_sid( (const SID *)((const char *)sd + offset), sd->owner_len );
683 offset += sd->owner_len;
684 fprintf( stderr, ",group=" );
685 if ((sd->group_len > FIELD_OFFSET(SID, SubAuthority[255])) || (offset + sd->group_len > size))
686 return;
687 dump_inline_sid( (const SID *)((const char *)sd + offset), sd->group_len );
688 offset += sd->group_len;
689 fprintf( stderr, ",sacl=" );
690 if ((sd->sacl_len >= MAX_ACL_LEN) || (offset + sd->sacl_len > size))
691 return;
692 dump_inline_acl( (const ACL *)((const char *)sd + offset), sd->sacl_len );
693 offset += sd->sacl_len;
694 fprintf( stderr, ",dacl=" );
695 if ((sd->dacl_len >= MAX_ACL_LEN) || (offset + sd->dacl_len > size))
696 return;
697 dump_inline_acl( (const ACL *)((const char *)sd + offset), sd->dacl_len );
698 offset += sd->dacl_len;
700 fputc( '}', stderr );
703 static void dump_varargs_security_descriptor( data_size_t size )
705 const struct security_descriptor *sd = cur_data;
706 dump_inline_security_descriptor( sd, size );
707 remove_data( size );
710 static void dump_varargs_token_groups( data_size_t size )
712 const struct token_groups *tg = cur_data;
713 fputc( '{', stderr );
714 if (size >= sizeof(struct token_groups))
716 size_t offset = sizeof(*tg);
717 fprintf( stderr, "count=%08x,", tg->count );
718 if (tg->count * sizeof(unsigned int) <= size)
720 unsigned int i;
721 const unsigned int *attr = (const unsigned int *)(tg + 1);
723 offset += tg->count * sizeof(unsigned int);
725 fputc( '[', stderr );
726 for (i = 0; i < tg->count; i++)
728 const SID *sid = (const SID *)((const char *)cur_data + offset);
729 if (i != 0)
730 fputc( ',', stderr );
731 fputc( '{', stderr );
732 fprintf( stderr, "attributes=%08x", attr[i] );
733 fprintf( stderr, ",sid=" );
734 dump_inline_sid( sid, size - offset );
735 if ((offset + FIELD_OFFSET(SID, SubAuthority[0]) > size) ||
736 (offset + FIELD_OFFSET(SID, SubAuthority[sid->SubAuthorityCount]) > size))
737 break;
738 offset += FIELD_OFFSET(SID, SubAuthority[sid->SubAuthorityCount]);
739 fputc( '}', stderr );
741 fputc( ']', stderr );
744 fputc( '}', stderr );
747 typedef void (*dump_func)( const void *req );
749 /* Everything below this line is generated automatically by tools/make_requests */
750 /* ### make_requests begin ### */
752 static void dump_new_process_request( const struct new_process_request *req )
754 fprintf( stderr, " inherit_all=%d,", req->inherit_all );
755 fprintf( stderr, " create_flags=%08x,", req->create_flags );
756 fprintf( stderr, " socket_fd=%d,", req->socket_fd );
757 fprintf( stderr, " exe_file=%p,", req->exe_file );
758 fprintf( stderr, " hstdin=%p,", req->hstdin );
759 fprintf( stderr, " hstdout=%p,", req->hstdout );
760 fprintf( stderr, " hstderr=%p,", req->hstderr );
761 fprintf( stderr, " process_access=%08x,", req->process_access );
762 fprintf( stderr, " process_attr=%08x,", req->process_attr );
763 fprintf( stderr, " thread_access=%08x,", req->thread_access );
764 fprintf( stderr, " thread_attr=%08x,", req->thread_attr );
765 fprintf( stderr, " info=" );
766 dump_varargs_startup_info( cur_size );
767 fputc( ',', stderr );
768 fprintf( stderr, " env=" );
769 dump_varargs_unicode_str( cur_size );
772 static void dump_new_process_reply( const struct new_process_reply *req )
774 fprintf( stderr, " info=%p,", req->info );
775 fprintf( stderr, " pid=%04x,", req->pid );
776 fprintf( stderr, " phandle=%p,", req->phandle );
777 fprintf( stderr, " tid=%04x,", req->tid );
778 fprintf( stderr, " thandle=%p", req->thandle );
781 static void dump_get_new_process_info_request( const struct get_new_process_info_request *req )
783 fprintf( stderr, " info=%p", req->info );
786 static void dump_get_new_process_info_reply( const struct get_new_process_info_reply *req )
788 fprintf( stderr, " success=%d,", req->success );
789 fprintf( stderr, " exit_code=%d", req->exit_code );
792 static void dump_new_thread_request( const struct new_thread_request *req )
794 fprintf( stderr, " access=%08x,", req->access );
795 fprintf( stderr, " attributes=%08x,", req->attributes );
796 fprintf( stderr, " suspend=%d,", req->suspend );
797 fprintf( stderr, " request_fd=%d", req->request_fd );
800 static void dump_new_thread_reply( const struct new_thread_reply *req )
802 fprintf( stderr, " tid=%04x,", req->tid );
803 fprintf( stderr, " handle=%p", req->handle );
806 static void dump_get_startup_info_request( const struct get_startup_info_request *req )
810 static void dump_get_startup_info_reply( const struct get_startup_info_reply *req )
812 fprintf( stderr, " exe_file=%p,", req->exe_file );
813 fprintf( stderr, " hstdin=%p,", req->hstdin );
814 fprintf( stderr, " hstdout=%p,", req->hstdout );
815 fprintf( stderr, " hstderr=%p,", req->hstderr );
816 fprintf( stderr, " info=" );
817 dump_varargs_startup_info( cur_size );
818 fputc( ',', stderr );
819 fprintf( stderr, " env=" );
820 dump_varargs_unicode_str( cur_size );
823 static void dump_init_process_done_request( const struct init_process_done_request *req )
825 fprintf( stderr, " module=%p,", req->module );
826 fprintf( stderr, " entry=%p,", req->entry );
827 fprintf( stderr, " gui=%d", req->gui );
830 static void dump_init_thread_request( const struct init_thread_request *req )
832 fprintf( stderr, " unix_pid=%d,", req->unix_pid );
833 fprintf( stderr, " unix_tid=%d,", req->unix_tid );
834 fprintf( stderr, " debug_level=%d,", req->debug_level );
835 fprintf( stderr, " teb=%p,", req->teb );
836 fprintf( stderr, " peb=%p,", req->peb );
837 fprintf( stderr, " entry=%p,", req->entry );
838 fprintf( stderr, " ldt_copy=%p,", req->ldt_copy );
839 fprintf( stderr, " reply_fd=%d,", req->reply_fd );
840 fprintf( stderr, " wait_fd=%d", req->wait_fd );
843 static void dump_init_thread_reply( const struct init_thread_reply *req )
845 fprintf( stderr, " pid=%04x,", req->pid );
846 fprintf( stderr, " tid=%04x,", req->tid );
847 fprintf( stderr, " info_size=%u,", req->info_size );
848 fprintf( stderr, " server_start=" );
849 dump_abs_time( &req->server_start );
850 fprintf( stderr, "," );
851 fprintf( stderr, " version=%d", req->version );
854 static void dump_terminate_process_request( const struct terminate_process_request *req )
856 fprintf( stderr, " handle=%p,", req->handle );
857 fprintf( stderr, " exit_code=%d", req->exit_code );
860 static void dump_terminate_process_reply( const struct terminate_process_reply *req )
862 fprintf( stderr, " self=%d", req->self );
865 static void dump_terminate_thread_request( const struct terminate_thread_request *req )
867 fprintf( stderr, " handle=%p,", req->handle );
868 fprintf( stderr, " exit_code=%d", req->exit_code );
871 static void dump_terminate_thread_reply( const struct terminate_thread_reply *req )
873 fprintf( stderr, " self=%d,", req->self );
874 fprintf( stderr, " last=%d", req->last );
877 static void dump_get_process_info_request( const struct get_process_info_request *req )
879 fprintf( stderr, " handle=%p", req->handle );
882 static void dump_get_process_info_reply( const struct get_process_info_reply *req )
884 fprintf( stderr, " pid=%04x,", req->pid );
885 fprintf( stderr, " ppid=%04x,", req->ppid );
886 fprintf( stderr, " exit_code=%d,", req->exit_code );
887 fprintf( stderr, " priority=%d,", req->priority );
888 fprintf( stderr, " affinity=%d,", req->affinity );
889 fprintf( stderr, " peb=%p,", req->peb );
890 fprintf( stderr, " start_time=" );
891 dump_abs_time( &req->start_time );
892 fprintf( stderr, "," );
893 fprintf( stderr, " end_time=" );
894 dump_abs_time( &req->end_time );
897 static void dump_set_process_info_request( const struct set_process_info_request *req )
899 fprintf( stderr, " handle=%p,", req->handle );
900 fprintf( stderr, " mask=%d,", req->mask );
901 fprintf( stderr, " priority=%d,", req->priority );
902 fprintf( stderr, " affinity=%d", req->affinity );
905 static void dump_get_thread_info_request( const struct get_thread_info_request *req )
907 fprintf( stderr, " handle=%p,", req->handle );
908 fprintf( stderr, " tid_in=%04x", req->tid_in );
911 static void dump_get_thread_info_reply( const struct get_thread_info_reply *req )
913 fprintf( stderr, " pid=%04x,", req->pid );
914 fprintf( stderr, " tid=%04x,", req->tid );
915 fprintf( stderr, " teb=%p,", req->teb );
916 fprintf( stderr, " exit_code=%d,", req->exit_code );
917 fprintf( stderr, " priority=%d,", req->priority );
918 fprintf( stderr, " affinity=%d,", req->affinity );
919 fprintf( stderr, " creation_time=" );
920 dump_abs_time( &req->creation_time );
921 fprintf( stderr, "," );
922 fprintf( stderr, " exit_time=" );
923 dump_abs_time( &req->exit_time );
924 fprintf( stderr, "," );
925 fprintf( stderr, " last=%d", req->last );
928 static void dump_set_thread_info_request( const struct set_thread_info_request *req )
930 fprintf( stderr, " handle=%p,", req->handle );
931 fprintf( stderr, " mask=%d,", req->mask );
932 fprintf( stderr, " priority=%d,", req->priority );
933 fprintf( stderr, " affinity=%d,", req->affinity );
934 fprintf( stderr, " token=%p", req->token );
937 static void dump_get_dll_info_request( const struct get_dll_info_request *req )
939 fprintf( stderr, " handle=%p,", req->handle );
940 fprintf( stderr, " base_address=%p", req->base_address );
943 static void dump_get_dll_info_reply( const struct get_dll_info_reply *req )
945 fprintf( stderr, " size=%lu,", (unsigned long)req->size );
946 fprintf( stderr, " entry_point=%p,", req->entry_point );
947 fprintf( stderr, " filename=" );
948 dump_varargs_unicode_str( cur_size );
951 static void dump_suspend_thread_request( const struct suspend_thread_request *req )
953 fprintf( stderr, " handle=%p", req->handle );
956 static void dump_suspend_thread_reply( const struct suspend_thread_reply *req )
958 fprintf( stderr, " count=%d", req->count );
961 static void dump_resume_thread_request( const struct resume_thread_request *req )
963 fprintf( stderr, " handle=%p", req->handle );
966 static void dump_resume_thread_reply( const struct resume_thread_reply *req )
968 fprintf( stderr, " count=%d", req->count );
971 static void dump_load_dll_request( const struct load_dll_request *req )
973 fprintf( stderr, " handle=%p,", req->handle );
974 fprintf( stderr, " base=%p,", req->base );
975 fprintf( stderr, " size=%lu,", (unsigned long)req->size );
976 fprintf( stderr, " dbg_offset=%d,", req->dbg_offset );
977 fprintf( stderr, " dbg_size=%d,", req->dbg_size );
978 fprintf( stderr, " name=%p,", req->name );
979 fprintf( stderr, " filename=" );
980 dump_varargs_unicode_str( cur_size );
983 static void dump_unload_dll_request( const struct unload_dll_request *req )
985 fprintf( stderr, " base=%p", req->base );
988 static void dump_queue_apc_request( const struct queue_apc_request *req )
990 fprintf( stderr, " thread=%p,", req->thread );
991 fprintf( stderr, " process=%p,", req->process );
992 fprintf( stderr, " call=" );
993 dump_apc_call( &req->call );
996 static void dump_queue_apc_reply( const struct queue_apc_reply *req )
998 fprintf( stderr, " handle=%p,", req->handle );
999 fprintf( stderr, " self=%d", req->self );
1002 static void dump_get_apc_request( const struct get_apc_request *req )
1004 fprintf( stderr, " alertable=%d,", req->alertable );
1005 fprintf( stderr, " prev=%p,", req->prev );
1006 fprintf( stderr, " result=" );
1007 dump_apc_result( &req->result );
1010 static void dump_get_apc_reply( const struct get_apc_reply *req )
1012 fprintf( stderr, " handle=%p,", req->handle );
1013 fprintf( stderr, " call=" );
1014 dump_apc_call( &req->call );
1017 static void dump_get_apc_result_request( const struct get_apc_result_request *req )
1019 fprintf( stderr, " handle=%p", req->handle );
1022 static void dump_get_apc_result_reply( const struct get_apc_result_reply *req )
1024 fprintf( stderr, " result=" );
1025 dump_apc_result( &req->result );
1028 static void dump_close_handle_request( const struct close_handle_request *req )
1030 fprintf( stderr, " handle=%p", req->handle );
1033 static void dump_set_handle_info_request( const struct set_handle_info_request *req )
1035 fprintf( stderr, " handle=%p,", req->handle );
1036 fprintf( stderr, " flags=%d,", req->flags );
1037 fprintf( stderr, " mask=%d", req->mask );
1040 static void dump_set_handle_info_reply( const struct set_handle_info_reply *req )
1042 fprintf( stderr, " old_flags=%d", req->old_flags );
1045 static void dump_dup_handle_request( const struct dup_handle_request *req )
1047 fprintf( stderr, " src_process=%p,", req->src_process );
1048 fprintf( stderr, " src_handle=%p,", req->src_handle );
1049 fprintf( stderr, " dst_process=%p,", req->dst_process );
1050 fprintf( stderr, " access=%08x,", req->access );
1051 fprintf( stderr, " attributes=%08x,", req->attributes );
1052 fprintf( stderr, " options=%08x", req->options );
1055 static void dump_dup_handle_reply( const struct dup_handle_reply *req )
1057 fprintf( stderr, " handle=%p,", req->handle );
1058 fprintf( stderr, " self=%d,", req->self );
1059 fprintf( stderr, " closed=%d", req->closed );
1062 static void dump_open_process_request( const struct open_process_request *req )
1064 fprintf( stderr, " pid=%04x,", req->pid );
1065 fprintf( stderr, " access=%08x,", req->access );
1066 fprintf( stderr, " attributes=%08x", req->attributes );
1069 static void dump_open_process_reply( const struct open_process_reply *req )
1071 fprintf( stderr, " handle=%p", req->handle );
1074 static void dump_open_thread_request( const struct open_thread_request *req )
1076 fprintf( stderr, " tid=%04x,", req->tid );
1077 fprintf( stderr, " access=%08x,", req->access );
1078 fprintf( stderr, " attributes=%08x", req->attributes );
1081 static void dump_open_thread_reply( const struct open_thread_reply *req )
1083 fprintf( stderr, " handle=%p", req->handle );
1086 static void dump_select_request( const struct select_request *req )
1088 fprintf( stderr, " flags=%d,", req->flags );
1089 fprintf( stderr, " cookie=%p,", req->cookie );
1090 fprintf( stderr, " signal=%p,", req->signal );
1091 fprintf( stderr, " timeout=" );
1092 dump_abs_time( &req->timeout );
1093 fprintf( stderr, "," );
1094 fprintf( stderr, " handles=" );
1095 dump_varargs_handles( cur_size );
1098 static void dump_create_event_request( const struct create_event_request *req )
1100 fprintf( stderr, " access=%08x,", req->access );
1101 fprintf( stderr, " attributes=%08x,", req->attributes );
1102 fprintf( stderr, " rootdir=%p,", req->rootdir );
1103 fprintf( stderr, " manual_reset=%d,", req->manual_reset );
1104 fprintf( stderr, " initial_state=%d,", req->initial_state );
1105 fprintf( stderr, " name=" );
1106 dump_varargs_unicode_str( cur_size );
1109 static void dump_create_event_reply( const struct create_event_reply *req )
1111 fprintf( stderr, " handle=%p", req->handle );
1114 static void dump_event_op_request( const struct event_op_request *req )
1116 fprintf( stderr, " handle=%p,", req->handle );
1117 fprintf( stderr, " op=%d", req->op );
1120 static void dump_open_event_request( const struct open_event_request *req )
1122 fprintf( stderr, " access=%08x,", req->access );
1123 fprintf( stderr, " attributes=%08x,", req->attributes );
1124 fprintf( stderr, " rootdir=%p,", req->rootdir );
1125 fprintf( stderr, " name=" );
1126 dump_varargs_unicode_str( cur_size );
1129 static void dump_open_event_reply( const struct open_event_reply *req )
1131 fprintf( stderr, " handle=%p", req->handle );
1134 static void dump_create_mutex_request( const struct create_mutex_request *req )
1136 fprintf( stderr, " access=%08x,", req->access );
1137 fprintf( stderr, " attributes=%08x,", req->attributes );
1138 fprintf( stderr, " rootdir=%p,", req->rootdir );
1139 fprintf( stderr, " owned=%d,", req->owned );
1140 fprintf( stderr, " name=" );
1141 dump_varargs_unicode_str( cur_size );
1144 static void dump_create_mutex_reply( const struct create_mutex_reply *req )
1146 fprintf( stderr, " handle=%p", req->handle );
1149 static void dump_release_mutex_request( const struct release_mutex_request *req )
1151 fprintf( stderr, " handle=%p", req->handle );
1154 static void dump_release_mutex_reply( const struct release_mutex_reply *req )
1156 fprintf( stderr, " prev_count=%08x", req->prev_count );
1159 static void dump_open_mutex_request( const struct open_mutex_request *req )
1161 fprintf( stderr, " access=%08x,", req->access );
1162 fprintf( stderr, " attributes=%08x,", req->attributes );
1163 fprintf( stderr, " rootdir=%p,", req->rootdir );
1164 fprintf( stderr, " name=" );
1165 dump_varargs_unicode_str( cur_size );
1168 static void dump_open_mutex_reply( const struct open_mutex_reply *req )
1170 fprintf( stderr, " handle=%p", req->handle );
1173 static void dump_create_semaphore_request( const struct create_semaphore_request *req )
1175 fprintf( stderr, " access=%08x,", req->access );
1176 fprintf( stderr, " attributes=%08x,", req->attributes );
1177 fprintf( stderr, " rootdir=%p,", req->rootdir );
1178 fprintf( stderr, " initial=%08x,", req->initial );
1179 fprintf( stderr, " max=%08x,", req->max );
1180 fprintf( stderr, " name=" );
1181 dump_varargs_unicode_str( cur_size );
1184 static void dump_create_semaphore_reply( const struct create_semaphore_reply *req )
1186 fprintf( stderr, " handle=%p", req->handle );
1189 static void dump_release_semaphore_request( const struct release_semaphore_request *req )
1191 fprintf( stderr, " handle=%p,", req->handle );
1192 fprintf( stderr, " count=%08x", req->count );
1195 static void dump_release_semaphore_reply( const struct release_semaphore_reply *req )
1197 fprintf( stderr, " prev_count=%08x", req->prev_count );
1200 static void dump_open_semaphore_request( const struct open_semaphore_request *req )
1202 fprintf( stderr, " access=%08x,", req->access );
1203 fprintf( stderr, " attributes=%08x,", req->attributes );
1204 fprintf( stderr, " rootdir=%p,", req->rootdir );
1205 fprintf( stderr, " name=" );
1206 dump_varargs_unicode_str( cur_size );
1209 static void dump_open_semaphore_reply( const struct open_semaphore_reply *req )
1211 fprintf( stderr, " handle=%p", req->handle );
1214 static void dump_create_file_request( const struct create_file_request *req )
1216 fprintf( stderr, " access=%08x,", req->access );
1217 fprintf( stderr, " attributes=%08x,", req->attributes );
1218 fprintf( stderr, " sharing=%08x,", req->sharing );
1219 fprintf( stderr, " create=%d,", req->create );
1220 fprintf( stderr, " options=%08x,", req->options );
1221 fprintf( stderr, " attrs=%08x,", req->attrs );
1222 fprintf( stderr, " filename=" );
1223 dump_varargs_string( cur_size );
1226 static void dump_create_file_reply( const struct create_file_reply *req )
1228 fprintf( stderr, " handle=%p", req->handle );
1231 static void dump_open_file_object_request( const struct open_file_object_request *req )
1233 fprintf( stderr, " access=%08x,", req->access );
1234 fprintf( stderr, " attributes=%08x,", req->attributes );
1235 fprintf( stderr, " rootdir=%p,", req->rootdir );
1236 fprintf( stderr, " sharing=%08x,", req->sharing );
1237 fprintf( stderr, " filename=" );
1238 dump_varargs_unicode_str( cur_size );
1241 static void dump_open_file_object_reply( const struct open_file_object_reply *req )
1243 fprintf( stderr, " handle=%p", req->handle );
1246 static void dump_alloc_file_handle_request( const struct alloc_file_handle_request *req )
1248 fprintf( stderr, " access=%08x,", req->access );
1249 fprintf( stderr, " attributes=%08x,", req->attributes );
1250 fprintf( stderr, " fd=%d", req->fd );
1253 static void dump_alloc_file_handle_reply( const struct alloc_file_handle_reply *req )
1255 fprintf( stderr, " handle=%p", req->handle );
1258 static void dump_get_handle_fd_request( const struct get_handle_fd_request *req )
1260 fprintf( stderr, " handle=%p,", req->handle );
1261 fprintf( stderr, " access=%08x,", req->access );
1262 fprintf( stderr, " cached=%d", req->cached );
1265 static void dump_get_handle_fd_reply( const struct get_handle_fd_reply *req )
1267 fprintf( stderr, " type=%d,", req->type );
1268 fprintf( stderr, " flags=%d", req->flags );
1271 static void dump_flush_file_request( const struct flush_file_request *req )
1273 fprintf( stderr, " handle=%p", req->handle );
1276 static void dump_flush_file_reply( const struct flush_file_reply *req )
1278 fprintf( stderr, " event=%p", req->event );
1281 static void dump_lock_file_request( const struct lock_file_request *req )
1283 fprintf( stderr, " handle=%p,", req->handle );
1284 fprintf( stderr, " offset_low=%08x,", req->offset_low );
1285 fprintf( stderr, " offset_high=%08x,", req->offset_high );
1286 fprintf( stderr, " count_low=%08x,", req->count_low );
1287 fprintf( stderr, " count_high=%08x,", req->count_high );
1288 fprintf( stderr, " shared=%d,", req->shared );
1289 fprintf( stderr, " wait=%d", req->wait );
1292 static void dump_lock_file_reply( const struct lock_file_reply *req )
1294 fprintf( stderr, " handle=%p,", req->handle );
1295 fprintf( stderr, " overlapped=%d", req->overlapped );
1298 static void dump_unlock_file_request( const struct unlock_file_request *req )
1300 fprintf( stderr, " handle=%p,", req->handle );
1301 fprintf( stderr, " offset_low=%08x,", req->offset_low );
1302 fprintf( stderr, " offset_high=%08x,", req->offset_high );
1303 fprintf( stderr, " count_low=%08x,", req->count_low );
1304 fprintf( stderr, " count_high=%08x", req->count_high );
1307 static void dump_unmount_device_request( const struct unmount_device_request *req )
1309 fprintf( stderr, " handle=%p", req->handle );
1312 static void dump_create_socket_request( const struct create_socket_request *req )
1314 fprintf( stderr, " access=%08x,", req->access );
1315 fprintf( stderr, " attributes=%08x,", req->attributes );
1316 fprintf( stderr, " family=%d,", req->family );
1317 fprintf( stderr, " type=%d,", req->type );
1318 fprintf( stderr, " protocol=%d,", req->protocol );
1319 fprintf( stderr, " flags=%08x", req->flags );
1322 static void dump_create_socket_reply( const struct create_socket_reply *req )
1324 fprintf( stderr, " handle=%p", req->handle );
1327 static void dump_accept_socket_request( const struct accept_socket_request *req )
1329 fprintf( stderr, " lhandle=%p,", req->lhandle );
1330 fprintf( stderr, " access=%08x,", req->access );
1331 fprintf( stderr, " attributes=%08x", req->attributes );
1334 static void dump_accept_socket_reply( const struct accept_socket_reply *req )
1336 fprintf( stderr, " handle=%p", req->handle );
1339 static void dump_set_socket_event_request( const struct set_socket_event_request *req )
1341 fprintf( stderr, " handle=%p,", req->handle );
1342 fprintf( stderr, " mask=%08x,", req->mask );
1343 fprintf( stderr, " event=%p,", req->event );
1344 fprintf( stderr, " window=%p,", req->window );
1345 fprintf( stderr, " msg=%08x", req->msg );
1348 static void dump_get_socket_event_request( const struct get_socket_event_request *req )
1350 fprintf( stderr, " handle=%p,", req->handle );
1351 fprintf( stderr, " service=%d,", req->service );
1352 fprintf( stderr, " c_event=%p", req->c_event );
1355 static void dump_get_socket_event_reply( const struct get_socket_event_reply *req )
1357 fprintf( stderr, " mask=%08x,", req->mask );
1358 fprintf( stderr, " pmask=%08x,", req->pmask );
1359 fprintf( stderr, " state=%08x,", req->state );
1360 fprintf( stderr, " errors=" );
1361 dump_varargs_ints( cur_size );
1364 static void dump_enable_socket_event_request( const struct enable_socket_event_request *req )
1366 fprintf( stderr, " handle=%p,", req->handle );
1367 fprintf( stderr, " mask=%08x,", req->mask );
1368 fprintf( stderr, " sstate=%08x,", req->sstate );
1369 fprintf( stderr, " cstate=%08x", req->cstate );
1372 static void dump_set_socket_deferred_request( const struct set_socket_deferred_request *req )
1374 fprintf( stderr, " handle=%p,", req->handle );
1375 fprintf( stderr, " deferred=%p", req->deferred );
1378 static void dump_alloc_console_request( const struct alloc_console_request *req )
1380 fprintf( stderr, " access=%08x,", req->access );
1381 fprintf( stderr, " attributes=%08x,", req->attributes );
1382 fprintf( stderr, " pid=%04x", req->pid );
1385 static void dump_alloc_console_reply( const struct alloc_console_reply *req )
1387 fprintf( stderr, " handle_in=%p,", req->handle_in );
1388 fprintf( stderr, " event=%p", req->event );
1391 static void dump_free_console_request( const struct free_console_request *req )
1395 static void dump_get_console_renderer_events_request( const struct get_console_renderer_events_request *req )
1397 fprintf( stderr, " handle=%p", req->handle );
1400 static void dump_get_console_renderer_events_reply( const struct get_console_renderer_events_reply *req )
1402 fprintf( stderr, " data=" );
1403 dump_varargs_bytes( cur_size );
1406 static void dump_open_console_request( const struct open_console_request *req )
1408 fprintf( stderr, " from=%p,", req->from );
1409 fprintf( stderr, " access=%08x,", req->access );
1410 fprintf( stderr, " attributes=%08x,", req->attributes );
1411 fprintf( stderr, " share=%d", req->share );
1414 static void dump_open_console_reply( const struct open_console_reply *req )
1416 fprintf( stderr, " handle=%p", req->handle );
1419 static void dump_get_console_wait_event_request( const struct get_console_wait_event_request *req )
1423 static void dump_get_console_wait_event_reply( const struct get_console_wait_event_reply *req )
1425 fprintf( stderr, " handle=%p", req->handle );
1428 static void dump_get_console_mode_request( const struct get_console_mode_request *req )
1430 fprintf( stderr, " handle=%p", req->handle );
1433 static void dump_get_console_mode_reply( const struct get_console_mode_reply *req )
1435 fprintf( stderr, " mode=%d", req->mode );
1438 static void dump_set_console_mode_request( const struct set_console_mode_request *req )
1440 fprintf( stderr, " handle=%p,", req->handle );
1441 fprintf( stderr, " mode=%d", req->mode );
1444 static void dump_set_console_input_info_request( const struct set_console_input_info_request *req )
1446 fprintf( stderr, " handle=%p,", req->handle );
1447 fprintf( stderr, " mask=%d,", req->mask );
1448 fprintf( stderr, " active_sb=%p,", req->active_sb );
1449 fprintf( stderr, " history_mode=%d,", req->history_mode );
1450 fprintf( stderr, " history_size=%d,", req->history_size );
1451 fprintf( stderr, " edition_mode=%d,", req->edition_mode );
1452 fprintf( stderr, " title=" );
1453 dump_varargs_unicode_str( cur_size );
1456 static void dump_get_console_input_info_request( const struct get_console_input_info_request *req )
1458 fprintf( stderr, " handle=%p", req->handle );
1461 static void dump_get_console_input_info_reply( const struct get_console_input_info_reply *req )
1463 fprintf( stderr, " history_mode=%d,", req->history_mode );
1464 fprintf( stderr, " history_size=%d,", req->history_size );
1465 fprintf( stderr, " history_index=%d,", req->history_index );
1466 fprintf( stderr, " edition_mode=%d,", req->edition_mode );
1467 fprintf( stderr, " title=" );
1468 dump_varargs_unicode_str( cur_size );
1471 static void dump_append_console_input_history_request( const struct append_console_input_history_request *req )
1473 fprintf( stderr, " handle=%p,", req->handle );
1474 fprintf( stderr, " line=" );
1475 dump_varargs_unicode_str( cur_size );
1478 static void dump_get_console_input_history_request( const struct get_console_input_history_request *req )
1480 fprintf( stderr, " handle=%p,", req->handle );
1481 fprintf( stderr, " index=%d", req->index );
1484 static void dump_get_console_input_history_reply( const struct get_console_input_history_reply *req )
1486 fprintf( stderr, " total=%d,", req->total );
1487 fprintf( stderr, " line=" );
1488 dump_varargs_unicode_str( cur_size );
1491 static void dump_create_console_output_request( const struct create_console_output_request *req )
1493 fprintf( stderr, " handle_in=%p,", req->handle_in );
1494 fprintf( stderr, " access=%08x,", req->access );
1495 fprintf( stderr, " attributes=%08x,", req->attributes );
1496 fprintf( stderr, " share=%08x", req->share );
1499 static void dump_create_console_output_reply( const struct create_console_output_reply *req )
1501 fprintf( stderr, " handle_out=%p", req->handle_out );
1504 static void dump_set_console_output_info_request( const struct set_console_output_info_request *req )
1506 fprintf( stderr, " handle=%p,", req->handle );
1507 fprintf( stderr, " mask=%d,", req->mask );
1508 fprintf( stderr, " cursor_size=%d,", req->cursor_size );
1509 fprintf( stderr, " cursor_visible=%d,", req->cursor_visible );
1510 fprintf( stderr, " cursor_x=%d,", req->cursor_x );
1511 fprintf( stderr, " cursor_y=%d,", req->cursor_y );
1512 fprintf( stderr, " width=%d,", req->width );
1513 fprintf( stderr, " height=%d,", req->height );
1514 fprintf( stderr, " attr=%d,", req->attr );
1515 fprintf( stderr, " win_left=%d,", req->win_left );
1516 fprintf( stderr, " win_top=%d,", req->win_top );
1517 fprintf( stderr, " win_right=%d,", req->win_right );
1518 fprintf( stderr, " win_bottom=%d,", req->win_bottom );
1519 fprintf( stderr, " max_width=%d,", req->max_width );
1520 fprintf( stderr, " max_height=%d", req->max_height );
1523 static void dump_get_console_output_info_request( const struct get_console_output_info_request *req )
1525 fprintf( stderr, " handle=%p", req->handle );
1528 static void dump_get_console_output_info_reply( const struct get_console_output_info_reply *req )
1530 fprintf( stderr, " cursor_size=%d,", req->cursor_size );
1531 fprintf( stderr, " cursor_visible=%d,", req->cursor_visible );
1532 fprintf( stderr, " cursor_x=%d,", req->cursor_x );
1533 fprintf( stderr, " cursor_y=%d,", req->cursor_y );
1534 fprintf( stderr, " width=%d,", req->width );
1535 fprintf( stderr, " height=%d,", req->height );
1536 fprintf( stderr, " attr=%d,", req->attr );
1537 fprintf( stderr, " win_left=%d,", req->win_left );
1538 fprintf( stderr, " win_top=%d,", req->win_top );
1539 fprintf( stderr, " win_right=%d,", req->win_right );
1540 fprintf( stderr, " win_bottom=%d,", req->win_bottom );
1541 fprintf( stderr, " max_width=%d,", req->max_width );
1542 fprintf( stderr, " max_height=%d", req->max_height );
1545 static void dump_write_console_input_request( const struct write_console_input_request *req )
1547 fprintf( stderr, " handle=%p,", req->handle );
1548 fprintf( stderr, " rec=" );
1549 dump_varargs_input_records( cur_size );
1552 static void dump_write_console_input_reply( const struct write_console_input_reply *req )
1554 fprintf( stderr, " written=%d", req->written );
1557 static void dump_read_console_input_request( const struct read_console_input_request *req )
1559 fprintf( stderr, " handle=%p,", req->handle );
1560 fprintf( stderr, " flush=%d", req->flush );
1563 static void dump_read_console_input_reply( const struct read_console_input_reply *req )
1565 fprintf( stderr, " read=%d,", req->read );
1566 fprintf( stderr, " rec=" );
1567 dump_varargs_input_records( cur_size );
1570 static void dump_write_console_output_request( const struct write_console_output_request *req )
1572 fprintf( stderr, " handle=%p,", req->handle );
1573 fprintf( stderr, " x=%d,", req->x );
1574 fprintf( stderr, " y=%d,", req->y );
1575 fprintf( stderr, " mode=%d,", req->mode );
1576 fprintf( stderr, " wrap=%d,", req->wrap );
1577 fprintf( stderr, " data=" );
1578 dump_varargs_bytes( cur_size );
1581 static void dump_write_console_output_reply( const struct write_console_output_reply *req )
1583 fprintf( stderr, " written=%d,", req->written );
1584 fprintf( stderr, " width=%d,", req->width );
1585 fprintf( stderr, " height=%d", req->height );
1588 static void dump_fill_console_output_request( const struct fill_console_output_request *req )
1590 fprintf( stderr, " handle=%p,", req->handle );
1591 fprintf( stderr, " x=%d,", req->x );
1592 fprintf( stderr, " y=%d,", req->y );
1593 fprintf( stderr, " mode=%d,", req->mode );
1594 fprintf( stderr, " count=%d,", req->count );
1595 fprintf( stderr, " wrap=%d,", req->wrap );
1596 fprintf( stderr, " data=" );
1597 dump_char_info( &req->data );
1600 static void dump_fill_console_output_reply( const struct fill_console_output_reply *req )
1602 fprintf( stderr, " written=%d", req->written );
1605 static void dump_read_console_output_request( const struct read_console_output_request *req )
1607 fprintf( stderr, " handle=%p,", req->handle );
1608 fprintf( stderr, " x=%d,", req->x );
1609 fprintf( stderr, " y=%d,", req->y );
1610 fprintf( stderr, " mode=%d,", req->mode );
1611 fprintf( stderr, " wrap=%d", req->wrap );
1614 static void dump_read_console_output_reply( const struct read_console_output_reply *req )
1616 fprintf( stderr, " width=%d,", req->width );
1617 fprintf( stderr, " height=%d,", req->height );
1618 fprintf( stderr, " data=" );
1619 dump_varargs_bytes( cur_size );
1622 static void dump_move_console_output_request( const struct move_console_output_request *req )
1624 fprintf( stderr, " handle=%p,", req->handle );
1625 fprintf( stderr, " x_src=%d,", req->x_src );
1626 fprintf( stderr, " y_src=%d,", req->y_src );
1627 fprintf( stderr, " x_dst=%d,", req->x_dst );
1628 fprintf( stderr, " y_dst=%d,", req->y_dst );
1629 fprintf( stderr, " w=%d,", req->w );
1630 fprintf( stderr, " h=%d", req->h );
1633 static void dump_send_console_signal_request( const struct send_console_signal_request *req )
1635 fprintf( stderr, " signal=%d,", req->signal );
1636 fprintf( stderr, " group_id=%04x", req->group_id );
1639 static void dump_read_directory_changes_request( const struct read_directory_changes_request *req )
1641 fprintf( stderr, " filter=%08x,", req->filter );
1642 fprintf( stderr, " handle=%p,", req->handle );
1643 fprintf( stderr, " event=%p,", req->event );
1644 fprintf( stderr, " subtree=%d,", req->subtree );
1645 fprintf( stderr, " want_data=%d,", req->want_data );
1646 fprintf( stderr, " io_apc=%p,", req->io_apc );
1647 fprintf( stderr, " io_sb=%p,", req->io_sb );
1648 fprintf( stderr, " io_user=%p", req->io_user );
1651 static void dump_read_change_request( const struct read_change_request *req )
1653 fprintf( stderr, " handle=%p", req->handle );
1656 static void dump_read_change_reply( const struct read_change_reply *req )
1658 fprintf( stderr, " action=%d,", req->action );
1659 fprintf( stderr, " name=" );
1660 dump_varargs_string( cur_size );
1663 static void dump_create_mapping_request( const struct create_mapping_request *req )
1665 fprintf( stderr, " access=%08x,", req->access );
1666 fprintf( stderr, " attributes=%08x,", req->attributes );
1667 fprintf( stderr, " rootdir=%p,", req->rootdir );
1668 fprintf( stderr, " size_high=%d,", req->size_high );
1669 fprintf( stderr, " size_low=%d,", req->size_low );
1670 fprintf( stderr, " protect=%d,", req->protect );
1671 fprintf( stderr, " file_handle=%p,", req->file_handle );
1672 fprintf( stderr, " name=" );
1673 dump_varargs_unicode_str( cur_size );
1676 static void dump_create_mapping_reply( const struct create_mapping_reply *req )
1678 fprintf( stderr, " handle=%p", req->handle );
1681 static void dump_open_mapping_request( const struct open_mapping_request *req )
1683 fprintf( stderr, " access=%08x,", req->access );
1684 fprintf( stderr, " attributes=%08x,", req->attributes );
1685 fprintf( stderr, " rootdir=%p,", req->rootdir );
1686 fprintf( stderr, " name=" );
1687 dump_varargs_unicode_str( cur_size );
1690 static void dump_open_mapping_reply( const struct open_mapping_reply *req )
1692 fprintf( stderr, " handle=%p", req->handle );
1695 static void dump_get_mapping_info_request( const struct get_mapping_info_request *req )
1697 fprintf( stderr, " handle=%p", req->handle );
1700 static void dump_get_mapping_info_reply( const struct get_mapping_info_reply *req )
1702 fprintf( stderr, " size_high=%d,", req->size_high );
1703 fprintf( stderr, " size_low=%d,", req->size_low );
1704 fprintf( stderr, " protect=%d,", req->protect );
1705 fprintf( stderr, " header_size=%d,", req->header_size );
1706 fprintf( stderr, " base=%p,", req->base );
1707 fprintf( stderr, " mapping=%p,", req->mapping );
1708 fprintf( stderr, " shared_file=%p,", req->shared_file );
1709 fprintf( stderr, " shared_size=%d", req->shared_size );
1712 static void dump_create_snapshot_request( const struct create_snapshot_request *req )
1714 fprintf( stderr, " attributes=%08x,", req->attributes );
1715 fprintf( stderr, " flags=%d,", req->flags );
1716 fprintf( stderr, " pid=%04x", req->pid );
1719 static void dump_create_snapshot_reply( const struct create_snapshot_reply *req )
1721 fprintf( stderr, " handle=%p", req->handle );
1724 static void dump_next_process_request( const struct next_process_request *req )
1726 fprintf( stderr, " handle=%p,", req->handle );
1727 fprintf( stderr, " reset=%d", req->reset );
1730 static void dump_next_process_reply( const struct next_process_reply *req )
1732 fprintf( stderr, " count=%d,", req->count );
1733 fprintf( stderr, " pid=%04x,", req->pid );
1734 fprintf( stderr, " ppid=%04x,", req->ppid );
1735 fprintf( stderr, " heap=%p,", req->heap );
1736 fprintf( stderr, " module=%p,", req->module );
1737 fprintf( stderr, " threads=%d,", req->threads );
1738 fprintf( stderr, " priority=%d,", req->priority );
1739 fprintf( stderr, " handles=%d,", req->handles );
1740 fprintf( stderr, " filename=" );
1741 dump_varargs_unicode_str( cur_size );
1744 static void dump_next_thread_request( const struct next_thread_request *req )
1746 fprintf( stderr, " handle=%p,", req->handle );
1747 fprintf( stderr, " reset=%d", req->reset );
1750 static void dump_next_thread_reply( const struct next_thread_reply *req )
1752 fprintf( stderr, " count=%d,", req->count );
1753 fprintf( stderr, " pid=%04x,", req->pid );
1754 fprintf( stderr, " tid=%04x,", req->tid );
1755 fprintf( stderr, " base_pri=%d,", req->base_pri );
1756 fprintf( stderr, " delta_pri=%d", req->delta_pri );
1759 static void dump_next_module_request( const struct next_module_request *req )
1761 fprintf( stderr, " handle=%p,", req->handle );
1762 fprintf( stderr, " reset=%d", req->reset );
1765 static void dump_next_module_reply( const struct next_module_reply *req )
1767 fprintf( stderr, " pid=%04x,", req->pid );
1768 fprintf( stderr, " base=%p,", req->base );
1769 fprintf( stderr, " size=%lu,", (unsigned long)req->size );
1770 fprintf( stderr, " filename=" );
1771 dump_varargs_unicode_str( cur_size );
1774 static void dump_wait_debug_event_request( const struct wait_debug_event_request *req )
1776 fprintf( stderr, " get_handle=%d", req->get_handle );
1779 static void dump_wait_debug_event_reply( const struct wait_debug_event_reply *req )
1781 fprintf( stderr, " pid=%04x,", req->pid );
1782 fprintf( stderr, " tid=%04x,", req->tid );
1783 fprintf( stderr, " wait=%p,", req->wait );
1784 fprintf( stderr, " event=" );
1785 dump_varargs_debug_event( cur_size );
1788 static void dump_queue_exception_event_request( const struct queue_exception_event_request *req )
1790 fprintf( stderr, " first=%d,", req->first );
1791 fprintf( stderr, " record=" );
1792 dump_varargs_exc_event( cur_size );
1795 static void dump_queue_exception_event_reply( const struct queue_exception_event_reply *req )
1797 fprintf( stderr, " handle=%p", req->handle );
1800 static void dump_get_exception_status_request( const struct get_exception_status_request *req )
1802 fprintf( stderr, " handle=%p", req->handle );
1805 static void dump_get_exception_status_reply( const struct get_exception_status_reply *req )
1807 fprintf( stderr, " context=" );
1808 dump_varargs_context( cur_size );
1811 static void dump_output_debug_string_request( const struct output_debug_string_request *req )
1813 fprintf( stderr, " string=%p,", req->string );
1814 fprintf( stderr, " unicode=%d,", req->unicode );
1815 fprintf( stderr, " length=%d", req->length );
1818 static void dump_continue_debug_event_request( const struct continue_debug_event_request *req )
1820 fprintf( stderr, " pid=%04x,", req->pid );
1821 fprintf( stderr, " tid=%04x,", req->tid );
1822 fprintf( stderr, " status=%d", req->status );
1825 static void dump_debug_process_request( const struct debug_process_request *req )
1827 fprintf( stderr, " pid=%04x,", req->pid );
1828 fprintf( stderr, " attach=%d", req->attach );
1831 static void dump_debug_break_request( const struct debug_break_request *req )
1833 fprintf( stderr, " handle=%p", req->handle );
1836 static void dump_debug_break_reply( const struct debug_break_reply *req )
1838 fprintf( stderr, " self=%d", req->self );
1841 static void dump_set_debugger_kill_on_exit_request( const struct set_debugger_kill_on_exit_request *req )
1843 fprintf( stderr, " kill_on_exit=%d", req->kill_on_exit );
1846 static void dump_read_process_memory_request( const struct read_process_memory_request *req )
1848 fprintf( stderr, " handle=%p,", req->handle );
1849 fprintf( stderr, " addr=%p", req->addr );
1852 static void dump_read_process_memory_reply( const struct read_process_memory_reply *req )
1854 fprintf( stderr, " data=" );
1855 dump_varargs_bytes( cur_size );
1858 static void dump_write_process_memory_request( const struct write_process_memory_request *req )
1860 fprintf( stderr, " handle=%p,", req->handle );
1861 fprintf( stderr, " addr=%p,", req->addr );
1862 fprintf( stderr, " data=" );
1863 dump_varargs_bytes( cur_size );
1866 static void dump_create_key_request( const struct create_key_request *req )
1868 fprintf( stderr, " parent=%p,", req->parent );
1869 fprintf( stderr, " access=%08x,", req->access );
1870 fprintf( stderr, " attributes=%08x,", req->attributes );
1871 fprintf( stderr, " options=%08x,", req->options );
1872 fprintf( stderr, " modif=%ld,", (long)req->modif );
1873 fprintf( stderr, " namelen=%u,", req->namelen );
1874 fprintf( stderr, " name=" );
1875 dump_varargs_unicode_str( min(cur_size,req->namelen) );
1876 fputc( ',', stderr );
1877 fprintf( stderr, " class=" );
1878 dump_varargs_unicode_str( cur_size );
1881 static void dump_create_key_reply( const struct create_key_reply *req )
1883 fprintf( stderr, " hkey=%p,", req->hkey );
1884 fprintf( stderr, " created=%d", req->created );
1887 static void dump_open_key_request( const struct open_key_request *req )
1889 fprintf( stderr, " parent=%p,", req->parent );
1890 fprintf( stderr, " access=%08x,", req->access );
1891 fprintf( stderr, " attributes=%08x,", req->attributes );
1892 fprintf( stderr, " name=" );
1893 dump_varargs_unicode_str( cur_size );
1896 static void dump_open_key_reply( const struct open_key_reply *req )
1898 fprintf( stderr, " hkey=%p", req->hkey );
1901 static void dump_delete_key_request( const struct delete_key_request *req )
1903 fprintf( stderr, " hkey=%p", req->hkey );
1906 static void dump_flush_key_request( const struct flush_key_request *req )
1908 fprintf( stderr, " hkey=%p", req->hkey );
1911 static void dump_enum_key_request( const struct enum_key_request *req )
1913 fprintf( stderr, " hkey=%p,", req->hkey );
1914 fprintf( stderr, " index=%d,", req->index );
1915 fprintf( stderr, " info_class=%d", req->info_class );
1918 static void dump_enum_key_reply( const struct enum_key_reply *req )
1920 fprintf( stderr, " subkeys=%d,", req->subkeys );
1921 fprintf( stderr, " max_subkey=%d,", req->max_subkey );
1922 fprintf( stderr, " max_class=%d,", req->max_class );
1923 fprintf( stderr, " values=%d,", req->values );
1924 fprintf( stderr, " max_value=%d,", req->max_value );
1925 fprintf( stderr, " max_data=%d,", req->max_data );
1926 fprintf( stderr, " modif=%ld,", (long)req->modif );
1927 fprintf( stderr, " total=%u,", req->total );
1928 fprintf( stderr, " namelen=%u,", req->namelen );
1929 fprintf( stderr, " name=" );
1930 dump_varargs_unicode_str( min(cur_size,req->namelen) );
1931 fputc( ',', stderr );
1932 fprintf( stderr, " class=" );
1933 dump_varargs_unicode_str( cur_size );
1936 static void dump_set_key_value_request( const struct set_key_value_request *req )
1938 fprintf( stderr, " hkey=%p,", req->hkey );
1939 fprintf( stderr, " type=%d,", req->type );
1940 fprintf( stderr, " namelen=%u,", req->namelen );
1941 fprintf( stderr, " name=" );
1942 dump_varargs_unicode_str( min(cur_size,req->namelen) );
1943 fputc( ',', stderr );
1944 fprintf( stderr, " data=" );
1945 dump_varargs_bytes( cur_size );
1948 static void dump_get_key_value_request( const struct get_key_value_request *req )
1950 fprintf( stderr, " hkey=%p,", req->hkey );
1951 fprintf( stderr, " name=" );
1952 dump_varargs_unicode_str( cur_size );
1955 static void dump_get_key_value_reply( const struct get_key_value_reply *req )
1957 fprintf( stderr, " type=%d,", req->type );
1958 fprintf( stderr, " total=%u,", req->total );
1959 fprintf( stderr, " data=" );
1960 dump_varargs_bytes( cur_size );
1963 static void dump_enum_key_value_request( const struct enum_key_value_request *req )
1965 fprintf( stderr, " hkey=%p,", req->hkey );
1966 fprintf( stderr, " index=%d,", req->index );
1967 fprintf( stderr, " info_class=%d", req->info_class );
1970 static void dump_enum_key_value_reply( const struct enum_key_value_reply *req )
1972 fprintf( stderr, " type=%d,", req->type );
1973 fprintf( stderr, " total=%u,", req->total );
1974 fprintf( stderr, " namelen=%u,", req->namelen );
1975 fprintf( stderr, " name=" );
1976 dump_varargs_unicode_str( min(cur_size,req->namelen) );
1977 fputc( ',', stderr );
1978 fprintf( stderr, " data=" );
1979 dump_varargs_bytes( cur_size );
1982 static void dump_delete_key_value_request( const struct delete_key_value_request *req )
1984 fprintf( stderr, " hkey=%p,", req->hkey );
1985 fprintf( stderr, " name=" );
1986 dump_varargs_unicode_str( cur_size );
1989 static void dump_load_registry_request( const struct load_registry_request *req )
1991 fprintf( stderr, " hkey=%p,", req->hkey );
1992 fprintf( stderr, " file=%p,", req->file );
1993 fprintf( stderr, " name=" );
1994 dump_varargs_unicode_str( cur_size );
1997 static void dump_unload_registry_request( const struct unload_registry_request *req )
1999 fprintf( stderr, " hkey=%p", req->hkey );
2002 static void dump_save_registry_request( const struct save_registry_request *req )
2004 fprintf( stderr, " hkey=%p,", req->hkey );
2005 fprintf( stderr, " file=%p", req->file );
2008 static void dump_set_registry_notification_request( const struct set_registry_notification_request *req )
2010 fprintf( stderr, " hkey=%p,", req->hkey );
2011 fprintf( stderr, " event=%p,", req->event );
2012 fprintf( stderr, " subtree=%d,", req->subtree );
2013 fprintf( stderr, " filter=%08x", req->filter );
2016 static void dump_create_timer_request( const struct create_timer_request *req )
2018 fprintf( stderr, " access=%08x,", req->access );
2019 fprintf( stderr, " attributes=%08x,", req->attributes );
2020 fprintf( stderr, " rootdir=%p,", req->rootdir );
2021 fprintf( stderr, " manual=%d,", req->manual );
2022 fprintf( stderr, " name=" );
2023 dump_varargs_unicode_str( cur_size );
2026 static void dump_create_timer_reply( const struct create_timer_reply *req )
2028 fprintf( stderr, " handle=%p", req->handle );
2031 static void dump_open_timer_request( const struct open_timer_request *req )
2033 fprintf( stderr, " access=%08x,", req->access );
2034 fprintf( stderr, " attributes=%08x,", req->attributes );
2035 fprintf( stderr, " rootdir=%p,", req->rootdir );
2036 fprintf( stderr, " name=" );
2037 dump_varargs_unicode_str( cur_size );
2040 static void dump_open_timer_reply( const struct open_timer_reply *req )
2042 fprintf( stderr, " handle=%p", req->handle );
2045 static void dump_set_timer_request( const struct set_timer_request *req )
2047 fprintf( stderr, " handle=%p,", req->handle );
2048 fprintf( stderr, " expire=" );
2049 dump_abs_time( &req->expire );
2050 fprintf( stderr, "," );
2051 fprintf( stderr, " period=%d,", req->period );
2052 fprintf( stderr, " callback=%p,", req->callback );
2053 fprintf( stderr, " arg=%p", req->arg );
2056 static void dump_set_timer_reply( const struct set_timer_reply *req )
2058 fprintf( stderr, " signaled=%d", req->signaled );
2061 static void dump_cancel_timer_request( const struct cancel_timer_request *req )
2063 fprintf( stderr, " handle=%p", req->handle );
2066 static void dump_cancel_timer_reply( const struct cancel_timer_reply *req )
2068 fprintf( stderr, " signaled=%d", req->signaled );
2071 static void dump_get_timer_info_request( const struct get_timer_info_request *req )
2073 fprintf( stderr, " handle=%p", req->handle );
2076 static void dump_get_timer_info_reply( const struct get_timer_info_reply *req )
2078 fprintf( stderr, " when=" );
2079 dump_abs_time( &req->when );
2080 fprintf( stderr, "," );
2081 fprintf( stderr, " signaled=%d", req->signaled );
2084 static void dump_get_thread_context_request( const struct get_thread_context_request *req )
2086 fprintf( stderr, " handle=%p,", req->handle );
2087 fprintf( stderr, " flags=%08x,", req->flags );
2088 fprintf( stderr, " suspend=%d", req->suspend );
2091 static void dump_get_thread_context_reply( const struct get_thread_context_reply *req )
2093 fprintf( stderr, " self=%d,", req->self );
2094 fprintf( stderr, " context=" );
2095 dump_varargs_context( cur_size );
2098 static void dump_set_thread_context_request( const struct set_thread_context_request *req )
2100 fprintf( stderr, " handle=%p,", req->handle );
2101 fprintf( stderr, " flags=%08x,", req->flags );
2102 fprintf( stderr, " suspend=%d,", req->suspend );
2103 fprintf( stderr, " context=" );
2104 dump_varargs_context( cur_size );
2107 static void dump_set_thread_context_reply( const struct set_thread_context_reply *req )
2109 fprintf( stderr, " self=%d", req->self );
2112 static void dump_get_selector_entry_request( const struct get_selector_entry_request *req )
2114 fprintf( stderr, " handle=%p,", req->handle );
2115 fprintf( stderr, " entry=%d", req->entry );
2118 static void dump_get_selector_entry_reply( const struct get_selector_entry_reply *req )
2120 fprintf( stderr, " base=%08x,", req->base );
2121 fprintf( stderr, " limit=%08x,", req->limit );
2122 fprintf( stderr, " flags=%02x", req->flags );
2125 static void dump_add_atom_request( const struct add_atom_request *req )
2127 fprintf( stderr, " table=%p,", req->table );
2128 fprintf( stderr, " name=" );
2129 dump_varargs_unicode_str( cur_size );
2132 static void dump_add_atom_reply( const struct add_atom_reply *req )
2134 fprintf( stderr, " atom=%04x", req->atom );
2137 static void dump_delete_atom_request( const struct delete_atom_request *req )
2139 fprintf( stderr, " table=%p,", req->table );
2140 fprintf( stderr, " atom=%04x", req->atom );
2143 static void dump_find_atom_request( const struct find_atom_request *req )
2145 fprintf( stderr, " table=%p,", req->table );
2146 fprintf( stderr, " name=" );
2147 dump_varargs_unicode_str( cur_size );
2150 static void dump_find_atom_reply( const struct find_atom_reply *req )
2152 fprintf( stderr, " atom=%04x", req->atom );
2155 static void dump_get_atom_information_request( const struct get_atom_information_request *req )
2157 fprintf( stderr, " table=%p,", req->table );
2158 fprintf( stderr, " atom=%04x", req->atom );
2161 static void dump_get_atom_information_reply( const struct get_atom_information_reply *req )
2163 fprintf( stderr, " count=%d,", req->count );
2164 fprintf( stderr, " pinned=%d,", req->pinned );
2165 fprintf( stderr, " total=%u,", req->total );
2166 fprintf( stderr, " name=" );
2167 dump_varargs_unicode_str( cur_size );
2170 static void dump_set_atom_information_request( const struct set_atom_information_request *req )
2172 fprintf( stderr, " table=%p,", req->table );
2173 fprintf( stderr, " atom=%04x,", req->atom );
2174 fprintf( stderr, " pinned=%d", req->pinned );
2177 static void dump_empty_atom_table_request( const struct empty_atom_table_request *req )
2179 fprintf( stderr, " table=%p,", req->table );
2180 fprintf( stderr, " if_pinned=%d", req->if_pinned );
2183 static void dump_init_atom_table_request( const struct init_atom_table_request *req )
2185 fprintf( stderr, " entries=%d", req->entries );
2188 static void dump_init_atom_table_reply( const struct init_atom_table_reply *req )
2190 fprintf( stderr, " table=%p", req->table );
2193 static void dump_get_msg_queue_request( const struct get_msg_queue_request *req )
2197 static void dump_get_msg_queue_reply( const struct get_msg_queue_reply *req )
2199 fprintf( stderr, " handle=%p", req->handle );
2202 static void dump_set_queue_mask_request( const struct set_queue_mask_request *req )
2204 fprintf( stderr, " wake_mask=%08x,", req->wake_mask );
2205 fprintf( stderr, " changed_mask=%08x,", req->changed_mask );
2206 fprintf( stderr, " skip_wait=%d", req->skip_wait );
2209 static void dump_set_queue_mask_reply( const struct set_queue_mask_reply *req )
2211 fprintf( stderr, " wake_bits=%08x,", req->wake_bits );
2212 fprintf( stderr, " changed_bits=%08x", req->changed_bits );
2215 static void dump_get_queue_status_request( const struct get_queue_status_request *req )
2217 fprintf( stderr, " clear=%d", req->clear );
2220 static void dump_get_queue_status_reply( const struct get_queue_status_reply *req )
2222 fprintf( stderr, " wake_bits=%08x,", req->wake_bits );
2223 fprintf( stderr, " changed_bits=%08x", req->changed_bits );
2226 static void dump_get_process_idle_event_request( const struct get_process_idle_event_request *req )
2228 fprintf( stderr, " handle=%p", req->handle );
2231 static void dump_get_process_idle_event_reply( const struct get_process_idle_event_reply *req )
2233 fprintf( stderr, " event=%p", req->event );
2236 static void dump_send_message_request( const struct send_message_request *req )
2238 fprintf( stderr, " id=%04x,", req->id );
2239 fprintf( stderr, " type=%d,", req->type );
2240 fprintf( stderr, " flags=%d,", req->flags );
2241 fprintf( stderr, " win=%p,", req->win );
2242 fprintf( stderr, " msg=%08x,", req->msg );
2243 fprintf( stderr, " wparam=%lx,", req->wparam );
2244 fprintf( stderr, " lparam=%lx,", req->lparam );
2245 fprintf( stderr, " timeout=%d,", req->timeout );
2246 fprintf( stderr, " data=" );
2247 dump_varargs_message_data( cur_size );
2250 static void dump_post_quit_message_request( const struct post_quit_message_request *req )
2252 fprintf( stderr, " exit_code=%d", req->exit_code );
2255 static void dump_send_hardware_message_request( const struct send_hardware_message_request *req )
2257 fprintf( stderr, " id=%04x,", req->id );
2258 fprintf( stderr, " win=%p,", req->win );
2259 fprintf( stderr, " msg=%08x,", req->msg );
2260 fprintf( stderr, " time=%08x,", req->time );
2261 fprintf( stderr, " wparam=%lx,", req->wparam );
2262 fprintf( stderr, " lparam=%lx,", req->lparam );
2263 fprintf( stderr, " info=%lx,", req->info );
2264 fprintf( stderr, " x=%d,", req->x );
2265 fprintf( stderr, " y=%d", req->y );
2268 static void dump_get_message_request( const struct get_message_request *req )
2270 fprintf( stderr, " flags=%d,", req->flags );
2271 fprintf( stderr, " get_win=%p,", req->get_win );
2272 fprintf( stderr, " get_first=%08x,", req->get_first );
2273 fprintf( stderr, " get_last=%08x,", req->get_last );
2274 fprintf( stderr, " hw_id=%08x", req->hw_id );
2277 static void dump_get_message_reply( const struct get_message_reply *req )
2279 fprintf( stderr, " win=%p,", req->win );
2280 fprintf( stderr, " type=%d,", req->type );
2281 fprintf( stderr, " msg=%08x,", req->msg );
2282 fprintf( stderr, " wparam=%lx,", req->wparam );
2283 fprintf( stderr, " lparam=%lx,", req->lparam );
2284 fprintf( stderr, " info=%lx,", req->info );
2285 fprintf( stderr, " x=%d,", req->x );
2286 fprintf( stderr, " y=%d,", req->y );
2287 fprintf( stderr, " time=%08x,", req->time );
2288 fprintf( stderr, " hw_id=%08x,", req->hw_id );
2289 fprintf( stderr, " active_hooks=%08x,", req->active_hooks );
2290 fprintf( stderr, " total=%u,", req->total );
2291 fprintf( stderr, " data=" );
2292 dump_varargs_message_data( cur_size );
2295 static void dump_reply_message_request( const struct reply_message_request *req )
2297 fprintf( stderr, " result=%08x,", req->result );
2298 fprintf( stderr, " remove=%d,", req->remove );
2299 fprintf( stderr, " data=" );
2300 dump_varargs_bytes( cur_size );
2303 static void dump_accept_hardware_message_request( const struct accept_hardware_message_request *req )
2305 fprintf( stderr, " hw_id=%08x,", req->hw_id );
2306 fprintf( stderr, " remove=%d,", req->remove );
2307 fprintf( stderr, " new_win=%p", req->new_win );
2310 static void dump_get_message_reply_request( const struct get_message_reply_request *req )
2312 fprintf( stderr, " cancel=%d", req->cancel );
2315 static void dump_get_message_reply_reply( const struct get_message_reply_reply *req )
2317 fprintf( stderr, " result=%08x,", req->result );
2318 fprintf( stderr, " data=" );
2319 dump_varargs_bytes( cur_size );
2322 static void dump_set_win_timer_request( const struct set_win_timer_request *req )
2324 fprintf( stderr, " win=%p,", req->win );
2325 fprintf( stderr, " msg=%08x,", req->msg );
2326 fprintf( stderr, " rate=%08x,", req->rate );
2327 fprintf( stderr, " id=%lx,", req->id );
2328 fprintf( stderr, " lparam=%lx", req->lparam );
2331 static void dump_set_win_timer_reply( const struct set_win_timer_reply *req )
2333 fprintf( stderr, " id=%lx", req->id );
2336 static void dump_kill_win_timer_request( const struct kill_win_timer_request *req )
2338 fprintf( stderr, " win=%p,", req->win );
2339 fprintf( stderr, " msg=%08x,", req->msg );
2340 fprintf( stderr, " id=%lx", req->id );
2343 static void dump_get_serial_info_request( const struct get_serial_info_request *req )
2345 fprintf( stderr, " handle=%p", req->handle );
2348 static void dump_get_serial_info_reply( const struct get_serial_info_reply *req )
2350 fprintf( stderr, " readinterval=%08x,", req->readinterval );
2351 fprintf( stderr, " readconst=%08x,", req->readconst );
2352 fprintf( stderr, " readmult=%08x,", req->readmult );
2353 fprintf( stderr, " writeconst=%08x,", req->writeconst );
2354 fprintf( stderr, " writemult=%08x,", req->writemult );
2355 fprintf( stderr, " eventmask=%08x", req->eventmask );
2358 static void dump_set_serial_info_request( const struct set_serial_info_request *req )
2360 fprintf( stderr, " handle=%p,", req->handle );
2361 fprintf( stderr, " flags=%d,", req->flags );
2362 fprintf( stderr, " readinterval=%08x,", req->readinterval );
2363 fprintf( stderr, " readconst=%08x,", req->readconst );
2364 fprintf( stderr, " readmult=%08x,", req->readmult );
2365 fprintf( stderr, " writeconst=%08x,", req->writeconst );
2366 fprintf( stderr, " writemult=%08x,", req->writemult );
2367 fprintf( stderr, " eventmask=%08x", req->eventmask );
2370 static void dump_register_async_request( const struct register_async_request *req )
2372 fprintf( stderr, " handle=%p,", req->handle );
2373 fprintf( stderr, " type=%d,", req->type );
2374 fprintf( stderr, " io_apc=%p,", req->io_apc );
2375 fprintf( stderr, " io_sb=%p,", req->io_sb );
2376 fprintf( stderr, " io_user=%p,", req->io_user );
2377 fprintf( stderr, " count=%d", req->count );
2380 static void dump_cancel_async_request( const struct cancel_async_request *req )
2382 fprintf( stderr, " handle=%p", req->handle );
2385 static void dump_create_named_pipe_request( const struct create_named_pipe_request *req )
2387 fprintf( stderr, " access=%08x,", req->access );
2388 fprintf( stderr, " attributes=%08x,", req->attributes );
2389 fprintf( stderr, " rootdir=%p,", req->rootdir );
2390 fprintf( stderr, " options=%08x,", req->options );
2391 fprintf( stderr, " flags=%08x,", req->flags );
2392 fprintf( stderr, " maxinstances=%08x,", req->maxinstances );
2393 fprintf( stderr, " outsize=%08x,", req->outsize );
2394 fprintf( stderr, " insize=%08x,", req->insize );
2395 fprintf( stderr, " timeout=%08x,", req->timeout );
2396 fprintf( stderr, " name=" );
2397 dump_varargs_unicode_str( cur_size );
2400 static void dump_create_named_pipe_reply( const struct create_named_pipe_reply *req )
2402 fprintf( stderr, " handle=%p", req->handle );
2405 static void dump_open_named_pipe_request( const struct open_named_pipe_request *req )
2407 fprintf( stderr, " access=%08x,", req->access );
2408 fprintf( stderr, " attributes=%08x,", req->attributes );
2409 fprintf( stderr, " rootdir=%p,", req->rootdir );
2410 fprintf( stderr, " flags=%08x,", req->flags );
2411 fprintf( stderr, " name=" );
2412 dump_varargs_unicode_str( cur_size );
2415 static void dump_open_named_pipe_reply( const struct open_named_pipe_reply *req )
2417 fprintf( stderr, " handle=%p", req->handle );
2420 static void dump_connect_named_pipe_request( const struct connect_named_pipe_request *req )
2422 fprintf( stderr, " handle=%p,", req->handle );
2423 fprintf( stderr, " event=%p,", req->event );
2424 fprintf( stderr, " func=%p", req->func );
2427 static void dump_wait_named_pipe_request( const struct wait_named_pipe_request *req )
2429 fprintf( stderr, " handle=%p,", req->handle );
2430 fprintf( stderr, " timeout=%08x,", req->timeout );
2431 fprintf( stderr, " event=%p,", req->event );
2432 fprintf( stderr, " func=%p,", req->func );
2433 fprintf( stderr, " name=" );
2434 dump_varargs_unicode_str( cur_size );
2437 static void dump_disconnect_named_pipe_request( const struct disconnect_named_pipe_request *req )
2439 fprintf( stderr, " handle=%p", req->handle );
2442 static void dump_get_named_pipe_info_request( const struct get_named_pipe_info_request *req )
2444 fprintf( stderr, " handle=%p", req->handle );
2447 static void dump_get_named_pipe_info_reply( const struct get_named_pipe_info_reply *req )
2449 fprintf( stderr, " flags=%08x,", req->flags );
2450 fprintf( stderr, " maxinstances=%08x,", req->maxinstances );
2451 fprintf( stderr, " instances=%08x,", req->instances );
2452 fprintf( stderr, " outsize=%08x,", req->outsize );
2453 fprintf( stderr, " insize=%08x", req->insize );
2456 static void dump_create_window_request( const struct create_window_request *req )
2458 fprintf( stderr, " parent=%p,", req->parent );
2459 fprintf( stderr, " owner=%p,", req->owner );
2460 fprintf( stderr, " atom=%04x,", req->atom );
2461 fprintf( stderr, " instance=%p", req->instance );
2464 static void dump_create_window_reply( const struct create_window_reply *req )
2466 fprintf( stderr, " handle=%p,", req->handle );
2467 fprintf( stderr, " parent=%p,", req->parent );
2468 fprintf( stderr, " owner=%p,", req->owner );
2469 fprintf( stderr, " extra=%d,", req->extra );
2470 fprintf( stderr, " class_ptr=%p", req->class_ptr );
2473 static void dump_destroy_window_request( const struct destroy_window_request *req )
2475 fprintf( stderr, " handle=%p", req->handle );
2478 static void dump_get_desktop_window_request( const struct get_desktop_window_request *req )
2480 fprintf( stderr, " force=%d", req->force );
2483 static void dump_get_desktop_window_reply( const struct get_desktop_window_reply *req )
2485 fprintf( stderr, " handle=%p", req->handle );
2488 static void dump_set_window_owner_request( const struct set_window_owner_request *req )
2490 fprintf( stderr, " handle=%p,", req->handle );
2491 fprintf( stderr, " owner=%p", req->owner );
2494 static void dump_set_window_owner_reply( const struct set_window_owner_reply *req )
2496 fprintf( stderr, " full_owner=%p,", req->full_owner );
2497 fprintf( stderr, " prev_owner=%p", req->prev_owner );
2500 static void dump_get_window_info_request( const struct get_window_info_request *req )
2502 fprintf( stderr, " handle=%p", req->handle );
2505 static void dump_get_window_info_reply( const struct get_window_info_reply *req )
2507 fprintf( stderr, " full_handle=%p,", req->full_handle );
2508 fprintf( stderr, " last_active=%p,", req->last_active );
2509 fprintf( stderr, " pid=%04x,", req->pid );
2510 fprintf( stderr, " tid=%04x,", req->tid );
2511 fprintf( stderr, " atom=%04x,", req->atom );
2512 fprintf( stderr, " is_unicode=%d", req->is_unicode );
2515 static void dump_set_window_info_request( const struct set_window_info_request *req )
2517 fprintf( stderr, " flags=%08x,", req->flags );
2518 fprintf( stderr, " handle=%p,", req->handle );
2519 fprintf( stderr, " style=%08x,", req->style );
2520 fprintf( stderr, " ex_style=%08x,", req->ex_style );
2521 fprintf( stderr, " id=%08x,", req->id );
2522 fprintf( stderr, " is_unicode=%d,", req->is_unicode );
2523 fprintf( stderr, " instance=%p,", req->instance );
2524 fprintf( stderr, " user_data=%lx,", req->user_data );
2525 fprintf( stderr, " extra_offset=%d,", req->extra_offset );
2526 fprintf( stderr, " extra_size=%u,", req->extra_size );
2527 fprintf( stderr, " extra_value=%lx", req->extra_value );
2530 static void dump_set_window_info_reply( const struct set_window_info_reply *req )
2532 fprintf( stderr, " old_style=%08x,", req->old_style );
2533 fprintf( stderr, " old_ex_style=%08x,", req->old_ex_style );
2534 fprintf( stderr, " old_id=%08x,", req->old_id );
2535 fprintf( stderr, " old_instance=%p,", req->old_instance );
2536 fprintf( stderr, " old_user_data=%lx,", req->old_user_data );
2537 fprintf( stderr, " old_extra_value=%lx", req->old_extra_value );
2540 static void dump_set_parent_request( const struct set_parent_request *req )
2542 fprintf( stderr, " handle=%p,", req->handle );
2543 fprintf( stderr, " parent=%p", req->parent );
2546 static void dump_set_parent_reply( const struct set_parent_reply *req )
2548 fprintf( stderr, " old_parent=%p,", req->old_parent );
2549 fprintf( stderr, " full_parent=%p", req->full_parent );
2552 static void dump_get_window_parents_request( const struct get_window_parents_request *req )
2554 fprintf( stderr, " handle=%p", req->handle );
2557 static void dump_get_window_parents_reply( const struct get_window_parents_reply *req )
2559 fprintf( stderr, " count=%d,", req->count );
2560 fprintf( stderr, " parents=" );
2561 dump_varargs_user_handles( cur_size );
2564 static void dump_get_window_children_request( const struct get_window_children_request *req )
2566 fprintf( stderr, " parent=%p,", req->parent );
2567 fprintf( stderr, " atom=%04x,", req->atom );
2568 fprintf( stderr, " tid=%04x", req->tid );
2571 static void dump_get_window_children_reply( const struct get_window_children_reply *req )
2573 fprintf( stderr, " count=%d,", req->count );
2574 fprintf( stderr, " children=" );
2575 dump_varargs_user_handles( cur_size );
2578 static void dump_get_window_children_from_point_request( const struct get_window_children_from_point_request *req )
2580 fprintf( stderr, " parent=%p,", req->parent );
2581 fprintf( stderr, " x=%d,", req->x );
2582 fprintf( stderr, " y=%d", req->y );
2585 static void dump_get_window_children_from_point_reply( const struct get_window_children_from_point_reply *req )
2587 fprintf( stderr, " count=%d,", req->count );
2588 fprintf( stderr, " children=" );
2589 dump_varargs_user_handles( cur_size );
2592 static void dump_get_window_tree_request( const struct get_window_tree_request *req )
2594 fprintf( stderr, " handle=%p", req->handle );
2597 static void dump_get_window_tree_reply( const struct get_window_tree_reply *req )
2599 fprintf( stderr, " parent=%p,", req->parent );
2600 fprintf( stderr, " owner=%p,", req->owner );
2601 fprintf( stderr, " next_sibling=%p,", req->next_sibling );
2602 fprintf( stderr, " prev_sibling=%p,", req->prev_sibling );
2603 fprintf( stderr, " first_sibling=%p,", req->first_sibling );
2604 fprintf( stderr, " last_sibling=%p,", req->last_sibling );
2605 fprintf( stderr, " first_child=%p,", req->first_child );
2606 fprintf( stderr, " last_child=%p", req->last_child );
2609 static void dump_set_window_pos_request( const struct set_window_pos_request *req )
2611 fprintf( stderr, " flags=%08x,", req->flags );
2612 fprintf( stderr, " handle=%p,", req->handle );
2613 fprintf( stderr, " previous=%p,", req->previous );
2614 fprintf( stderr, " window=" );
2615 dump_rectangle( &req->window );
2616 fprintf( stderr, "," );
2617 fprintf( stderr, " client=" );
2618 dump_rectangle( &req->client );
2619 fprintf( stderr, "," );
2620 fprintf( stderr, " valid=" );
2621 dump_varargs_rectangles( cur_size );
2624 static void dump_set_window_pos_reply( const struct set_window_pos_reply *req )
2626 fprintf( stderr, " new_style=%08x", req->new_style );
2629 static void dump_get_window_rectangles_request( const struct get_window_rectangles_request *req )
2631 fprintf( stderr, " handle=%p", req->handle );
2634 static void dump_get_window_rectangles_reply( const struct get_window_rectangles_reply *req )
2636 fprintf( stderr, " window=" );
2637 dump_rectangle( &req->window );
2638 fprintf( stderr, "," );
2639 fprintf( stderr, " visible=" );
2640 dump_rectangle( &req->visible );
2641 fprintf( stderr, "," );
2642 fprintf( stderr, " client=" );
2643 dump_rectangle( &req->client );
2646 static void dump_get_window_text_request( const struct get_window_text_request *req )
2648 fprintf( stderr, " handle=%p", req->handle );
2651 static void dump_get_window_text_reply( const struct get_window_text_reply *req )
2653 fprintf( stderr, " text=" );
2654 dump_varargs_unicode_str( cur_size );
2657 static void dump_set_window_text_request( const struct set_window_text_request *req )
2659 fprintf( stderr, " handle=%p,", req->handle );
2660 fprintf( stderr, " text=" );
2661 dump_varargs_unicode_str( cur_size );
2664 static void dump_get_windows_offset_request( const struct get_windows_offset_request *req )
2666 fprintf( stderr, " from=%p,", req->from );
2667 fprintf( stderr, " to=%p", req->to );
2670 static void dump_get_windows_offset_reply( const struct get_windows_offset_reply *req )
2672 fprintf( stderr, " x=%d,", req->x );
2673 fprintf( stderr, " y=%d", req->y );
2676 static void dump_get_visible_region_request( const struct get_visible_region_request *req )
2678 fprintf( stderr, " window=%p,", req->window );
2679 fprintf( stderr, " flags=%08x", req->flags );
2682 static void dump_get_visible_region_reply( const struct get_visible_region_reply *req )
2684 fprintf( stderr, " top_win=%p,", req->top_win );
2685 fprintf( stderr, " top_rect=" );
2686 dump_rectangle( &req->top_rect );
2687 fprintf( stderr, "," );
2688 fprintf( stderr, " win_rect=" );
2689 dump_rectangle( &req->win_rect );
2690 fprintf( stderr, "," );
2691 fprintf( stderr, " total_size=%u,", req->total_size );
2692 fprintf( stderr, " region=" );
2693 dump_varargs_rectangles( cur_size );
2696 static void dump_get_window_region_request( const struct get_window_region_request *req )
2698 fprintf( stderr, " window=%p", req->window );
2701 static void dump_get_window_region_reply( const struct get_window_region_reply *req )
2703 fprintf( stderr, " total_size=%u,", req->total_size );
2704 fprintf( stderr, " region=" );
2705 dump_varargs_rectangles( cur_size );
2708 static void dump_set_window_region_request( const struct set_window_region_request *req )
2710 fprintf( stderr, " window=%p,", req->window );
2711 fprintf( stderr, " region=" );
2712 dump_varargs_rectangles( cur_size );
2715 static void dump_get_update_region_request( const struct get_update_region_request *req )
2717 fprintf( stderr, " window=%p,", req->window );
2718 fprintf( stderr, " from_child=%p,", req->from_child );
2719 fprintf( stderr, " flags=%08x", req->flags );
2722 static void dump_get_update_region_reply( const struct get_update_region_reply *req )
2724 fprintf( stderr, " child=%p,", req->child );
2725 fprintf( stderr, " flags=%08x,", req->flags );
2726 fprintf( stderr, " total_size=%u,", req->total_size );
2727 fprintf( stderr, " region=" );
2728 dump_varargs_rectangles( cur_size );
2731 static void dump_update_window_zorder_request( const struct update_window_zorder_request *req )
2733 fprintf( stderr, " window=%p,", req->window );
2734 fprintf( stderr, " rect=" );
2735 dump_rectangle( &req->rect );
2738 static void dump_redraw_window_request( const struct redraw_window_request *req )
2740 fprintf( stderr, " window=%p,", req->window );
2741 fprintf( stderr, " flags=%08x,", req->flags );
2742 fprintf( stderr, " region=" );
2743 dump_varargs_rectangles( cur_size );
2746 static void dump_set_window_property_request( const struct set_window_property_request *req )
2748 fprintf( stderr, " window=%p,", req->window );
2749 fprintf( stderr, " atom=%04x,", req->atom );
2750 fprintf( stderr, " handle=%p,", req->handle );
2751 fprintf( stderr, " name=" );
2752 dump_varargs_unicode_str( cur_size );
2755 static void dump_remove_window_property_request( const struct remove_window_property_request *req )
2757 fprintf( stderr, " window=%p,", req->window );
2758 fprintf( stderr, " atom=%04x,", req->atom );
2759 fprintf( stderr, " name=" );
2760 dump_varargs_unicode_str( cur_size );
2763 static void dump_remove_window_property_reply( const struct remove_window_property_reply *req )
2765 fprintf( stderr, " handle=%p", req->handle );
2768 static void dump_get_window_property_request( const struct get_window_property_request *req )
2770 fprintf( stderr, " window=%p,", req->window );
2771 fprintf( stderr, " atom=%04x,", req->atom );
2772 fprintf( stderr, " name=" );
2773 dump_varargs_unicode_str( cur_size );
2776 static void dump_get_window_property_reply( const struct get_window_property_reply *req )
2778 fprintf( stderr, " handle=%p", req->handle );
2781 static void dump_get_window_properties_request( const struct get_window_properties_request *req )
2783 fprintf( stderr, " window=%p", req->window );
2786 static void dump_get_window_properties_reply( const struct get_window_properties_reply *req )
2788 fprintf( stderr, " total=%d,", req->total );
2789 fprintf( stderr, " props=" );
2790 dump_varargs_properties( cur_size );
2793 static void dump_create_winstation_request( const struct create_winstation_request *req )
2795 fprintf( stderr, " flags=%08x,", req->flags );
2796 fprintf( stderr, " access=%08x,", req->access );
2797 fprintf( stderr, " attributes=%08x,", req->attributes );
2798 fprintf( stderr, " name=" );
2799 dump_varargs_unicode_str( cur_size );
2802 static void dump_create_winstation_reply( const struct create_winstation_reply *req )
2804 fprintf( stderr, " handle=%p", req->handle );
2807 static void dump_open_winstation_request( const struct open_winstation_request *req )
2809 fprintf( stderr, " access=%08x,", req->access );
2810 fprintf( stderr, " attributes=%08x,", req->attributes );
2811 fprintf( stderr, " name=" );
2812 dump_varargs_unicode_str( cur_size );
2815 static void dump_open_winstation_reply( const struct open_winstation_reply *req )
2817 fprintf( stderr, " handle=%p", req->handle );
2820 static void dump_close_winstation_request( const struct close_winstation_request *req )
2822 fprintf( stderr, " handle=%p", req->handle );
2825 static void dump_get_process_winstation_request( const struct get_process_winstation_request *req )
2829 static void dump_get_process_winstation_reply( const struct get_process_winstation_reply *req )
2831 fprintf( stderr, " handle=%p", req->handle );
2834 static void dump_set_process_winstation_request( const struct set_process_winstation_request *req )
2836 fprintf( stderr, " handle=%p", req->handle );
2839 static void dump_create_desktop_request( const struct create_desktop_request *req )
2841 fprintf( stderr, " flags=%08x,", req->flags );
2842 fprintf( stderr, " access=%08x,", req->access );
2843 fprintf( stderr, " attributes=%08x,", req->attributes );
2844 fprintf( stderr, " name=" );
2845 dump_varargs_unicode_str( cur_size );
2848 static void dump_create_desktop_reply( const struct create_desktop_reply *req )
2850 fprintf( stderr, " handle=%p", req->handle );
2853 static void dump_open_desktop_request( const struct open_desktop_request *req )
2855 fprintf( stderr, " flags=%08x,", req->flags );
2856 fprintf( stderr, " access=%08x,", req->access );
2857 fprintf( stderr, " attributes=%08x,", req->attributes );
2858 fprintf( stderr, " name=" );
2859 dump_varargs_unicode_str( cur_size );
2862 static void dump_open_desktop_reply( const struct open_desktop_reply *req )
2864 fprintf( stderr, " handle=%p", req->handle );
2867 static void dump_close_desktop_request( const struct close_desktop_request *req )
2869 fprintf( stderr, " handle=%p", req->handle );
2872 static void dump_get_thread_desktop_request( const struct get_thread_desktop_request *req )
2874 fprintf( stderr, " tid=%04x", req->tid );
2877 static void dump_get_thread_desktop_reply( const struct get_thread_desktop_reply *req )
2879 fprintf( stderr, " handle=%p", req->handle );
2882 static void dump_set_thread_desktop_request( const struct set_thread_desktop_request *req )
2884 fprintf( stderr, " handle=%p", req->handle );
2887 static void dump_set_user_object_info_request( const struct set_user_object_info_request *req )
2889 fprintf( stderr, " handle=%p,", req->handle );
2890 fprintf( stderr, " flags=%08x,", req->flags );
2891 fprintf( stderr, " obj_flags=%08x", req->obj_flags );
2894 static void dump_set_user_object_info_reply( const struct set_user_object_info_reply *req )
2896 fprintf( stderr, " is_desktop=%d,", req->is_desktop );
2897 fprintf( stderr, " old_obj_flags=%08x,", req->old_obj_flags );
2898 fprintf( stderr, " name=" );
2899 dump_varargs_unicode_str( cur_size );
2902 static void dump_attach_thread_input_request( const struct attach_thread_input_request *req )
2904 fprintf( stderr, " tid_from=%04x,", req->tid_from );
2905 fprintf( stderr, " tid_to=%04x,", req->tid_to );
2906 fprintf( stderr, " attach=%d", req->attach );
2909 static void dump_get_thread_input_request( const struct get_thread_input_request *req )
2911 fprintf( stderr, " tid=%04x", req->tid );
2914 static void dump_get_thread_input_reply( const struct get_thread_input_reply *req )
2916 fprintf( stderr, " focus=%p,", req->focus );
2917 fprintf( stderr, " capture=%p,", req->capture );
2918 fprintf( stderr, " active=%p,", req->active );
2919 fprintf( stderr, " foreground=%p,", req->foreground );
2920 fprintf( stderr, " menu_owner=%p,", req->menu_owner );
2921 fprintf( stderr, " move_size=%p,", req->move_size );
2922 fprintf( stderr, " caret=%p,", req->caret );
2923 fprintf( stderr, " rect=" );
2924 dump_rectangle( &req->rect );
2927 static void dump_get_last_input_time_request( const struct get_last_input_time_request *req )
2931 static void dump_get_last_input_time_reply( const struct get_last_input_time_reply *req )
2933 fprintf( stderr, " time=%08x", req->time );
2936 static void dump_get_key_state_request( const struct get_key_state_request *req )
2938 fprintf( stderr, " tid=%04x,", req->tid );
2939 fprintf( stderr, " key=%d", req->key );
2942 static void dump_get_key_state_reply( const struct get_key_state_reply *req )
2944 fprintf( stderr, " state=%02x,", req->state );
2945 fprintf( stderr, " keystate=" );
2946 dump_varargs_bytes( cur_size );
2949 static void dump_set_key_state_request( const struct set_key_state_request *req )
2951 fprintf( stderr, " tid=%04x,", req->tid );
2952 fprintf( stderr, " keystate=" );
2953 dump_varargs_bytes( cur_size );
2956 static void dump_set_foreground_window_request( const struct set_foreground_window_request *req )
2958 fprintf( stderr, " handle=%p", req->handle );
2961 static void dump_set_foreground_window_reply( const struct set_foreground_window_reply *req )
2963 fprintf( stderr, " previous=%p,", req->previous );
2964 fprintf( stderr, " send_msg_old=%d,", req->send_msg_old );
2965 fprintf( stderr, " send_msg_new=%d", req->send_msg_new );
2968 static void dump_set_focus_window_request( const struct set_focus_window_request *req )
2970 fprintf( stderr, " handle=%p", req->handle );
2973 static void dump_set_focus_window_reply( const struct set_focus_window_reply *req )
2975 fprintf( stderr, " previous=%p", req->previous );
2978 static void dump_set_active_window_request( const struct set_active_window_request *req )
2980 fprintf( stderr, " handle=%p", req->handle );
2983 static void dump_set_active_window_reply( const struct set_active_window_reply *req )
2985 fprintf( stderr, " previous=%p", req->previous );
2988 static void dump_set_capture_window_request( const struct set_capture_window_request *req )
2990 fprintf( stderr, " handle=%p,", req->handle );
2991 fprintf( stderr, " flags=%08x", req->flags );
2994 static void dump_set_capture_window_reply( const struct set_capture_window_reply *req )
2996 fprintf( stderr, " previous=%p,", req->previous );
2997 fprintf( stderr, " full_handle=%p", req->full_handle );
3000 static void dump_set_caret_window_request( const struct set_caret_window_request *req )
3002 fprintf( stderr, " handle=%p,", req->handle );
3003 fprintf( stderr, " width=%d,", req->width );
3004 fprintf( stderr, " height=%d", req->height );
3007 static void dump_set_caret_window_reply( const struct set_caret_window_reply *req )
3009 fprintf( stderr, " previous=%p,", req->previous );
3010 fprintf( stderr, " old_rect=" );
3011 dump_rectangle( &req->old_rect );
3012 fprintf( stderr, "," );
3013 fprintf( stderr, " old_hide=%d,", req->old_hide );
3014 fprintf( stderr, " old_state=%d", req->old_state );
3017 static void dump_set_caret_info_request( const struct set_caret_info_request *req )
3019 fprintf( stderr, " flags=%08x,", req->flags );
3020 fprintf( stderr, " handle=%p,", req->handle );
3021 fprintf( stderr, " x=%d,", req->x );
3022 fprintf( stderr, " y=%d,", req->y );
3023 fprintf( stderr, " hide=%d,", req->hide );
3024 fprintf( stderr, " state=%d", req->state );
3027 static void dump_set_caret_info_reply( const struct set_caret_info_reply *req )
3029 fprintf( stderr, " full_handle=%p,", req->full_handle );
3030 fprintf( stderr, " old_rect=" );
3031 dump_rectangle( &req->old_rect );
3032 fprintf( stderr, "," );
3033 fprintf( stderr, " old_hide=%d,", req->old_hide );
3034 fprintf( stderr, " old_state=%d", req->old_state );
3037 static void dump_set_hook_request( const struct set_hook_request *req )
3039 fprintf( stderr, " id=%d,", req->id );
3040 fprintf( stderr, " pid=%04x,", req->pid );
3041 fprintf( stderr, " tid=%04x,", req->tid );
3042 fprintf( stderr, " event_min=%d,", req->event_min );
3043 fprintf( stderr, " event_max=%d,", req->event_max );
3044 fprintf( stderr, " flags=%d,", req->flags );
3045 fprintf( stderr, " proc=%p,", req->proc );
3046 fprintf( stderr, " unicode=%d,", req->unicode );
3047 fprintf( stderr, " module=" );
3048 dump_varargs_unicode_str( cur_size );
3051 static void dump_set_hook_reply( const struct set_hook_reply *req )
3053 fprintf( stderr, " handle=%p,", req->handle );
3054 fprintf( stderr, " active_hooks=%08x", req->active_hooks );
3057 static void dump_remove_hook_request( const struct remove_hook_request *req )
3059 fprintf( stderr, " handle=%p,", req->handle );
3060 fprintf( stderr, " id=%d,", req->id );
3061 fprintf( stderr, " proc=%p", req->proc );
3064 static void dump_remove_hook_reply( const struct remove_hook_reply *req )
3066 fprintf( stderr, " active_hooks=%08x", req->active_hooks );
3069 static void dump_start_hook_chain_request( const struct start_hook_chain_request *req )
3071 fprintf( stderr, " id=%d,", req->id );
3072 fprintf( stderr, " event=%d,", req->event );
3073 fprintf( stderr, " window=%p,", req->window );
3074 fprintf( stderr, " object_id=%d,", req->object_id );
3075 fprintf( stderr, " child_id=%d", req->child_id );
3078 static void dump_start_hook_chain_reply( const struct start_hook_chain_reply *req )
3080 fprintf( stderr, " handle=%p,", req->handle );
3081 fprintf( stderr, " pid=%04x,", req->pid );
3082 fprintf( stderr, " tid=%04x,", req->tid );
3083 fprintf( stderr, " proc=%p,", req->proc );
3084 fprintf( stderr, " unicode=%d,", req->unicode );
3085 fprintf( stderr, " active_hooks=%08x,", req->active_hooks );
3086 fprintf( stderr, " module=" );
3087 dump_varargs_unicode_str( cur_size );
3090 static void dump_finish_hook_chain_request( const struct finish_hook_chain_request *req )
3092 fprintf( stderr, " id=%d", req->id );
3095 static void dump_get_hook_info_request( const struct get_hook_info_request *req )
3097 fprintf( stderr, " handle=%p,", req->handle );
3098 fprintf( stderr, " get_next=%d,", req->get_next );
3099 fprintf( stderr, " event=%d,", req->event );
3100 fprintf( stderr, " window=%p,", req->window );
3101 fprintf( stderr, " object_id=%d,", req->object_id );
3102 fprintf( stderr, " child_id=%d", req->child_id );
3105 static void dump_get_hook_info_reply( const struct get_hook_info_reply *req )
3107 fprintf( stderr, " handle=%p,", req->handle );
3108 fprintf( stderr, " id=%d,", req->id );
3109 fprintf( stderr, " pid=%04x,", req->pid );
3110 fprintf( stderr, " tid=%04x,", req->tid );
3111 fprintf( stderr, " proc=%p,", req->proc );
3112 fprintf( stderr, " unicode=%d,", req->unicode );
3113 fprintf( stderr, " module=" );
3114 dump_varargs_unicode_str( cur_size );
3117 static void dump_create_class_request( const struct create_class_request *req )
3119 fprintf( stderr, " local=%d,", req->local );
3120 fprintf( stderr, " atom=%04x,", req->atom );
3121 fprintf( stderr, " style=%08x,", req->style );
3122 fprintf( stderr, " instance=%p,", req->instance );
3123 fprintf( stderr, " extra=%d,", req->extra );
3124 fprintf( stderr, " win_extra=%d,", req->win_extra );
3125 fprintf( stderr, " client_ptr=%p", req->client_ptr );
3128 static void dump_destroy_class_request( const struct destroy_class_request *req )
3130 fprintf( stderr, " atom=%04x,", req->atom );
3131 fprintf( stderr, " instance=%p", req->instance );
3134 static void dump_destroy_class_reply( const struct destroy_class_reply *req )
3136 fprintf( stderr, " client_ptr=%p", req->client_ptr );
3139 static void dump_set_class_info_request( const struct set_class_info_request *req )
3141 fprintf( stderr, " window=%p,", req->window );
3142 fprintf( stderr, " flags=%08x,", req->flags );
3143 fprintf( stderr, " atom=%04x,", req->atom );
3144 fprintf( stderr, " style=%08x,", req->style );
3145 fprintf( stderr, " win_extra=%d,", req->win_extra );
3146 fprintf( stderr, " instance=%p,", req->instance );
3147 fprintf( stderr, " extra_offset=%d,", req->extra_offset );
3148 fprintf( stderr, " extra_size=%u,", req->extra_size );
3149 fprintf( stderr, " extra_value=%lx", req->extra_value );
3152 static void dump_set_class_info_reply( const struct set_class_info_reply *req )
3154 fprintf( stderr, " old_atom=%04x,", req->old_atom );
3155 fprintf( stderr, " old_style=%08x,", req->old_style );
3156 fprintf( stderr, " old_extra=%d,", req->old_extra );
3157 fprintf( stderr, " old_win_extra=%d,", req->old_win_extra );
3158 fprintf( stderr, " old_instance=%p,", req->old_instance );
3159 fprintf( stderr, " old_extra_value=%lx", req->old_extra_value );
3162 static void dump_set_clipboard_info_request( const struct set_clipboard_info_request *req )
3164 fprintf( stderr, " flags=%08x,", req->flags );
3165 fprintf( stderr, " clipboard=%p,", req->clipboard );
3166 fprintf( stderr, " owner=%p,", req->owner );
3167 fprintf( stderr, " viewer=%p,", req->viewer );
3168 fprintf( stderr, " seqno=%08x", req->seqno );
3171 static void dump_set_clipboard_info_reply( const struct set_clipboard_info_reply *req )
3173 fprintf( stderr, " flags=%08x,", req->flags );
3174 fprintf( stderr, " old_clipboard=%p,", req->old_clipboard );
3175 fprintf( stderr, " old_owner=%p,", req->old_owner );
3176 fprintf( stderr, " old_viewer=%p,", req->old_viewer );
3177 fprintf( stderr, " seqno=%08x", req->seqno );
3180 static void dump_open_token_request( const struct open_token_request *req )
3182 fprintf( stderr, " handle=%p,", req->handle );
3183 fprintf( stderr, " access=%08x,", req->access );
3184 fprintf( stderr, " attributes=%08x,", req->attributes );
3185 fprintf( stderr, " flags=%08x", req->flags );
3188 static void dump_open_token_reply( const struct open_token_reply *req )
3190 fprintf( stderr, " token=%p", req->token );
3193 static void dump_set_global_windows_request( const struct set_global_windows_request *req )
3195 fprintf( stderr, " flags=%08x,", req->flags );
3196 fprintf( stderr, " shell_window=%p,", req->shell_window );
3197 fprintf( stderr, " shell_listview=%p,", req->shell_listview );
3198 fprintf( stderr, " progman_window=%p,", req->progman_window );
3199 fprintf( stderr, " taskman_window=%p", req->taskman_window );
3202 static void dump_set_global_windows_reply( const struct set_global_windows_reply *req )
3204 fprintf( stderr, " old_shell_window=%p,", req->old_shell_window );
3205 fprintf( stderr, " old_shell_listview=%p,", req->old_shell_listview );
3206 fprintf( stderr, " old_progman_window=%p,", req->old_progman_window );
3207 fprintf( stderr, " old_taskman_window=%p", req->old_taskman_window );
3210 static void dump_adjust_token_privileges_request( const struct adjust_token_privileges_request *req )
3212 fprintf( stderr, " handle=%p,", req->handle );
3213 fprintf( stderr, " disable_all=%d,", req->disable_all );
3214 fprintf( stderr, " get_modified_state=%d,", req->get_modified_state );
3215 fprintf( stderr, " privileges=" );
3216 dump_varargs_LUID_AND_ATTRIBUTES( cur_size );
3219 static void dump_adjust_token_privileges_reply( const struct adjust_token_privileges_reply *req )
3221 fprintf( stderr, " len=%08x,", req->len );
3222 fprintf( stderr, " privileges=" );
3223 dump_varargs_LUID_AND_ATTRIBUTES( cur_size );
3226 static void dump_get_token_privileges_request( const struct get_token_privileges_request *req )
3228 fprintf( stderr, " handle=%p", req->handle );
3231 static void dump_get_token_privileges_reply( const struct get_token_privileges_reply *req )
3233 fprintf( stderr, " len=%08x,", req->len );
3234 fprintf( stderr, " privileges=" );
3235 dump_varargs_LUID_AND_ATTRIBUTES( cur_size );
3238 static void dump_check_token_privileges_request( const struct check_token_privileges_request *req )
3240 fprintf( stderr, " handle=%p,", req->handle );
3241 fprintf( stderr, " all_required=%d,", req->all_required );
3242 fprintf( stderr, " privileges=" );
3243 dump_varargs_LUID_AND_ATTRIBUTES( cur_size );
3246 static void dump_check_token_privileges_reply( const struct check_token_privileges_reply *req )
3248 fprintf( stderr, " has_privileges=%d,", req->has_privileges );
3249 fprintf( stderr, " privileges=" );
3250 dump_varargs_LUID_AND_ATTRIBUTES( cur_size );
3253 static void dump_duplicate_token_request( const struct duplicate_token_request *req )
3255 fprintf( stderr, " handle=%p,", req->handle );
3256 fprintf( stderr, " access=%08x,", req->access );
3257 fprintf( stderr, " attributes=%08x,", req->attributes );
3258 fprintf( stderr, " primary=%d,", req->primary );
3259 fprintf( stderr, " impersonation_level=%d", req->impersonation_level );
3262 static void dump_duplicate_token_reply( const struct duplicate_token_reply *req )
3264 fprintf( stderr, " new_handle=%p", req->new_handle );
3267 static void dump_access_check_request( const struct access_check_request *req )
3269 fprintf( stderr, " handle=%p,", req->handle );
3270 fprintf( stderr, " desired_access=%08x,", req->desired_access );
3271 fprintf( stderr, " mapping_read=%08x,", req->mapping_read );
3272 fprintf( stderr, " mapping_write=%08x,", req->mapping_write );
3273 fprintf( stderr, " mapping_execute=%08x,", req->mapping_execute );
3274 fprintf( stderr, " mapping_all=%08x,", req->mapping_all );
3275 fprintf( stderr, " sd=" );
3276 dump_varargs_security_descriptor( cur_size );
3279 static void dump_access_check_reply( const struct access_check_reply *req )
3281 fprintf( stderr, " access_granted=%08x,", req->access_granted );
3282 fprintf( stderr, " access_status=%08x,", req->access_status );
3283 fprintf( stderr, " privileges_len=%08x,", req->privileges_len );
3284 fprintf( stderr, " privileges=" );
3285 dump_varargs_LUID_AND_ATTRIBUTES( cur_size );
3288 static void dump_get_token_user_request( const struct get_token_user_request *req )
3290 fprintf( stderr, " handle=%p", req->handle );
3293 static void dump_get_token_user_reply( const struct get_token_user_reply *req )
3295 fprintf( stderr, " user_len=%u,", req->user_len );
3296 fprintf( stderr, " user=" );
3297 dump_varargs_SID( cur_size );
3300 static void dump_get_token_groups_request( const struct get_token_groups_request *req )
3302 fprintf( stderr, " handle=%p", req->handle );
3305 static void dump_get_token_groups_reply( const struct get_token_groups_reply *req )
3307 fprintf( stderr, " user_len=%u,", req->user_len );
3308 fprintf( stderr, " user=" );
3309 dump_varargs_token_groups( cur_size );
3312 static void dump_create_mailslot_request( const struct create_mailslot_request *req )
3314 fprintf( stderr, " access=%08x,", req->access );
3315 fprintf( stderr, " attributes=%08x,", req->attributes );
3316 fprintf( stderr, " rootdir=%p,", req->rootdir );
3317 fprintf( stderr, " max_msgsize=%08x,", req->max_msgsize );
3318 fprintf( stderr, " read_timeout=%d,", req->read_timeout );
3319 fprintf( stderr, " name=" );
3320 dump_varargs_unicode_str( cur_size );
3323 static void dump_create_mailslot_reply( const struct create_mailslot_reply *req )
3325 fprintf( stderr, " handle=%p", req->handle );
3328 static void dump_open_mailslot_request( const struct open_mailslot_request *req )
3330 fprintf( stderr, " access=%08x,", req->access );
3331 fprintf( stderr, " attributes=%08x,", req->attributes );
3332 fprintf( stderr, " rootdir=%p,", req->rootdir );
3333 fprintf( stderr, " sharing=%08x,", req->sharing );
3334 fprintf( stderr, " name=" );
3335 dump_varargs_unicode_str( cur_size );
3338 static void dump_open_mailslot_reply( const struct open_mailslot_reply *req )
3340 fprintf( stderr, " handle=%p", req->handle );
3343 static void dump_set_mailslot_info_request( const struct set_mailslot_info_request *req )
3345 fprintf( stderr, " handle=%p,", req->handle );
3346 fprintf( stderr, " flags=%08x,", req->flags );
3347 fprintf( stderr, " read_timeout=%d", req->read_timeout );
3350 static void dump_set_mailslot_info_reply( const struct set_mailslot_info_reply *req )
3352 fprintf( stderr, " max_msgsize=%08x,", req->max_msgsize );
3353 fprintf( stderr, " read_timeout=%d", req->read_timeout );
3356 static void dump_create_directory_request( const struct create_directory_request *req )
3358 fprintf( stderr, " access=%08x,", req->access );
3359 fprintf( stderr, " attributes=%08x,", req->attributes );
3360 fprintf( stderr, " rootdir=%p,", req->rootdir );
3361 fprintf( stderr, " directory_name=" );
3362 dump_varargs_unicode_str( cur_size );
3365 static void dump_create_directory_reply( const struct create_directory_reply *req )
3367 fprintf( stderr, " handle=%p", req->handle );
3370 static void dump_open_directory_request( const struct open_directory_request *req )
3372 fprintf( stderr, " access=%08x,", req->access );
3373 fprintf( stderr, " attributes=%08x,", req->attributes );
3374 fprintf( stderr, " rootdir=%p,", req->rootdir );
3375 fprintf( stderr, " directory_name=" );
3376 dump_varargs_unicode_str( cur_size );
3379 static void dump_open_directory_reply( const struct open_directory_reply *req )
3381 fprintf( stderr, " handle=%p", req->handle );
3384 static void dump_create_symlink_request( const struct create_symlink_request *req )
3386 fprintf( stderr, " access=%08x,", req->access );
3387 fprintf( stderr, " attributes=%08x,", req->attributes );
3388 fprintf( stderr, " rootdir=%p,", req->rootdir );
3389 fprintf( stderr, " name_len=%u,", req->name_len );
3390 fprintf( stderr, " name=" );
3391 dump_varargs_unicode_str( min(cur_size,req->name_len) );
3392 fputc( ',', stderr );
3393 fprintf( stderr, " target_name=" );
3394 dump_varargs_unicode_str( cur_size );
3397 static void dump_create_symlink_reply( const struct create_symlink_reply *req )
3399 fprintf( stderr, " handle=%p", req->handle );
3402 static void dump_open_symlink_request( const struct open_symlink_request *req )
3404 fprintf( stderr, " access=%08x,", req->access );
3405 fprintf( stderr, " attributes=%08x,", req->attributes );
3406 fprintf( stderr, " rootdir=%p,", req->rootdir );
3407 fprintf( stderr, " name=" );
3408 dump_varargs_unicode_str( cur_size );
3411 static void dump_open_symlink_reply( const struct open_symlink_reply *req )
3413 fprintf( stderr, " handle=%p", req->handle );
3416 static void dump_query_symlink_request( const struct query_symlink_request *req )
3418 fprintf( stderr, " handle=%p", req->handle );
3421 static void dump_query_symlink_reply( const struct query_symlink_reply *req )
3423 fprintf( stderr, " target_name=" );
3424 dump_varargs_unicode_str( cur_size );
3427 static const dump_func req_dumpers[REQ_NB_REQUESTS] = {
3428 (dump_func)dump_new_process_request,
3429 (dump_func)dump_get_new_process_info_request,
3430 (dump_func)dump_new_thread_request,
3431 (dump_func)dump_get_startup_info_request,
3432 (dump_func)dump_init_process_done_request,
3433 (dump_func)dump_init_thread_request,
3434 (dump_func)dump_terminate_process_request,
3435 (dump_func)dump_terminate_thread_request,
3436 (dump_func)dump_get_process_info_request,
3437 (dump_func)dump_set_process_info_request,
3438 (dump_func)dump_get_thread_info_request,
3439 (dump_func)dump_set_thread_info_request,
3440 (dump_func)dump_get_dll_info_request,
3441 (dump_func)dump_suspend_thread_request,
3442 (dump_func)dump_resume_thread_request,
3443 (dump_func)dump_load_dll_request,
3444 (dump_func)dump_unload_dll_request,
3445 (dump_func)dump_queue_apc_request,
3446 (dump_func)dump_get_apc_request,
3447 (dump_func)dump_get_apc_result_request,
3448 (dump_func)dump_close_handle_request,
3449 (dump_func)dump_set_handle_info_request,
3450 (dump_func)dump_dup_handle_request,
3451 (dump_func)dump_open_process_request,
3452 (dump_func)dump_open_thread_request,
3453 (dump_func)dump_select_request,
3454 (dump_func)dump_create_event_request,
3455 (dump_func)dump_event_op_request,
3456 (dump_func)dump_open_event_request,
3457 (dump_func)dump_create_mutex_request,
3458 (dump_func)dump_release_mutex_request,
3459 (dump_func)dump_open_mutex_request,
3460 (dump_func)dump_create_semaphore_request,
3461 (dump_func)dump_release_semaphore_request,
3462 (dump_func)dump_open_semaphore_request,
3463 (dump_func)dump_create_file_request,
3464 (dump_func)dump_open_file_object_request,
3465 (dump_func)dump_alloc_file_handle_request,
3466 (dump_func)dump_get_handle_fd_request,
3467 (dump_func)dump_flush_file_request,
3468 (dump_func)dump_lock_file_request,
3469 (dump_func)dump_unlock_file_request,
3470 (dump_func)dump_unmount_device_request,
3471 (dump_func)dump_create_socket_request,
3472 (dump_func)dump_accept_socket_request,
3473 (dump_func)dump_set_socket_event_request,
3474 (dump_func)dump_get_socket_event_request,
3475 (dump_func)dump_enable_socket_event_request,
3476 (dump_func)dump_set_socket_deferred_request,
3477 (dump_func)dump_alloc_console_request,
3478 (dump_func)dump_free_console_request,
3479 (dump_func)dump_get_console_renderer_events_request,
3480 (dump_func)dump_open_console_request,
3481 (dump_func)dump_get_console_wait_event_request,
3482 (dump_func)dump_get_console_mode_request,
3483 (dump_func)dump_set_console_mode_request,
3484 (dump_func)dump_set_console_input_info_request,
3485 (dump_func)dump_get_console_input_info_request,
3486 (dump_func)dump_append_console_input_history_request,
3487 (dump_func)dump_get_console_input_history_request,
3488 (dump_func)dump_create_console_output_request,
3489 (dump_func)dump_set_console_output_info_request,
3490 (dump_func)dump_get_console_output_info_request,
3491 (dump_func)dump_write_console_input_request,
3492 (dump_func)dump_read_console_input_request,
3493 (dump_func)dump_write_console_output_request,
3494 (dump_func)dump_fill_console_output_request,
3495 (dump_func)dump_read_console_output_request,
3496 (dump_func)dump_move_console_output_request,
3497 (dump_func)dump_send_console_signal_request,
3498 (dump_func)dump_read_directory_changes_request,
3499 (dump_func)dump_read_change_request,
3500 (dump_func)dump_create_mapping_request,
3501 (dump_func)dump_open_mapping_request,
3502 (dump_func)dump_get_mapping_info_request,
3503 (dump_func)dump_create_snapshot_request,
3504 (dump_func)dump_next_process_request,
3505 (dump_func)dump_next_thread_request,
3506 (dump_func)dump_next_module_request,
3507 (dump_func)dump_wait_debug_event_request,
3508 (dump_func)dump_queue_exception_event_request,
3509 (dump_func)dump_get_exception_status_request,
3510 (dump_func)dump_output_debug_string_request,
3511 (dump_func)dump_continue_debug_event_request,
3512 (dump_func)dump_debug_process_request,
3513 (dump_func)dump_debug_break_request,
3514 (dump_func)dump_set_debugger_kill_on_exit_request,
3515 (dump_func)dump_read_process_memory_request,
3516 (dump_func)dump_write_process_memory_request,
3517 (dump_func)dump_create_key_request,
3518 (dump_func)dump_open_key_request,
3519 (dump_func)dump_delete_key_request,
3520 (dump_func)dump_flush_key_request,
3521 (dump_func)dump_enum_key_request,
3522 (dump_func)dump_set_key_value_request,
3523 (dump_func)dump_get_key_value_request,
3524 (dump_func)dump_enum_key_value_request,
3525 (dump_func)dump_delete_key_value_request,
3526 (dump_func)dump_load_registry_request,
3527 (dump_func)dump_unload_registry_request,
3528 (dump_func)dump_save_registry_request,
3529 (dump_func)dump_set_registry_notification_request,
3530 (dump_func)dump_create_timer_request,
3531 (dump_func)dump_open_timer_request,
3532 (dump_func)dump_set_timer_request,
3533 (dump_func)dump_cancel_timer_request,
3534 (dump_func)dump_get_timer_info_request,
3535 (dump_func)dump_get_thread_context_request,
3536 (dump_func)dump_set_thread_context_request,
3537 (dump_func)dump_get_selector_entry_request,
3538 (dump_func)dump_add_atom_request,
3539 (dump_func)dump_delete_atom_request,
3540 (dump_func)dump_find_atom_request,
3541 (dump_func)dump_get_atom_information_request,
3542 (dump_func)dump_set_atom_information_request,
3543 (dump_func)dump_empty_atom_table_request,
3544 (dump_func)dump_init_atom_table_request,
3545 (dump_func)dump_get_msg_queue_request,
3546 (dump_func)dump_set_queue_mask_request,
3547 (dump_func)dump_get_queue_status_request,
3548 (dump_func)dump_get_process_idle_event_request,
3549 (dump_func)dump_send_message_request,
3550 (dump_func)dump_post_quit_message_request,
3551 (dump_func)dump_send_hardware_message_request,
3552 (dump_func)dump_get_message_request,
3553 (dump_func)dump_reply_message_request,
3554 (dump_func)dump_accept_hardware_message_request,
3555 (dump_func)dump_get_message_reply_request,
3556 (dump_func)dump_set_win_timer_request,
3557 (dump_func)dump_kill_win_timer_request,
3558 (dump_func)dump_get_serial_info_request,
3559 (dump_func)dump_set_serial_info_request,
3560 (dump_func)dump_register_async_request,
3561 (dump_func)dump_cancel_async_request,
3562 (dump_func)dump_create_named_pipe_request,
3563 (dump_func)dump_open_named_pipe_request,
3564 (dump_func)dump_connect_named_pipe_request,
3565 (dump_func)dump_wait_named_pipe_request,
3566 (dump_func)dump_disconnect_named_pipe_request,
3567 (dump_func)dump_get_named_pipe_info_request,
3568 (dump_func)dump_create_window_request,
3569 (dump_func)dump_destroy_window_request,
3570 (dump_func)dump_get_desktop_window_request,
3571 (dump_func)dump_set_window_owner_request,
3572 (dump_func)dump_get_window_info_request,
3573 (dump_func)dump_set_window_info_request,
3574 (dump_func)dump_set_parent_request,
3575 (dump_func)dump_get_window_parents_request,
3576 (dump_func)dump_get_window_children_request,
3577 (dump_func)dump_get_window_children_from_point_request,
3578 (dump_func)dump_get_window_tree_request,
3579 (dump_func)dump_set_window_pos_request,
3580 (dump_func)dump_get_window_rectangles_request,
3581 (dump_func)dump_get_window_text_request,
3582 (dump_func)dump_set_window_text_request,
3583 (dump_func)dump_get_windows_offset_request,
3584 (dump_func)dump_get_visible_region_request,
3585 (dump_func)dump_get_window_region_request,
3586 (dump_func)dump_set_window_region_request,
3587 (dump_func)dump_get_update_region_request,
3588 (dump_func)dump_update_window_zorder_request,
3589 (dump_func)dump_redraw_window_request,
3590 (dump_func)dump_set_window_property_request,
3591 (dump_func)dump_remove_window_property_request,
3592 (dump_func)dump_get_window_property_request,
3593 (dump_func)dump_get_window_properties_request,
3594 (dump_func)dump_create_winstation_request,
3595 (dump_func)dump_open_winstation_request,
3596 (dump_func)dump_close_winstation_request,
3597 (dump_func)dump_get_process_winstation_request,
3598 (dump_func)dump_set_process_winstation_request,
3599 (dump_func)dump_create_desktop_request,
3600 (dump_func)dump_open_desktop_request,
3601 (dump_func)dump_close_desktop_request,
3602 (dump_func)dump_get_thread_desktop_request,
3603 (dump_func)dump_set_thread_desktop_request,
3604 (dump_func)dump_set_user_object_info_request,
3605 (dump_func)dump_attach_thread_input_request,
3606 (dump_func)dump_get_thread_input_request,
3607 (dump_func)dump_get_last_input_time_request,
3608 (dump_func)dump_get_key_state_request,
3609 (dump_func)dump_set_key_state_request,
3610 (dump_func)dump_set_foreground_window_request,
3611 (dump_func)dump_set_focus_window_request,
3612 (dump_func)dump_set_active_window_request,
3613 (dump_func)dump_set_capture_window_request,
3614 (dump_func)dump_set_caret_window_request,
3615 (dump_func)dump_set_caret_info_request,
3616 (dump_func)dump_set_hook_request,
3617 (dump_func)dump_remove_hook_request,
3618 (dump_func)dump_start_hook_chain_request,
3619 (dump_func)dump_finish_hook_chain_request,
3620 (dump_func)dump_get_hook_info_request,
3621 (dump_func)dump_create_class_request,
3622 (dump_func)dump_destroy_class_request,
3623 (dump_func)dump_set_class_info_request,
3624 (dump_func)dump_set_clipboard_info_request,
3625 (dump_func)dump_open_token_request,
3626 (dump_func)dump_set_global_windows_request,
3627 (dump_func)dump_adjust_token_privileges_request,
3628 (dump_func)dump_get_token_privileges_request,
3629 (dump_func)dump_check_token_privileges_request,
3630 (dump_func)dump_duplicate_token_request,
3631 (dump_func)dump_access_check_request,
3632 (dump_func)dump_get_token_user_request,
3633 (dump_func)dump_get_token_groups_request,
3634 (dump_func)dump_create_mailslot_request,
3635 (dump_func)dump_open_mailslot_request,
3636 (dump_func)dump_set_mailslot_info_request,
3637 (dump_func)dump_create_directory_request,
3638 (dump_func)dump_open_directory_request,
3639 (dump_func)dump_create_symlink_request,
3640 (dump_func)dump_open_symlink_request,
3641 (dump_func)dump_query_symlink_request,
3644 static const dump_func reply_dumpers[REQ_NB_REQUESTS] = {
3645 (dump_func)dump_new_process_reply,
3646 (dump_func)dump_get_new_process_info_reply,
3647 (dump_func)dump_new_thread_reply,
3648 (dump_func)dump_get_startup_info_reply,
3649 (dump_func)0,
3650 (dump_func)dump_init_thread_reply,
3651 (dump_func)dump_terminate_process_reply,
3652 (dump_func)dump_terminate_thread_reply,
3653 (dump_func)dump_get_process_info_reply,
3654 (dump_func)0,
3655 (dump_func)dump_get_thread_info_reply,
3656 (dump_func)0,
3657 (dump_func)dump_get_dll_info_reply,
3658 (dump_func)dump_suspend_thread_reply,
3659 (dump_func)dump_resume_thread_reply,
3660 (dump_func)0,
3661 (dump_func)0,
3662 (dump_func)dump_queue_apc_reply,
3663 (dump_func)dump_get_apc_reply,
3664 (dump_func)dump_get_apc_result_reply,
3665 (dump_func)0,
3666 (dump_func)dump_set_handle_info_reply,
3667 (dump_func)dump_dup_handle_reply,
3668 (dump_func)dump_open_process_reply,
3669 (dump_func)dump_open_thread_reply,
3670 (dump_func)0,
3671 (dump_func)dump_create_event_reply,
3672 (dump_func)0,
3673 (dump_func)dump_open_event_reply,
3674 (dump_func)dump_create_mutex_reply,
3675 (dump_func)dump_release_mutex_reply,
3676 (dump_func)dump_open_mutex_reply,
3677 (dump_func)dump_create_semaphore_reply,
3678 (dump_func)dump_release_semaphore_reply,
3679 (dump_func)dump_open_semaphore_reply,
3680 (dump_func)dump_create_file_reply,
3681 (dump_func)dump_open_file_object_reply,
3682 (dump_func)dump_alloc_file_handle_reply,
3683 (dump_func)dump_get_handle_fd_reply,
3684 (dump_func)dump_flush_file_reply,
3685 (dump_func)dump_lock_file_reply,
3686 (dump_func)0,
3687 (dump_func)0,
3688 (dump_func)dump_create_socket_reply,
3689 (dump_func)dump_accept_socket_reply,
3690 (dump_func)0,
3691 (dump_func)dump_get_socket_event_reply,
3692 (dump_func)0,
3693 (dump_func)0,
3694 (dump_func)dump_alloc_console_reply,
3695 (dump_func)0,
3696 (dump_func)dump_get_console_renderer_events_reply,
3697 (dump_func)dump_open_console_reply,
3698 (dump_func)dump_get_console_wait_event_reply,
3699 (dump_func)dump_get_console_mode_reply,
3700 (dump_func)0,
3701 (dump_func)0,
3702 (dump_func)dump_get_console_input_info_reply,
3703 (dump_func)0,
3704 (dump_func)dump_get_console_input_history_reply,
3705 (dump_func)dump_create_console_output_reply,
3706 (dump_func)0,
3707 (dump_func)dump_get_console_output_info_reply,
3708 (dump_func)dump_write_console_input_reply,
3709 (dump_func)dump_read_console_input_reply,
3710 (dump_func)dump_write_console_output_reply,
3711 (dump_func)dump_fill_console_output_reply,
3712 (dump_func)dump_read_console_output_reply,
3713 (dump_func)0,
3714 (dump_func)0,
3715 (dump_func)0,
3716 (dump_func)dump_read_change_reply,
3717 (dump_func)dump_create_mapping_reply,
3718 (dump_func)dump_open_mapping_reply,
3719 (dump_func)dump_get_mapping_info_reply,
3720 (dump_func)dump_create_snapshot_reply,
3721 (dump_func)dump_next_process_reply,
3722 (dump_func)dump_next_thread_reply,
3723 (dump_func)dump_next_module_reply,
3724 (dump_func)dump_wait_debug_event_reply,
3725 (dump_func)dump_queue_exception_event_reply,
3726 (dump_func)dump_get_exception_status_reply,
3727 (dump_func)0,
3728 (dump_func)0,
3729 (dump_func)0,
3730 (dump_func)dump_debug_break_reply,
3731 (dump_func)0,
3732 (dump_func)dump_read_process_memory_reply,
3733 (dump_func)0,
3734 (dump_func)dump_create_key_reply,
3735 (dump_func)dump_open_key_reply,
3736 (dump_func)0,
3737 (dump_func)0,
3738 (dump_func)dump_enum_key_reply,
3739 (dump_func)0,
3740 (dump_func)dump_get_key_value_reply,
3741 (dump_func)dump_enum_key_value_reply,
3742 (dump_func)0,
3743 (dump_func)0,
3744 (dump_func)0,
3745 (dump_func)0,
3746 (dump_func)0,
3747 (dump_func)dump_create_timer_reply,
3748 (dump_func)dump_open_timer_reply,
3749 (dump_func)dump_set_timer_reply,
3750 (dump_func)dump_cancel_timer_reply,
3751 (dump_func)dump_get_timer_info_reply,
3752 (dump_func)dump_get_thread_context_reply,
3753 (dump_func)dump_set_thread_context_reply,
3754 (dump_func)dump_get_selector_entry_reply,
3755 (dump_func)dump_add_atom_reply,
3756 (dump_func)0,
3757 (dump_func)dump_find_atom_reply,
3758 (dump_func)dump_get_atom_information_reply,
3759 (dump_func)0,
3760 (dump_func)0,
3761 (dump_func)dump_init_atom_table_reply,
3762 (dump_func)dump_get_msg_queue_reply,
3763 (dump_func)dump_set_queue_mask_reply,
3764 (dump_func)dump_get_queue_status_reply,
3765 (dump_func)dump_get_process_idle_event_reply,
3766 (dump_func)0,
3767 (dump_func)0,
3768 (dump_func)0,
3769 (dump_func)dump_get_message_reply,
3770 (dump_func)0,
3771 (dump_func)0,
3772 (dump_func)dump_get_message_reply_reply,
3773 (dump_func)dump_set_win_timer_reply,
3774 (dump_func)0,
3775 (dump_func)dump_get_serial_info_reply,
3776 (dump_func)0,
3777 (dump_func)0,
3778 (dump_func)0,
3779 (dump_func)dump_create_named_pipe_reply,
3780 (dump_func)dump_open_named_pipe_reply,
3781 (dump_func)0,
3782 (dump_func)0,
3783 (dump_func)0,
3784 (dump_func)dump_get_named_pipe_info_reply,
3785 (dump_func)dump_create_window_reply,
3786 (dump_func)0,
3787 (dump_func)dump_get_desktop_window_reply,
3788 (dump_func)dump_set_window_owner_reply,
3789 (dump_func)dump_get_window_info_reply,
3790 (dump_func)dump_set_window_info_reply,
3791 (dump_func)dump_set_parent_reply,
3792 (dump_func)dump_get_window_parents_reply,
3793 (dump_func)dump_get_window_children_reply,
3794 (dump_func)dump_get_window_children_from_point_reply,
3795 (dump_func)dump_get_window_tree_reply,
3796 (dump_func)dump_set_window_pos_reply,
3797 (dump_func)dump_get_window_rectangles_reply,
3798 (dump_func)dump_get_window_text_reply,
3799 (dump_func)0,
3800 (dump_func)dump_get_windows_offset_reply,
3801 (dump_func)dump_get_visible_region_reply,
3802 (dump_func)dump_get_window_region_reply,
3803 (dump_func)0,
3804 (dump_func)dump_get_update_region_reply,
3805 (dump_func)0,
3806 (dump_func)0,
3807 (dump_func)0,
3808 (dump_func)dump_remove_window_property_reply,
3809 (dump_func)dump_get_window_property_reply,
3810 (dump_func)dump_get_window_properties_reply,
3811 (dump_func)dump_create_winstation_reply,
3812 (dump_func)dump_open_winstation_reply,
3813 (dump_func)0,
3814 (dump_func)dump_get_process_winstation_reply,
3815 (dump_func)0,
3816 (dump_func)dump_create_desktop_reply,
3817 (dump_func)dump_open_desktop_reply,
3818 (dump_func)0,
3819 (dump_func)dump_get_thread_desktop_reply,
3820 (dump_func)0,
3821 (dump_func)dump_set_user_object_info_reply,
3822 (dump_func)0,
3823 (dump_func)dump_get_thread_input_reply,
3824 (dump_func)dump_get_last_input_time_reply,
3825 (dump_func)dump_get_key_state_reply,
3826 (dump_func)0,
3827 (dump_func)dump_set_foreground_window_reply,
3828 (dump_func)dump_set_focus_window_reply,
3829 (dump_func)dump_set_active_window_reply,
3830 (dump_func)dump_set_capture_window_reply,
3831 (dump_func)dump_set_caret_window_reply,
3832 (dump_func)dump_set_caret_info_reply,
3833 (dump_func)dump_set_hook_reply,
3834 (dump_func)dump_remove_hook_reply,
3835 (dump_func)dump_start_hook_chain_reply,
3836 (dump_func)0,
3837 (dump_func)dump_get_hook_info_reply,
3838 (dump_func)0,
3839 (dump_func)dump_destroy_class_reply,
3840 (dump_func)dump_set_class_info_reply,
3841 (dump_func)dump_set_clipboard_info_reply,
3842 (dump_func)dump_open_token_reply,
3843 (dump_func)dump_set_global_windows_reply,
3844 (dump_func)dump_adjust_token_privileges_reply,
3845 (dump_func)dump_get_token_privileges_reply,
3846 (dump_func)dump_check_token_privileges_reply,
3847 (dump_func)dump_duplicate_token_reply,
3848 (dump_func)dump_access_check_reply,
3849 (dump_func)dump_get_token_user_reply,
3850 (dump_func)dump_get_token_groups_reply,
3851 (dump_func)dump_create_mailslot_reply,
3852 (dump_func)dump_open_mailslot_reply,
3853 (dump_func)dump_set_mailslot_info_reply,
3854 (dump_func)dump_create_directory_reply,
3855 (dump_func)dump_open_directory_reply,
3856 (dump_func)dump_create_symlink_reply,
3857 (dump_func)dump_open_symlink_reply,
3858 (dump_func)dump_query_symlink_reply,
3861 static const char * const req_names[REQ_NB_REQUESTS] = {
3862 "new_process",
3863 "get_new_process_info",
3864 "new_thread",
3865 "get_startup_info",
3866 "init_process_done",
3867 "init_thread",
3868 "terminate_process",
3869 "terminate_thread",
3870 "get_process_info",
3871 "set_process_info",
3872 "get_thread_info",
3873 "set_thread_info",
3874 "get_dll_info",
3875 "suspend_thread",
3876 "resume_thread",
3877 "load_dll",
3878 "unload_dll",
3879 "queue_apc",
3880 "get_apc",
3881 "get_apc_result",
3882 "close_handle",
3883 "set_handle_info",
3884 "dup_handle",
3885 "open_process",
3886 "open_thread",
3887 "select",
3888 "create_event",
3889 "event_op",
3890 "open_event",
3891 "create_mutex",
3892 "release_mutex",
3893 "open_mutex",
3894 "create_semaphore",
3895 "release_semaphore",
3896 "open_semaphore",
3897 "create_file",
3898 "open_file_object",
3899 "alloc_file_handle",
3900 "get_handle_fd",
3901 "flush_file",
3902 "lock_file",
3903 "unlock_file",
3904 "unmount_device",
3905 "create_socket",
3906 "accept_socket",
3907 "set_socket_event",
3908 "get_socket_event",
3909 "enable_socket_event",
3910 "set_socket_deferred",
3911 "alloc_console",
3912 "free_console",
3913 "get_console_renderer_events",
3914 "open_console",
3915 "get_console_wait_event",
3916 "get_console_mode",
3917 "set_console_mode",
3918 "set_console_input_info",
3919 "get_console_input_info",
3920 "append_console_input_history",
3921 "get_console_input_history",
3922 "create_console_output",
3923 "set_console_output_info",
3924 "get_console_output_info",
3925 "write_console_input",
3926 "read_console_input",
3927 "write_console_output",
3928 "fill_console_output",
3929 "read_console_output",
3930 "move_console_output",
3931 "send_console_signal",
3932 "read_directory_changes",
3933 "read_change",
3934 "create_mapping",
3935 "open_mapping",
3936 "get_mapping_info",
3937 "create_snapshot",
3938 "next_process",
3939 "next_thread",
3940 "next_module",
3941 "wait_debug_event",
3942 "queue_exception_event",
3943 "get_exception_status",
3944 "output_debug_string",
3945 "continue_debug_event",
3946 "debug_process",
3947 "debug_break",
3948 "set_debugger_kill_on_exit",
3949 "read_process_memory",
3950 "write_process_memory",
3951 "create_key",
3952 "open_key",
3953 "delete_key",
3954 "flush_key",
3955 "enum_key",
3956 "set_key_value",
3957 "get_key_value",
3958 "enum_key_value",
3959 "delete_key_value",
3960 "load_registry",
3961 "unload_registry",
3962 "save_registry",
3963 "set_registry_notification",
3964 "create_timer",
3965 "open_timer",
3966 "set_timer",
3967 "cancel_timer",
3968 "get_timer_info",
3969 "get_thread_context",
3970 "set_thread_context",
3971 "get_selector_entry",
3972 "add_atom",
3973 "delete_atom",
3974 "find_atom",
3975 "get_atom_information",
3976 "set_atom_information",
3977 "empty_atom_table",
3978 "init_atom_table",
3979 "get_msg_queue",
3980 "set_queue_mask",
3981 "get_queue_status",
3982 "get_process_idle_event",
3983 "send_message",
3984 "post_quit_message",
3985 "send_hardware_message",
3986 "get_message",
3987 "reply_message",
3988 "accept_hardware_message",
3989 "get_message_reply",
3990 "set_win_timer",
3991 "kill_win_timer",
3992 "get_serial_info",
3993 "set_serial_info",
3994 "register_async",
3995 "cancel_async",
3996 "create_named_pipe",
3997 "open_named_pipe",
3998 "connect_named_pipe",
3999 "wait_named_pipe",
4000 "disconnect_named_pipe",
4001 "get_named_pipe_info",
4002 "create_window",
4003 "destroy_window",
4004 "get_desktop_window",
4005 "set_window_owner",
4006 "get_window_info",
4007 "set_window_info",
4008 "set_parent",
4009 "get_window_parents",
4010 "get_window_children",
4011 "get_window_children_from_point",
4012 "get_window_tree",
4013 "set_window_pos",
4014 "get_window_rectangles",
4015 "get_window_text",
4016 "set_window_text",
4017 "get_windows_offset",
4018 "get_visible_region",
4019 "get_window_region",
4020 "set_window_region",
4021 "get_update_region",
4022 "update_window_zorder",
4023 "redraw_window",
4024 "set_window_property",
4025 "remove_window_property",
4026 "get_window_property",
4027 "get_window_properties",
4028 "create_winstation",
4029 "open_winstation",
4030 "close_winstation",
4031 "get_process_winstation",
4032 "set_process_winstation",
4033 "create_desktop",
4034 "open_desktop",
4035 "close_desktop",
4036 "get_thread_desktop",
4037 "set_thread_desktop",
4038 "set_user_object_info",
4039 "attach_thread_input",
4040 "get_thread_input",
4041 "get_last_input_time",
4042 "get_key_state",
4043 "set_key_state",
4044 "set_foreground_window",
4045 "set_focus_window",
4046 "set_active_window",
4047 "set_capture_window",
4048 "set_caret_window",
4049 "set_caret_info",
4050 "set_hook",
4051 "remove_hook",
4052 "start_hook_chain",
4053 "finish_hook_chain",
4054 "get_hook_info",
4055 "create_class",
4056 "destroy_class",
4057 "set_class_info",
4058 "set_clipboard_info",
4059 "open_token",
4060 "set_global_windows",
4061 "adjust_token_privileges",
4062 "get_token_privileges",
4063 "check_token_privileges",
4064 "duplicate_token",
4065 "access_check",
4066 "get_token_user",
4067 "get_token_groups",
4068 "create_mailslot",
4069 "open_mailslot",
4070 "set_mailslot_info",
4071 "create_directory",
4072 "open_directory",
4073 "create_symlink",
4074 "open_symlink",
4075 "query_symlink",
4078 static const struct
4080 const char *name;
4081 unsigned int value;
4082 } status_names[] =
4084 { "ACCESS_DENIED", STATUS_ACCESS_DENIED },
4085 { "ACCESS_VIOLATION", STATUS_ACCESS_VIOLATION },
4086 { "ALERTED", STATUS_ALERTED },
4087 { "ALIAS_EXISTS", STATUS_ALIAS_EXISTS },
4088 { "BAD_DEVICE_TYPE", STATUS_BAD_DEVICE_TYPE },
4089 { "BUFFER_OVERFLOW", STATUS_BUFFER_OVERFLOW },
4090 { "BUFFER_TOO_SMALL", STATUS_BUFFER_TOO_SMALL },
4091 { "CANCELLED", STATUS_CANCELLED },
4092 { "CHILD_MUST_BE_VOLATILE", STATUS_CHILD_MUST_BE_VOLATILE },
4093 { "DEVICE_BUSY", STATUS_DEVICE_BUSY },
4094 { "DIRECTORY_NOT_EMPTY", STATUS_DIRECTORY_NOT_EMPTY },
4095 { "DISK_FULL", STATUS_DISK_FULL },
4096 { "DLL_NOT_FOUND", STATUS_DLL_NOT_FOUND },
4097 { "ERROR_CLASS_ALREADY_EXISTS", 0xc0010000 | ERROR_CLASS_ALREADY_EXISTS },
4098 { "ERROR_CLASS_DOES_NOT_EXIST", 0xc0010000 | ERROR_CLASS_DOES_NOT_EXIST },
4099 { "ERROR_CLASS_HAS_WINDOWS", 0xc0010000 | ERROR_CLASS_HAS_WINDOWS },
4100 { "ERROR_CLIPBOARD_NOT_OPEN", 0xc0010000 | ERROR_CLIPBOARD_NOT_OPEN },
4101 { "ERROR_INVALID_INDEX", 0xc0010000 | ERROR_INVALID_INDEX },
4102 { "ERROR_INVALID_WINDOW_HANDLE", 0xc0010000 | ERROR_INVALID_WINDOW_HANDLE },
4103 { "FILE_IS_A_DIRECTORY", STATUS_FILE_IS_A_DIRECTORY },
4104 { "FILE_LOCK_CONFLICT", STATUS_FILE_LOCK_CONFLICT },
4105 { "HANDLES_CLOSED", STATUS_HANDLES_CLOSED },
4106 { "HANDLE_NOT_CLOSABLE", STATUS_HANDLE_NOT_CLOSABLE },
4107 { "ILLEGAL_FUNCTION", STATUS_ILLEGAL_FUNCTION },
4108 { "INSTANCE_NOT_AVAILABLE", STATUS_INSTANCE_NOT_AVAILABLE },
4109 { "INVALID_CID", STATUS_INVALID_CID },
4110 { "INVALID_FILE_FOR_SECTION", STATUS_INVALID_FILE_FOR_SECTION },
4111 { "INVALID_HANDLE", STATUS_INVALID_HANDLE },
4112 { "INVALID_PARAMETER", STATUS_INVALID_PARAMETER },
4113 { "IO_TIMEOUT", STATUS_IO_TIMEOUT },
4114 { "KEY_DELETED", STATUS_KEY_DELETED },
4115 { "MAPPED_FILE_SIZE_ZERO", STATUS_MAPPED_FILE_SIZE_ZERO },
4116 { "MEDIA_WRITE_PROTECTED", STATUS_MEDIA_WRITE_PROTECTED },
4117 { "MUTANT_NOT_OWNED", STATUS_MUTANT_NOT_OWNED },
4118 { "NAME_TOO_LONG", STATUS_NAME_TOO_LONG },
4119 { "NOT_ALL_ASSIGNED", STATUS_NOT_ALL_ASSIGNED },
4120 { "NOT_A_DIRECTORY", STATUS_NOT_A_DIRECTORY },
4121 { "NOT_IMPLEMENTED", STATUS_NOT_IMPLEMENTED },
4122 { "NOT_REGISTRY_FILE", STATUS_NOT_REGISTRY_FILE },
4123 { "NO_DATA_DETECTED", STATUS_NO_DATA_DETECTED },
4124 { "NO_IMPERSONATION_TOKEN", STATUS_NO_IMPERSONATION_TOKEN },
4125 { "NO_MEMORY", STATUS_NO_MEMORY },
4126 { "NO_MORE_ENTRIES", STATUS_NO_MORE_ENTRIES },
4127 { "NO_MORE_FILES", STATUS_NO_MORE_FILES },
4128 { "NO_SUCH_DEVICE", STATUS_NO_SUCH_DEVICE },
4129 { "NO_SUCH_FILE", STATUS_NO_SUCH_FILE },
4130 { "NO_TOKEN", STATUS_NO_TOKEN },
4131 { "OBJECT_NAME_COLLISION", STATUS_OBJECT_NAME_COLLISION },
4132 { "OBJECT_NAME_EXISTS", STATUS_OBJECT_NAME_EXISTS },
4133 { "OBJECT_NAME_INVALID", STATUS_OBJECT_NAME_INVALID },
4134 { "OBJECT_NAME_NOT_FOUND", STATUS_OBJECT_NAME_NOT_FOUND },
4135 { "OBJECT_PATH_INVALID", STATUS_OBJECT_PATH_INVALID },
4136 { "OBJECT_PATH_NOT_FOUND", STATUS_OBJECT_PATH_NOT_FOUND },
4137 { "OBJECT_PATH_SYNTAX_BAD", STATUS_OBJECT_PATH_SYNTAX_BAD },
4138 { "OBJECT_TYPE_MISMATCH", STATUS_OBJECT_TYPE_MISMATCH },
4139 { "PENDING", STATUS_PENDING },
4140 { "PIPE_BUSY", STATUS_PIPE_BUSY },
4141 { "PIPE_CONNECTED", STATUS_PIPE_CONNECTED },
4142 { "PIPE_DISCONNECTED", STATUS_PIPE_DISCONNECTED },
4143 { "PIPE_LISTENING", STATUS_PIPE_LISTENING },
4144 { "PIPE_NOT_AVAILABLE", STATUS_PIPE_NOT_AVAILABLE },
4145 { "PRIVILEGE_NOT_HELD", STATUS_PRIVILEGE_NOT_HELD },
4146 { "PROCESS_IS_TERMINATING", STATUS_PROCESS_IS_TERMINATING },
4147 { "SECTION_TOO_BIG", STATUS_SECTION_TOO_BIG },
4148 { "SEMAPHORE_LIMIT_EXCEEDED", STATUS_SEMAPHORE_LIMIT_EXCEEDED },
4149 { "SHARING_VIOLATION", STATUS_SHARING_VIOLATION },
4150 { "SUSPEND_COUNT_EXCEEDED", STATUS_SUSPEND_COUNT_EXCEEDED },
4151 { "THREAD_IS_TERMINATING", STATUS_THREAD_IS_TERMINATING },
4152 { "TIMEOUT", STATUS_TIMEOUT },
4153 { "TOO_MANY_OPENED_FILES", STATUS_TOO_MANY_OPENED_FILES },
4154 { "UNSUCCESSFUL", STATUS_UNSUCCESSFUL },
4155 { "VOLUME_DISMOUNTED", STATUS_VOLUME_DISMOUNTED },
4156 { "WAS_LOCKED", STATUS_WAS_LOCKED },
4157 { NULL, 0 }
4160 /* ### make_requests end ### */
4161 /* Everything above this line is generated automatically by tools/make_requests */
4163 static const char *get_status_name( unsigned int status )
4165 int i;
4166 static char buffer[10];
4168 if (status)
4170 for (i = 0; status_names[i].name; i++)
4171 if (status_names[i].value == status) return status_names[i].name;
4173 sprintf( buffer, "%x", status );
4174 return buffer;
4177 void trace_request(void)
4179 enum request req = current->req.request_header.req;
4180 if (req < REQ_NB_REQUESTS)
4182 fprintf( stderr, "%04x: %s(", current->id, req_names[req] );
4183 if (req_dumpers[req])
4185 cur_data = get_req_data();
4186 cur_size = get_req_data_size();
4187 req_dumpers[req]( &current->req );
4189 fprintf( stderr, " )\n" );
4191 else fprintf( stderr, "%04x: %d(?)\n", current->id, req );
4194 void trace_reply( enum request req, const union generic_reply *reply )
4196 if (req < REQ_NB_REQUESTS)
4198 fprintf( stderr, "%04x: %s() = %s",
4199 current->id, req_names[req], get_status_name(current->error) );
4200 if (reply_dumpers[req])
4202 fprintf( stderr, " {" );
4203 cur_data = current->reply_data;
4204 cur_size = reply->reply_header.reply_size;
4205 reply_dumpers[req]( reply );
4206 fprintf( stderr, " }" );
4208 fputc( '\n', stderr );
4210 else fprintf( stderr, "%04x: %d() = %s\n",
4211 current->id, req, get_status_name(current->error) );