ReactOS 0.4.16-dev-197-g92996da
generated.c
Go to the documentation of this file.
1/* File generated automatically from tools/winapi/tests.dat; do not edit! */
2/* This file can be copied, modified and distributed without restriction. */
3
4/*
5 * Unit tests for data structure packing
6 */
7
8#define WINE_NOWINSOCK
9
10#include "ntdll_test.h"
11
12#include "wine/test.h"
13
14/***********************************************************************
15 * Compatibility macros
16 */
17
18#define DWORD_PTR UINT_PTR
19#define LONG_PTR INT_PTR
20#define ULONG_PTR UINT_PTR
21
22/***********************************************************************
23 * Windows API extension
24 */
25
26#if defined(_MSC_VER) && (_MSC_VER >= 1300) && defined(__cplusplus)
27# define _TYPE_ALIGNMENT(type) __alignof(type)
28#elif defined(__GNUC__)
29# define _TYPE_ALIGNMENT(type) __alignof__(type)
30#else
31/*
32 * FIXME: May not be possible without a compiler extension
33 * (if type is not just a name that is, otherwise the normal
34 * TYPE_ALIGNMENT can be used)
35 */
36#endif
37
38#if defined(TYPE_ALIGNMENT) && defined(_MSC_VER) && _MSC_VER >= 800 && !defined(__cplusplus)
39#pragma warning(disable:4116)
40#endif
41
42#if !defined(TYPE_ALIGNMENT) && defined(_TYPE_ALIGNMENT)
43# define TYPE_ALIGNMENT _TYPE_ALIGNMENT
44#endif
45
46/***********************************************************************
47 * Test helper macros
48 */
49
50#define TEST_TYPE_SIZE(type, size) C_ASSERT(sizeof(type) == size);
51
52#ifdef TYPE_ALIGNMENT
53# define TEST_TYPE_ALIGN(type, align) C_ASSERT(TYPE_ALIGNMENT(type) == align);
54#else
55# define TEST_TYPE_ALIGN(type, align)
56#endif
57
58#ifdef _TYPE_ALIGNMENT
59# define TEST_TARGET_ALIGN(type, align) C_ASSERT(_TYPE_ALIGNMENT(*(type)0) == align);
60# define TEST_FIELD_ALIGN(type, field, align) C_ASSERT(_TYPE_ALIGNMENT(((type*)0)->field) == align);
61#else
62# define TEST_TARGET_ALIGN(type, align)
63# define TEST_FIELD_ALIGN(type, field, align)
64#endif
65
66#define TEST_FIELD_OFFSET(type, field, offset) C_ASSERT(FIELD_OFFSET(type, field) == offset);
67
68#define TEST_TARGET_SIZE(type, size) TEST_TYPE_SIZE(*(type)0, size)
69#define TEST_FIELD_SIZE(type, field, size) TEST_TYPE_SIZE((((type*)0)->field), size)
70#define TEST_TYPE_SIGNED(type) C_ASSERT((type) -1 < 0);
71#define TEST_TYPE_UNSIGNED(type) C_ASSERT((type) -1 > 0);
72
73
74#ifdef _WIN64
75
76static void test_pack_DWORD32(void)
77{
78 /* DWORD32 */
82}
83
84static void test_pack_DWORD64(void)
85{
86 /* DWORD64 */
90}
91
92static void test_pack_DWORD_PTR(void)
93{
94 /* DWORD_PTR */
97}
98
99static void test_pack_HALF_PTR(void)
100{
101 /* HALF_PTR */
105}
106
107static void test_pack_INT16(void)
108{
109 /* INT16 */
113}
114
115static void test_pack_INT32(void)
116{
117 /* INT32 */
121}
122
123static void test_pack_INT64(void)
124{
125 /* INT64 */
129}
130
131static void test_pack_INT8(void)
132{
133 /* INT8 */
137}
138
139static void test_pack_INT_PTR(void)
140{
141 /* INT_PTR */
145}
146
147static void test_pack_LONG32(void)
148{
149 /* LONG32 */
153}
154
155static void test_pack_LONG64(void)
156{
157 /* LONG64 */
161}
162
163static void test_pack_LONG_PTR(void)
164{
165 /* LONG_PTR */
169}
170
171static void test_pack_SIZE_T(void)
172{
173 /* SIZE_T */
176}
177
178static void test_pack_SSIZE_T(void)
179{
180 /* SSIZE_T */
183}
184
185static void test_pack_UHALF_PTR(void)
186{
187 /* UHALF_PTR */
191}
192
193static void test_pack_UINT16(void)
194{
195 /* UINT16 */
199}
200
201static void test_pack_UINT32(void)
202{
203 /* UINT32 */
207}
208
209static void test_pack_UINT64(void)
210{
211 /* UINT64 */
215}
216
217static void test_pack_UINT8(void)
218{
219 /* UINT8 */
223}
224
225static void test_pack_UINT_PTR(void)
226{
227 /* UINT_PTR */
231}
232
233static void test_pack_ULONG32(void)
234{
235 /* ULONG32 */
239}
240
241static void test_pack_ULONG64(void)
242{
243 /* ULONG64 */
247}
248
249static void test_pack_ULONG_PTR(void)
250{
251 /* ULONG_PTR */
255}
256
257static void test_pack_ACCESS_ALLOWED_ACE(void)
258{
259 /* ACCESS_ALLOWED_ACE */
271}
272
273static void test_pack_ACCESS_DENIED_ACE(void)
274{
275 /* ACCESS_DENIED_ACE */
287}
288
289static void test_pack_ACCESS_MASK(void)
290{
291 /* ACCESS_MASK */
295}
296
297static void test_pack_ACE_HEADER(void)
298{
299 /* ACE_HEADER */
308 TEST_FIELD_SIZE (ACE_HEADER, AceSize, 2)
309 TEST_FIELD_ALIGN (ACE_HEADER, AceSize, 2)
310 TEST_FIELD_OFFSET(ACE_HEADER, AceSize, 2)
311}
312
313static void test_pack_ACL(void)
314{
315 /* ACL */
321 TEST_FIELD_SIZE (ACL, Sbz1, 1)
322 TEST_FIELD_ALIGN (ACL, Sbz1, 1)
323 TEST_FIELD_OFFSET(ACL, Sbz1, 1)
324 TEST_FIELD_SIZE (ACL, AclSize, 2)
325 TEST_FIELD_ALIGN (ACL, AclSize, 2)
326 TEST_FIELD_OFFSET(ACL, AclSize, 2)
327 TEST_FIELD_SIZE (ACL, AceCount, 2)
328 TEST_FIELD_ALIGN (ACL, AceCount, 2)
329 TEST_FIELD_OFFSET(ACL, AceCount, 4)
330 TEST_FIELD_SIZE (ACL, Sbz2, 2)
331 TEST_FIELD_ALIGN (ACL, Sbz2, 2)
332 TEST_FIELD_OFFSET(ACL, Sbz2, 6)
333}
334
336{
337 /* ACL_REVISION_INFORMATION */
343}
344
345static void test_pack_ACL_SIZE_INFORMATION(void)
346{
347 /* ACL_SIZE_INFORMATION */
353 TEST_FIELD_SIZE (ACL_SIZE_INFORMATION, AclBytesInUse, 4)
354 TEST_FIELD_ALIGN (ACL_SIZE_INFORMATION, AclBytesInUse, 4)
355 TEST_FIELD_OFFSET(ACL_SIZE_INFORMATION, AclBytesInUse, 4)
356 TEST_FIELD_SIZE (ACL_SIZE_INFORMATION, AclBytesFree, 4)
357 TEST_FIELD_ALIGN (ACL_SIZE_INFORMATION, AclBytesFree, 4)
359}
360
361static void test_pack_BOOLEAN(void)
362{
363 /* BOOLEAN */
367}
368
369static void test_pack_CCHAR(void)
370{
371 /* CCHAR */
374}
375
376static void test_pack_CHAR(void)
377{
378 /* CHAR */
381}
382
383static void test_pack_DWORDLONG(void)
384{
385 /* DWORDLONG */
389}
390
391static void test_pack_EXCEPTION_POINTERS(void)
392{
393 /* EXCEPTION_POINTERS */
396 TEST_FIELD_SIZE (EXCEPTION_POINTERS, ExceptionRecord, 8)
397 TEST_FIELD_ALIGN (EXCEPTION_POINTERS, ExceptionRecord, 8)
398 TEST_FIELD_OFFSET(EXCEPTION_POINTERS, ExceptionRecord, 0)
402}
403
404static void test_pack_EXCEPTION_RECORD(void)
405{
406 /* EXCEPTION_RECORD */
412 TEST_FIELD_SIZE (EXCEPTION_RECORD, ExceptionFlags, 4)
413 TEST_FIELD_ALIGN (EXCEPTION_RECORD, ExceptionFlags, 4)
414 TEST_FIELD_OFFSET(EXCEPTION_RECORD, ExceptionFlags, 4)
415 TEST_FIELD_SIZE (EXCEPTION_RECORD, ExceptionRecord, 8)
416 TEST_FIELD_ALIGN (EXCEPTION_RECORD, ExceptionRecord, 8)
417 TEST_FIELD_OFFSET(EXCEPTION_RECORD, ExceptionRecord, 8)
418 TEST_FIELD_SIZE (EXCEPTION_RECORD, ExceptionAddress, 8)
419 TEST_FIELD_ALIGN (EXCEPTION_RECORD, ExceptionAddress, 8)
420 TEST_FIELD_OFFSET(EXCEPTION_RECORD, ExceptionAddress, 16)
421 TEST_FIELD_SIZE (EXCEPTION_RECORD, NumberParameters, 4)
422 TEST_FIELD_ALIGN (EXCEPTION_RECORD, NumberParameters, 4)
423 TEST_FIELD_OFFSET(EXCEPTION_RECORD, NumberParameters, 24)
424 TEST_FIELD_SIZE (EXCEPTION_RECORD, ExceptionInformation, 120)
425 TEST_FIELD_ALIGN (EXCEPTION_RECORD, ExceptionInformation, 8)
426 TEST_FIELD_OFFSET(EXCEPTION_RECORD, ExceptionInformation, 32)
427}
428
429static void test_pack_EXECUTION_STATE(void)
430{
431 /* EXECUTION_STATE */
435}
436
437static void test_pack_FPO_DATA(void)
438{
439 /* FPO_DATA */
442 TEST_FIELD_SIZE (FPO_DATA, ulOffStart, 4)
443 TEST_FIELD_ALIGN (FPO_DATA, ulOffStart, 4)
444 TEST_FIELD_OFFSET(FPO_DATA, ulOffStart, 0)
445 TEST_FIELD_SIZE (FPO_DATA, cbProcSize, 4)
446 TEST_FIELD_ALIGN (FPO_DATA, cbProcSize, 4)
447 TEST_FIELD_OFFSET(FPO_DATA, cbProcSize, 4)
448 TEST_FIELD_SIZE (FPO_DATA, cdwLocals, 4)
449 TEST_FIELD_ALIGN (FPO_DATA, cdwLocals, 4)
450 TEST_FIELD_OFFSET(FPO_DATA, cdwLocals, 8)
451 TEST_FIELD_SIZE (FPO_DATA, cdwParams, 2)
452 TEST_FIELD_ALIGN (FPO_DATA, cdwParams, 2)
453 TEST_FIELD_OFFSET(FPO_DATA, cdwParams, 12)
454}
455
456static void test_pack_GENERIC_MAPPING(void)
457{
458 /* GENERIC_MAPPING */
461 TEST_FIELD_SIZE (GENERIC_MAPPING, GenericRead, 4)
462 TEST_FIELD_ALIGN (GENERIC_MAPPING, GenericRead, 4)
463 TEST_FIELD_OFFSET(GENERIC_MAPPING, GenericRead, 0)
464 TEST_FIELD_SIZE (GENERIC_MAPPING, GenericWrite, 4)
465 TEST_FIELD_ALIGN (GENERIC_MAPPING, GenericWrite, 4)
466 TEST_FIELD_OFFSET(GENERIC_MAPPING, GenericWrite, 4)
467 TEST_FIELD_SIZE (GENERIC_MAPPING, GenericExecute, 4)
468 TEST_FIELD_ALIGN (GENERIC_MAPPING, GenericExecute, 4)
469 TEST_FIELD_OFFSET(GENERIC_MAPPING, GenericExecute, 8)
470 TEST_FIELD_SIZE (GENERIC_MAPPING, GenericAll, 4)
471 TEST_FIELD_ALIGN (GENERIC_MAPPING, GenericAll, 4)
472 TEST_FIELD_OFFSET(GENERIC_MAPPING, GenericAll, 12)
473}
474
475static void test_pack_HANDLE(void)
476{
477 /* HANDLE */
480}
481
482static void test_pack_HRESULT(void)
483{
484 /* HRESULT */
487}
488
490{
491 /* IMAGE_ARCHIVE_MEMBER_HEADER */
515}
516
517static void test_pack_IMAGE_AUX_SYMBOL(void)
518{
519 /* IMAGE_AUX_SYMBOL (pack 2) */
520}
521
522static void test_pack_IMAGE_BASE_RELOCATION(void)
523{
524 /* IMAGE_BASE_RELOCATION */
530 TEST_FIELD_SIZE (IMAGE_BASE_RELOCATION, SizeOfBlock, 4)
533}
534
536{
537 /* IMAGE_BOUND_FORWARDER_REF */
543 TEST_FIELD_SIZE (IMAGE_BOUND_FORWARDER_REF, OffsetModuleName, 2)
544 TEST_FIELD_ALIGN (IMAGE_BOUND_FORWARDER_REF, OffsetModuleName, 2)
545 TEST_FIELD_OFFSET(IMAGE_BOUND_FORWARDER_REF, OffsetModuleName, 4)
549}
550
552{
553 /* IMAGE_BOUND_IMPORT_DESCRIPTOR */
562 TEST_FIELD_SIZE (IMAGE_BOUND_IMPORT_DESCRIPTOR, NumberOfModuleForwarderRefs, 2)
563 TEST_FIELD_ALIGN (IMAGE_BOUND_IMPORT_DESCRIPTOR, NumberOfModuleForwarderRefs, 2)
564 TEST_FIELD_OFFSET(IMAGE_BOUND_IMPORT_DESCRIPTOR, NumberOfModuleForwarderRefs, 6)
565}
566
568{
569 /* IMAGE_COFF_SYMBOLS_HEADER */
572 TEST_FIELD_SIZE (IMAGE_COFF_SYMBOLS_HEADER, NumberOfSymbols, 4)
573 TEST_FIELD_ALIGN (IMAGE_COFF_SYMBOLS_HEADER, NumberOfSymbols, 4)
575 TEST_FIELD_SIZE (IMAGE_COFF_SYMBOLS_HEADER, LvaToFirstSymbol, 4)
576 TEST_FIELD_ALIGN (IMAGE_COFF_SYMBOLS_HEADER, LvaToFirstSymbol, 4)
577 TEST_FIELD_OFFSET(IMAGE_COFF_SYMBOLS_HEADER, LvaToFirstSymbol, 4)
578 TEST_FIELD_SIZE (IMAGE_COFF_SYMBOLS_HEADER, NumberOfLinenumbers, 4)
579 TEST_FIELD_ALIGN (IMAGE_COFF_SYMBOLS_HEADER, NumberOfLinenumbers, 4)
580 TEST_FIELD_OFFSET(IMAGE_COFF_SYMBOLS_HEADER, NumberOfLinenumbers, 8)
581 TEST_FIELD_SIZE (IMAGE_COFF_SYMBOLS_HEADER, LvaToFirstLinenumber, 4)
582 TEST_FIELD_ALIGN (IMAGE_COFF_SYMBOLS_HEADER, LvaToFirstLinenumber, 4)
583 TEST_FIELD_OFFSET(IMAGE_COFF_SYMBOLS_HEADER, LvaToFirstLinenumber, 12)
584 TEST_FIELD_SIZE (IMAGE_COFF_SYMBOLS_HEADER, RvaToFirstByteOfCode, 4)
585 TEST_FIELD_ALIGN (IMAGE_COFF_SYMBOLS_HEADER, RvaToFirstByteOfCode, 4)
586 TEST_FIELD_OFFSET(IMAGE_COFF_SYMBOLS_HEADER, RvaToFirstByteOfCode, 16)
587 TEST_FIELD_SIZE (IMAGE_COFF_SYMBOLS_HEADER, RvaToLastByteOfCode, 4)
588 TEST_FIELD_ALIGN (IMAGE_COFF_SYMBOLS_HEADER, RvaToLastByteOfCode, 4)
589 TEST_FIELD_OFFSET(IMAGE_COFF_SYMBOLS_HEADER, RvaToLastByteOfCode, 20)
590 TEST_FIELD_SIZE (IMAGE_COFF_SYMBOLS_HEADER, RvaToFirstByteOfData, 4)
591 TEST_FIELD_ALIGN (IMAGE_COFF_SYMBOLS_HEADER, RvaToFirstByteOfData, 4)
592 TEST_FIELD_OFFSET(IMAGE_COFF_SYMBOLS_HEADER, RvaToFirstByteOfData, 24)
593 TEST_FIELD_SIZE (IMAGE_COFF_SYMBOLS_HEADER, RvaToLastByteOfData, 4)
594 TEST_FIELD_ALIGN (IMAGE_COFF_SYMBOLS_HEADER, RvaToLastByteOfData, 4)
595 TEST_FIELD_OFFSET(IMAGE_COFF_SYMBOLS_HEADER, RvaToLastByteOfData, 28)
596}
597
598static void test_pack_IMAGE_DATA_DIRECTORY(void)
599{
600 /* IMAGE_DATA_DIRECTORY */
609}
610
611static void test_pack_IMAGE_DEBUG_DIRECTORY(void)
612{
613 /* IMAGE_DEBUG_DIRECTORY */
616 TEST_FIELD_SIZE (IMAGE_DEBUG_DIRECTORY, Characteristics, 4)
617 TEST_FIELD_ALIGN (IMAGE_DEBUG_DIRECTORY, Characteristics, 4)
618 TEST_FIELD_OFFSET(IMAGE_DEBUG_DIRECTORY, Characteristics, 0)
619 TEST_FIELD_SIZE (IMAGE_DEBUG_DIRECTORY, TimeDateStamp, 4)
620 TEST_FIELD_ALIGN (IMAGE_DEBUG_DIRECTORY, TimeDateStamp, 4)
634 TEST_FIELD_SIZE (IMAGE_DEBUG_DIRECTORY, AddressOfRawData, 4)
635 TEST_FIELD_ALIGN (IMAGE_DEBUG_DIRECTORY, AddressOfRawData, 4)
636 TEST_FIELD_OFFSET(IMAGE_DEBUG_DIRECTORY, AddressOfRawData, 20)
637 TEST_FIELD_SIZE (IMAGE_DEBUG_DIRECTORY, PointerToRawData, 4)
638 TEST_FIELD_ALIGN (IMAGE_DEBUG_DIRECTORY, PointerToRawData, 4)
639 TEST_FIELD_OFFSET(IMAGE_DEBUG_DIRECTORY, PointerToRawData, 24)
640}
641
642static void test_pack_IMAGE_DEBUG_MISC(void)
643{
644 /* IMAGE_DEBUG_MISC */
662}
663
664static void test_pack_IMAGE_DOS_HEADER(void)
665{
666 /* IMAGE_DOS_HEADER (pack 2) */
681 TEST_FIELD_SIZE (IMAGE_DOS_HEADER, e_cparhdr, 2)
682 TEST_FIELD_ALIGN (IMAGE_DOS_HEADER, e_cparhdr, 2)
684 TEST_FIELD_SIZE (IMAGE_DOS_HEADER, e_minalloc, 2)
685 TEST_FIELD_ALIGN (IMAGE_DOS_HEADER, e_minalloc, 2)
686 TEST_FIELD_OFFSET(IMAGE_DOS_HEADER, e_minalloc, 10)
687 TEST_FIELD_SIZE (IMAGE_DOS_HEADER, e_maxalloc, 2)
688 TEST_FIELD_ALIGN (IMAGE_DOS_HEADER, e_maxalloc, 2)
689 TEST_FIELD_OFFSET(IMAGE_DOS_HEADER, e_maxalloc, 12)
705 TEST_FIELD_SIZE (IMAGE_DOS_HEADER, e_lfarlc, 2)
717 TEST_FIELD_SIZE (IMAGE_DOS_HEADER, e_oeminfo, 2)
718 TEST_FIELD_ALIGN (IMAGE_DOS_HEADER, e_oeminfo, 2)
719 TEST_FIELD_OFFSET(IMAGE_DOS_HEADER, e_oeminfo, 38)
726}
727
728static void test_pack_IMAGE_EXPORT_DIRECTORY(void)
729{
730 /* IMAGE_EXPORT_DIRECTORY */
733 TEST_FIELD_SIZE (IMAGE_EXPORT_DIRECTORY, Characteristics, 4)
734 TEST_FIELD_ALIGN (IMAGE_EXPORT_DIRECTORY, Characteristics, 4)
735 TEST_FIELD_OFFSET(IMAGE_EXPORT_DIRECTORY, Characteristics, 0)
736 TEST_FIELD_SIZE (IMAGE_EXPORT_DIRECTORY, TimeDateStamp, 4)
737 TEST_FIELD_ALIGN (IMAGE_EXPORT_DIRECTORY, TimeDateStamp, 4)
751 TEST_FIELD_SIZE (IMAGE_EXPORT_DIRECTORY, NumberOfFunctions, 4)
752 TEST_FIELD_ALIGN (IMAGE_EXPORT_DIRECTORY, NumberOfFunctions, 4)
753 TEST_FIELD_OFFSET(IMAGE_EXPORT_DIRECTORY, NumberOfFunctions, 20)
754 TEST_FIELD_SIZE (IMAGE_EXPORT_DIRECTORY, NumberOfNames, 4)
755 TEST_FIELD_ALIGN (IMAGE_EXPORT_DIRECTORY, NumberOfNames, 4)
756 TEST_FIELD_OFFSET(IMAGE_EXPORT_DIRECTORY, NumberOfNames, 24)
757 TEST_FIELD_SIZE (IMAGE_EXPORT_DIRECTORY, AddressOfFunctions, 4)
758 TEST_FIELD_ALIGN (IMAGE_EXPORT_DIRECTORY, AddressOfFunctions, 4)
759 TEST_FIELD_OFFSET(IMAGE_EXPORT_DIRECTORY, AddressOfFunctions, 28)
760 TEST_FIELD_SIZE (IMAGE_EXPORT_DIRECTORY, AddressOfNames, 4)
761 TEST_FIELD_ALIGN (IMAGE_EXPORT_DIRECTORY, AddressOfNames, 4)
762 TEST_FIELD_OFFSET(IMAGE_EXPORT_DIRECTORY, AddressOfNames, 32)
763 TEST_FIELD_SIZE (IMAGE_EXPORT_DIRECTORY, AddressOfNameOrdinals, 4)
764 TEST_FIELD_ALIGN (IMAGE_EXPORT_DIRECTORY, AddressOfNameOrdinals, 4)
765 TEST_FIELD_OFFSET(IMAGE_EXPORT_DIRECTORY, AddressOfNameOrdinals, 36)
766}
767
768static void test_pack_IMAGE_FILE_HEADER(void)
769{
770 /* IMAGE_FILE_HEADER */
776 TEST_FIELD_SIZE (IMAGE_FILE_HEADER, NumberOfSections, 2)
777 TEST_FIELD_ALIGN (IMAGE_FILE_HEADER, NumberOfSections, 2)
778 TEST_FIELD_OFFSET(IMAGE_FILE_HEADER, NumberOfSections, 2)
779 TEST_FIELD_SIZE (IMAGE_FILE_HEADER, TimeDateStamp, 4)
780 TEST_FIELD_ALIGN (IMAGE_FILE_HEADER, TimeDateStamp, 4)
781 TEST_FIELD_OFFSET(IMAGE_FILE_HEADER, TimeDateStamp, 4)
782 TEST_FIELD_SIZE (IMAGE_FILE_HEADER, PointerToSymbolTable, 4)
783 TEST_FIELD_ALIGN (IMAGE_FILE_HEADER, PointerToSymbolTable, 4)
784 TEST_FIELD_OFFSET(IMAGE_FILE_HEADER, PointerToSymbolTable, 8)
785 TEST_FIELD_SIZE (IMAGE_FILE_HEADER, NumberOfSymbols, 4)
786 TEST_FIELD_ALIGN (IMAGE_FILE_HEADER, NumberOfSymbols, 4)
787 TEST_FIELD_OFFSET(IMAGE_FILE_HEADER, NumberOfSymbols, 12)
788 TEST_FIELD_SIZE (IMAGE_FILE_HEADER, SizeOfOptionalHeader, 2)
789 TEST_FIELD_ALIGN (IMAGE_FILE_HEADER, SizeOfOptionalHeader, 2)
790 TEST_FIELD_OFFSET(IMAGE_FILE_HEADER, SizeOfOptionalHeader, 16)
791 TEST_FIELD_SIZE (IMAGE_FILE_HEADER, Characteristics, 2)
792 TEST_FIELD_ALIGN (IMAGE_FILE_HEADER, Characteristics, 2)
793 TEST_FIELD_OFFSET(IMAGE_FILE_HEADER, Characteristics, 18)
794}
795
796static void test_pack_IMAGE_FUNCTION_ENTRY(void)
797{
798 /* IMAGE_FUNCTION_ENTRY */
801 TEST_FIELD_SIZE (IMAGE_FUNCTION_ENTRY, StartingAddress, 4)
802 TEST_FIELD_ALIGN (IMAGE_FUNCTION_ENTRY, StartingAddress, 4)
803 TEST_FIELD_OFFSET(IMAGE_FUNCTION_ENTRY, StartingAddress, 0)
804 TEST_FIELD_SIZE (IMAGE_FUNCTION_ENTRY, EndingAddress, 4)
805 TEST_FIELD_ALIGN (IMAGE_FUNCTION_ENTRY, EndingAddress, 4)
806 TEST_FIELD_OFFSET(IMAGE_FUNCTION_ENTRY, EndingAddress, 4)
807 TEST_FIELD_SIZE (IMAGE_FUNCTION_ENTRY, EndOfPrologue, 4)
808 TEST_FIELD_ALIGN (IMAGE_FUNCTION_ENTRY, EndOfPrologue, 4)
809 TEST_FIELD_OFFSET(IMAGE_FUNCTION_ENTRY, EndOfPrologue, 8)
810}
811
812static void test_pack_IMAGE_IMPORT_BY_NAME(void)
813{
814 /* IMAGE_IMPORT_BY_NAME */
823}
824
825static void test_pack_IMAGE_IMPORT_DESCRIPTOR(void)
826{
827 /* IMAGE_IMPORT_DESCRIPTOR */
828}
829
830static void test_pack_IMAGE_LINENUMBER(void)
831{
832 /* IMAGE_LINENUMBER (pack 2) */
833}
834
836{
837 /* IMAGE_LOAD_CONFIG_DIRECTORY */
840}
841
843{
844 /* IMAGE_LOAD_CONFIG_DIRECTORY32 */
865 TEST_FIELD_SIZE (IMAGE_LOAD_CONFIG_DIRECTORY32, CriticalSectionDefaultTimeout, 4)
866 TEST_FIELD_ALIGN (IMAGE_LOAD_CONFIG_DIRECTORY32, CriticalSectionDefaultTimeout, 4)
867 TEST_FIELD_OFFSET(IMAGE_LOAD_CONFIG_DIRECTORY32, CriticalSectionDefaultTimeout, 20)
868 TEST_FIELD_SIZE (IMAGE_LOAD_CONFIG_DIRECTORY32, DeCommitFreeBlockThreshold, 4)
869 TEST_FIELD_ALIGN (IMAGE_LOAD_CONFIG_DIRECTORY32, DeCommitFreeBlockThreshold, 4)
870 TEST_FIELD_OFFSET(IMAGE_LOAD_CONFIG_DIRECTORY32, DeCommitFreeBlockThreshold, 24)
871 TEST_FIELD_SIZE (IMAGE_LOAD_CONFIG_DIRECTORY32, DeCommitTotalFreeThreshold, 4)
872 TEST_FIELD_ALIGN (IMAGE_LOAD_CONFIG_DIRECTORY32, DeCommitTotalFreeThreshold, 4)
873 TEST_FIELD_OFFSET(IMAGE_LOAD_CONFIG_DIRECTORY32, DeCommitTotalFreeThreshold, 28)
877 TEST_FIELD_SIZE (IMAGE_LOAD_CONFIG_DIRECTORY32, MaximumAllocationSize, 4)
878 TEST_FIELD_ALIGN (IMAGE_LOAD_CONFIG_DIRECTORY32, MaximumAllocationSize, 4)
879 TEST_FIELD_OFFSET(IMAGE_LOAD_CONFIG_DIRECTORY32, MaximumAllocationSize, 40)
880 TEST_FIELD_SIZE (IMAGE_LOAD_CONFIG_DIRECTORY32, VirtualMemoryThreshold, 4)
881 TEST_FIELD_ALIGN (IMAGE_LOAD_CONFIG_DIRECTORY32, VirtualMemoryThreshold, 4)
882 TEST_FIELD_OFFSET(IMAGE_LOAD_CONFIG_DIRECTORY32, VirtualMemoryThreshold, 44)
907}
908
910{
911 /* IMAGE_LOAD_CONFIG_DIRECTORY64 */
932 TEST_FIELD_SIZE (IMAGE_LOAD_CONFIG_DIRECTORY64, CriticalSectionDefaultTimeout, 4)
933 TEST_FIELD_ALIGN (IMAGE_LOAD_CONFIG_DIRECTORY64, CriticalSectionDefaultTimeout, 4)
934 TEST_FIELD_OFFSET(IMAGE_LOAD_CONFIG_DIRECTORY64, CriticalSectionDefaultTimeout, 20)
935 TEST_FIELD_SIZE (IMAGE_LOAD_CONFIG_DIRECTORY64, DeCommitFreeBlockThreshold, 8)
936 TEST_FIELD_ALIGN (IMAGE_LOAD_CONFIG_DIRECTORY64, DeCommitFreeBlockThreshold, 8)
937 TEST_FIELD_OFFSET(IMAGE_LOAD_CONFIG_DIRECTORY64, DeCommitFreeBlockThreshold, 24)
938 TEST_FIELD_SIZE (IMAGE_LOAD_CONFIG_DIRECTORY64, DeCommitTotalFreeThreshold, 8)
939 TEST_FIELD_ALIGN (IMAGE_LOAD_CONFIG_DIRECTORY64, DeCommitTotalFreeThreshold, 8)
940 TEST_FIELD_OFFSET(IMAGE_LOAD_CONFIG_DIRECTORY64, DeCommitTotalFreeThreshold, 32)
944 TEST_FIELD_SIZE (IMAGE_LOAD_CONFIG_DIRECTORY64, MaximumAllocationSize, 8)
945 TEST_FIELD_ALIGN (IMAGE_LOAD_CONFIG_DIRECTORY64, MaximumAllocationSize, 8)
946 TEST_FIELD_OFFSET(IMAGE_LOAD_CONFIG_DIRECTORY64, MaximumAllocationSize, 48)
947 TEST_FIELD_SIZE (IMAGE_LOAD_CONFIG_DIRECTORY64, VirtualMemoryThreshold, 8)
948 TEST_FIELD_ALIGN (IMAGE_LOAD_CONFIG_DIRECTORY64, VirtualMemoryThreshold, 8)
949 TEST_FIELD_OFFSET(IMAGE_LOAD_CONFIG_DIRECTORY64, VirtualMemoryThreshold, 56)
974}
975
976static void test_pack_IMAGE_NT_HEADERS(void)
977{
978 /* IMAGE_NT_HEADERS */
981}
982
983static void test_pack_IMAGE_NT_HEADERS32(void)
984{
985 /* IMAGE_NT_HEADERS32 */
991 TEST_FIELD_SIZE (IMAGE_NT_HEADERS32, FileHeader, 20)
992 TEST_FIELD_ALIGN (IMAGE_NT_HEADERS32, FileHeader, 4)
994 TEST_FIELD_SIZE (IMAGE_NT_HEADERS32, OptionalHeader, 224)
995 TEST_FIELD_ALIGN (IMAGE_NT_HEADERS32, OptionalHeader, 4)
996 TEST_FIELD_OFFSET(IMAGE_NT_HEADERS32, OptionalHeader, 24)
997}
998
999static void test_pack_IMAGE_NT_HEADERS64(void)
1000{
1001 /* IMAGE_NT_HEADERS64 */
1007 TEST_FIELD_SIZE (IMAGE_NT_HEADERS64, FileHeader, 20)
1008 TEST_FIELD_ALIGN (IMAGE_NT_HEADERS64, FileHeader, 4)
1010 TEST_FIELD_SIZE (IMAGE_NT_HEADERS64, OptionalHeader, 240)
1011 TEST_FIELD_ALIGN (IMAGE_NT_HEADERS64, OptionalHeader, 8)
1012 TEST_FIELD_OFFSET(IMAGE_NT_HEADERS64, OptionalHeader, 24)
1013}
1014
1015static void test_pack_IMAGE_OPTIONAL_HEADER(void)
1016{
1017 /* IMAGE_OPTIONAL_HEADER */
1020}
1021
1022static void test_pack_IMAGE_OPTIONAL_HEADER32(void)
1023{
1024 /* IMAGE_OPTIONAL_HEADER32 */
1030 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, MajorLinkerVersion, 1)
1031 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, MajorLinkerVersion, 1)
1032 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, MajorLinkerVersion, 2)
1033 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, MinorLinkerVersion, 1)
1034 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, MinorLinkerVersion, 1)
1035 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, MinorLinkerVersion, 3)
1039 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, SizeOfInitializedData, 4)
1040 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, SizeOfInitializedData, 4)
1041 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, SizeOfInitializedData, 8)
1042 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, SizeOfUninitializedData, 4)
1043 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, SizeOfUninitializedData, 4)
1044 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, SizeOfUninitializedData, 12)
1045 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, AddressOfEntryPoint, 4)
1046 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, AddressOfEntryPoint, 4)
1047 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, AddressOfEntryPoint, 16)
1057 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, SectionAlignment, 4)
1058 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, SectionAlignment, 4)
1059 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, SectionAlignment, 32)
1060 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, FileAlignment, 4)
1061 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, FileAlignment, 4)
1062 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, FileAlignment, 36)
1063 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, MajorOperatingSystemVersion, 2)
1064 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, MajorOperatingSystemVersion, 2)
1065 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, MajorOperatingSystemVersion, 40)
1066 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, MinorOperatingSystemVersion, 2)
1067 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, MinorOperatingSystemVersion, 2)
1068 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, MinorOperatingSystemVersion, 42)
1069 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, MajorImageVersion, 2)
1070 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, MajorImageVersion, 2)
1071 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, MajorImageVersion, 44)
1072 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, MinorImageVersion, 2)
1073 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, MinorImageVersion, 2)
1074 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, MinorImageVersion, 46)
1075 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, MajorSubsystemVersion, 2)
1076 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, MajorSubsystemVersion, 2)
1077 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, MajorSubsystemVersion, 48)
1078 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, MinorSubsystemVersion, 2)
1079 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, MinorSubsystemVersion, 2)
1080 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, MinorSubsystemVersion, 50)
1081 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, Win32VersionValue, 4)
1082 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, Win32VersionValue, 4)
1083 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, Win32VersionValue, 52)
1087 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, SizeOfHeaders, 4)
1088 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, SizeOfHeaders, 4)
1089 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, SizeOfHeaders, 60)
1096 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, DllCharacteristics, 2)
1097 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, DllCharacteristics, 2)
1098 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, DllCharacteristics, 70)
1099 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, SizeOfStackReserve, 4)
1100 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, SizeOfStackReserve, 4)
1101 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, SizeOfStackReserve, 72)
1102 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, SizeOfStackCommit, 4)
1103 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, SizeOfStackCommit, 4)
1104 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, SizeOfStackCommit, 76)
1105 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, SizeOfHeapReserve, 4)
1106 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, SizeOfHeapReserve, 4)
1107 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, SizeOfHeapReserve, 80)
1108 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, SizeOfHeapCommit, 4)
1109 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, SizeOfHeapCommit, 4)
1110 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, SizeOfHeapCommit, 84)
1114 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, NumberOfRvaAndSizes, 4)
1115 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, NumberOfRvaAndSizes, 4)
1116 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, NumberOfRvaAndSizes, 92)
1117 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, DataDirectory, 128)
1118 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, DataDirectory, 4)
1119 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, DataDirectory, 96)
1120}
1121
1122static void test_pack_IMAGE_OPTIONAL_HEADER64(void)
1123{
1124 /* IMAGE_OPTIONAL_HEADER64 */
1130 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, MajorLinkerVersion, 1)
1131 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, MajorLinkerVersion, 1)
1132 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, MajorLinkerVersion, 2)
1133 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, MinorLinkerVersion, 1)
1134 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, MinorLinkerVersion, 1)
1135 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, MinorLinkerVersion, 3)
1139 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, SizeOfInitializedData, 4)
1140 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, SizeOfInitializedData, 4)
1141 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, SizeOfInitializedData, 8)
1142 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, SizeOfUninitializedData, 4)
1143 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, SizeOfUninitializedData, 4)
1144 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, SizeOfUninitializedData, 12)
1145 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, AddressOfEntryPoint, 4)
1146 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, AddressOfEntryPoint, 4)
1147 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, AddressOfEntryPoint, 16)
1154 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, SectionAlignment, 4)
1155 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, SectionAlignment, 4)
1156 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, SectionAlignment, 32)
1157 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, FileAlignment, 4)
1158 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, FileAlignment, 4)
1159 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, FileAlignment, 36)
1160 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, MajorOperatingSystemVersion, 2)
1161 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, MajorOperatingSystemVersion, 2)
1162 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, MajorOperatingSystemVersion, 40)
1163 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, MinorOperatingSystemVersion, 2)
1164 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, MinorOperatingSystemVersion, 2)
1165 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, MinorOperatingSystemVersion, 42)
1166 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, MajorImageVersion, 2)
1167 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, MajorImageVersion, 2)
1168 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, MajorImageVersion, 44)
1169 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, MinorImageVersion, 2)
1170 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, MinorImageVersion, 2)
1171 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, MinorImageVersion, 46)
1172 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, MajorSubsystemVersion, 2)
1173 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, MajorSubsystemVersion, 2)
1174 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, MajorSubsystemVersion, 48)
1175 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, MinorSubsystemVersion, 2)
1176 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, MinorSubsystemVersion, 2)
1177 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, MinorSubsystemVersion, 50)
1178 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, Win32VersionValue, 4)
1179 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, Win32VersionValue, 4)
1180 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, Win32VersionValue, 52)
1184 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, SizeOfHeaders, 4)
1185 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, SizeOfHeaders, 4)
1186 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, SizeOfHeaders, 60)
1193 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, DllCharacteristics, 2)
1194 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, DllCharacteristics, 2)
1195 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, DllCharacteristics, 70)
1196 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, SizeOfStackReserve, 8)
1197 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, SizeOfStackReserve, 8)
1198 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, SizeOfStackReserve, 72)
1199 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, SizeOfStackCommit, 8)
1200 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, SizeOfStackCommit, 8)
1201 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, SizeOfStackCommit, 80)
1202 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, SizeOfHeapReserve, 8)
1203 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, SizeOfHeapReserve, 8)
1204 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, SizeOfHeapReserve, 88)
1205 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, SizeOfHeapCommit, 8)
1206 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, SizeOfHeapCommit, 8)
1207 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, SizeOfHeapCommit, 96)
1211 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, NumberOfRvaAndSizes, 4)
1212 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, NumberOfRvaAndSizes, 4)
1213 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, NumberOfRvaAndSizes, 108)
1214 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, DataDirectory, 128)
1215 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, DataDirectory, 4)
1216 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, DataDirectory, 112)
1217}
1218
1219static void test_pack_IMAGE_OS2_HEADER(void)
1220{
1221 /* IMAGE_OS2_HEADER (pack 2) */
1224 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_magic, 2)
1225 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_magic, 2)
1233 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_enttab, 2)
1234 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_enttab, 2)
1235 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_enttab, 4)
1236 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_cbenttab, 2)
1237 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_cbenttab, 2)
1238 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_cbenttab, 6)
1242 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_flags, 2)
1243 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_flags, 2)
1244 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_flags, 12)
1245 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_autodata, 2)
1246 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_autodata, 2)
1247 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_autodata, 14)
1248 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_heap, 2)
1251 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_stack, 2)
1252 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_stack, 2)
1253 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_stack, 18)
1254 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_csip, 4)
1257 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_sssp, 4)
1260 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_cseg, 2)
1263 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_cmod, 2)
1266 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_cbnrestab, 2)
1267 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_cbnrestab, 2)
1268 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_cbnrestab, 32)
1269 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_segtab, 2)
1270 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_segtab, 2)
1271 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_segtab, 34)
1272 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_rsrctab, 2)
1273 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_rsrctab, 2)
1274 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_rsrctab, 36)
1275 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_restab, 2)
1276 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_restab, 2)
1277 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_restab, 38)
1278 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_modtab, 2)
1279 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_modtab, 2)
1280 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_modtab, 40)
1281 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_imptab, 2)
1282 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_imptab, 2)
1283 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_imptab, 42)
1284 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_nrestab, 4)
1285 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_nrestab, 2)
1286 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_nrestab, 44)
1287 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_cmovent, 2)
1288 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_cmovent, 2)
1289 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_cmovent, 48)
1290 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_align, 2)
1291 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_align, 2)
1292 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_align, 50)
1293 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_cres, 2)
1296 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_exetyp, 1)
1297 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_exetyp, 1)
1298 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_exetyp, 54)
1299 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_flagsothers, 1)
1300 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_flagsothers, 1)
1301 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_flagsothers, 55)
1302 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_pretthunks, 2)
1303 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_pretthunks, 2)
1304 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_pretthunks, 56)
1305 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_psegrefbytes, 2)
1306 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_psegrefbytes, 2)
1307 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_psegrefbytes, 58)
1308 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_swaparea, 2)
1309 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_swaparea, 2)
1310 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_swaparea, 60)
1311 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_expver, 2)
1312 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_expver, 2)
1313 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_expver, 62)
1314}
1315
1316static void test_pack_IMAGE_RELOCATION(void)
1317{
1318 /* IMAGE_RELOCATION (pack 2) */
1319}
1320
1322{
1323 /* IMAGE_RESOURCE_DATA_ENTRY */
1338}
1339
1340static void test_pack_IMAGE_RESOURCE_DIRECTORY(void)
1341{
1342 /* IMAGE_RESOURCE_DIRECTORY */
1345 TEST_FIELD_SIZE (IMAGE_RESOURCE_DIRECTORY, Characteristics, 4)
1346 TEST_FIELD_ALIGN (IMAGE_RESOURCE_DIRECTORY, Characteristics, 4)
1347 TEST_FIELD_OFFSET(IMAGE_RESOURCE_DIRECTORY, Characteristics, 0)
1348 TEST_FIELD_SIZE (IMAGE_RESOURCE_DIRECTORY, TimeDateStamp, 4)
1349 TEST_FIELD_ALIGN (IMAGE_RESOURCE_DIRECTORY, TimeDateStamp, 4)
1357 TEST_FIELD_SIZE (IMAGE_RESOURCE_DIRECTORY, NumberOfNamedEntries, 2)
1358 TEST_FIELD_ALIGN (IMAGE_RESOURCE_DIRECTORY, NumberOfNamedEntries, 2)
1359 TEST_FIELD_OFFSET(IMAGE_RESOURCE_DIRECTORY, NumberOfNamedEntries, 12)
1360 TEST_FIELD_SIZE (IMAGE_RESOURCE_DIRECTORY, NumberOfIdEntries, 2)
1361 TEST_FIELD_ALIGN (IMAGE_RESOURCE_DIRECTORY, NumberOfIdEntries, 2)
1362 TEST_FIELD_OFFSET(IMAGE_RESOURCE_DIRECTORY, NumberOfIdEntries, 14)
1363}
1364
1366{
1367 /* IMAGE_RESOURCE_DIRECTORY_ENTRY */
1368}
1369
1371{
1372 /* IMAGE_RESOURCE_DIRECTORY_STRING */
1381}
1382
1384{
1385 /* IMAGE_RESOURCE_DIR_STRING_U */
1394}
1395
1396static void test_pack_IMAGE_SECTION_HEADER(void)
1397{
1398 /* IMAGE_SECTION_HEADER */
1402}
1403
1405{
1406 /* IMAGE_SEPARATE_DEBUG_HEADER */
1418 TEST_FIELD_SIZE (IMAGE_SEPARATE_DEBUG_HEADER, Characteristics, 2)
1419 TEST_FIELD_ALIGN (IMAGE_SEPARATE_DEBUG_HEADER, Characteristics, 2)
1433 TEST_FIELD_SIZE (IMAGE_SEPARATE_DEBUG_HEADER, NumberOfSections, 4)
1434 TEST_FIELD_ALIGN (IMAGE_SEPARATE_DEBUG_HEADER, NumberOfSections, 4)
1435 TEST_FIELD_OFFSET(IMAGE_SEPARATE_DEBUG_HEADER, NumberOfSections, 24)
1436 TEST_FIELD_SIZE (IMAGE_SEPARATE_DEBUG_HEADER, ExportedNamesSize, 4)
1437 TEST_FIELD_ALIGN (IMAGE_SEPARATE_DEBUG_HEADER, ExportedNamesSize, 4)
1438 TEST_FIELD_OFFSET(IMAGE_SEPARATE_DEBUG_HEADER, ExportedNamesSize, 28)
1439 TEST_FIELD_SIZE (IMAGE_SEPARATE_DEBUG_HEADER, DebugDirectorySize, 4)
1440 TEST_FIELD_ALIGN (IMAGE_SEPARATE_DEBUG_HEADER, DebugDirectorySize, 4)
1441 TEST_FIELD_OFFSET(IMAGE_SEPARATE_DEBUG_HEADER, DebugDirectorySize, 32)
1442 TEST_FIELD_SIZE (IMAGE_SEPARATE_DEBUG_HEADER, SectionAlignment, 4)
1443 TEST_FIELD_ALIGN (IMAGE_SEPARATE_DEBUG_HEADER, SectionAlignment, 4)
1444 TEST_FIELD_OFFSET(IMAGE_SEPARATE_DEBUG_HEADER, SectionAlignment, 36)
1448}
1449
1450static void test_pack_IMAGE_SYMBOL(void)
1451{
1452 /* IMAGE_SYMBOL (pack 2) */
1453}
1454
1455static void test_pack_IMAGE_THUNK_DATA(void)
1456{
1457 /* IMAGE_THUNK_DATA */
1458}
1459
1460static void test_pack_IMAGE_TLS_DIRECTORY(void)
1461{
1462 /* IMAGE_TLS_DIRECTORY */
1465}
1466
1467static void test_pack_IMAGE_TLS_DIRECTORY32(void)
1468{
1469 /* IMAGE_TLS_DIRECTORY32 */
1472 TEST_FIELD_SIZE (IMAGE_TLS_DIRECTORY32, StartAddressOfRawData, 4)
1473 TEST_FIELD_ALIGN (IMAGE_TLS_DIRECTORY32, StartAddressOfRawData, 4)
1474 TEST_FIELD_OFFSET(IMAGE_TLS_DIRECTORY32, StartAddressOfRawData, 0)
1475 TEST_FIELD_SIZE (IMAGE_TLS_DIRECTORY32, EndAddressOfRawData, 4)
1476 TEST_FIELD_ALIGN (IMAGE_TLS_DIRECTORY32, EndAddressOfRawData, 4)
1477 TEST_FIELD_OFFSET(IMAGE_TLS_DIRECTORY32, EndAddressOfRawData, 4)
1478 TEST_FIELD_SIZE (IMAGE_TLS_DIRECTORY32, AddressOfIndex, 4)
1479 TEST_FIELD_ALIGN (IMAGE_TLS_DIRECTORY32, AddressOfIndex, 4)
1480 TEST_FIELD_OFFSET(IMAGE_TLS_DIRECTORY32, AddressOfIndex, 8)
1481 TEST_FIELD_SIZE (IMAGE_TLS_DIRECTORY32, AddressOfCallBacks, 4)
1482 TEST_FIELD_ALIGN (IMAGE_TLS_DIRECTORY32, AddressOfCallBacks, 4)
1483 TEST_FIELD_OFFSET(IMAGE_TLS_DIRECTORY32, AddressOfCallBacks, 12)
1484 TEST_FIELD_SIZE (IMAGE_TLS_DIRECTORY32, SizeOfZeroFill, 4)
1485 TEST_FIELD_ALIGN (IMAGE_TLS_DIRECTORY32, SizeOfZeroFill, 4)
1486 TEST_FIELD_OFFSET(IMAGE_TLS_DIRECTORY32, SizeOfZeroFill, 16)
1487 TEST_FIELD_SIZE (IMAGE_TLS_DIRECTORY32, Characteristics, 4)
1488 TEST_FIELD_ALIGN (IMAGE_TLS_DIRECTORY32, Characteristics, 4)
1489 TEST_FIELD_OFFSET(IMAGE_TLS_DIRECTORY32, Characteristics, 20)
1490}
1491
1492static void test_pack_IMAGE_TLS_DIRECTORY64(void)
1493{
1494 /* IMAGE_TLS_DIRECTORY64 */
1497 TEST_FIELD_SIZE (IMAGE_TLS_DIRECTORY64, StartAddressOfRawData, 8)
1498 TEST_FIELD_ALIGN (IMAGE_TLS_DIRECTORY64, StartAddressOfRawData, 8)
1499 TEST_FIELD_OFFSET(IMAGE_TLS_DIRECTORY64, StartAddressOfRawData, 0)
1500 TEST_FIELD_SIZE (IMAGE_TLS_DIRECTORY64, EndAddressOfRawData, 8)
1501 TEST_FIELD_ALIGN (IMAGE_TLS_DIRECTORY64, EndAddressOfRawData, 8)
1502 TEST_FIELD_OFFSET(IMAGE_TLS_DIRECTORY64, EndAddressOfRawData, 8)
1503 TEST_FIELD_SIZE (IMAGE_TLS_DIRECTORY64, AddressOfIndex, 8)
1504 TEST_FIELD_ALIGN (IMAGE_TLS_DIRECTORY64, AddressOfIndex, 8)
1505 TEST_FIELD_OFFSET(IMAGE_TLS_DIRECTORY64, AddressOfIndex, 16)
1506 TEST_FIELD_SIZE (IMAGE_TLS_DIRECTORY64, AddressOfCallBacks, 8)
1507 TEST_FIELD_ALIGN (IMAGE_TLS_DIRECTORY64, AddressOfCallBacks, 8)
1508 TEST_FIELD_OFFSET(IMAGE_TLS_DIRECTORY64, AddressOfCallBacks, 24)
1509 TEST_FIELD_SIZE (IMAGE_TLS_DIRECTORY64, SizeOfZeroFill, 4)
1510 TEST_FIELD_ALIGN (IMAGE_TLS_DIRECTORY64, SizeOfZeroFill, 4)
1511 TEST_FIELD_OFFSET(IMAGE_TLS_DIRECTORY64, SizeOfZeroFill, 32)
1512 TEST_FIELD_SIZE (IMAGE_TLS_DIRECTORY64, Characteristics, 4)
1513 TEST_FIELD_ALIGN (IMAGE_TLS_DIRECTORY64, Characteristics, 4)
1514 TEST_FIELD_OFFSET(IMAGE_TLS_DIRECTORY64, Characteristics, 36)
1515}
1516
1517static void test_pack_IMAGE_VXD_HEADER(void)
1518{
1519 /* IMAGE_VXD_HEADER (pack 2) */
1522 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_magic, 2)
1523 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_magic, 2)
1524 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_magic, 0)
1525 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_border, 1)
1526 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_border, 1)
1527 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_border, 2)
1528 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_worder, 1)
1529 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_worder, 1)
1530 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_worder, 3)
1531 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_level, 4)
1532 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_level, 2)
1533 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_level, 4)
1534 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_cpu, 2)
1540 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_ver, 4)
1543 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_mflags, 4)
1544 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_mflags, 2)
1545 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_mflags, 16)
1546 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_mpages, 4)
1547 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_mpages, 2)
1548 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_mpages, 20)
1549 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_startobj, 4)
1550 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_startobj, 2)
1551 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_startobj, 24)
1552 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_eip, 4)
1555 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_stackobj, 4)
1556 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_stackobj, 2)
1557 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_stackobj, 32)
1558 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_esp, 4)
1561 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_pagesize, 4)
1562 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_pagesize, 2)
1563 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_pagesize, 40)
1564 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_lastpagesize, 4)
1565 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_lastpagesize, 2)
1566 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_lastpagesize, 44)
1567 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_fixupsize, 4)
1568 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_fixupsize, 2)
1569 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_fixupsize, 48)
1570 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_fixupsum, 4)
1571 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_fixupsum, 2)
1572 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_fixupsum, 52)
1573 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_ldrsize, 4)
1574 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_ldrsize, 2)
1575 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_ldrsize, 56)
1576 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_ldrsum, 4)
1577 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_ldrsum, 2)
1578 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_ldrsum, 60)
1579 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_objtab, 4)
1580 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_objtab, 2)
1581 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_objtab, 64)
1582 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_objcnt, 4)
1583 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_objcnt, 2)
1584 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_objcnt, 68)
1585 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_objmap, 4)
1586 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_objmap, 2)
1587 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_objmap, 72)
1588 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_itermap, 4)
1589 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_itermap, 2)
1590 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_itermap, 76)
1591 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_rsrctab, 4)
1592 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_rsrctab, 2)
1593 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_rsrctab, 80)
1594 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_rsrccnt, 4)
1595 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_rsrccnt, 2)
1596 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_rsrccnt, 84)
1597 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_restab, 4)
1598 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_restab, 2)
1599 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_restab, 88)
1600 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_enttab, 4)
1601 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_enttab, 2)
1602 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_enttab, 92)
1603 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_dirtab, 4)
1604 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_dirtab, 2)
1605 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_dirtab, 96)
1606 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_dircnt, 4)
1607 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_dircnt, 2)
1608 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_dircnt, 100)
1609 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_fpagetab, 4)
1610 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_fpagetab, 2)
1611 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_fpagetab, 104)
1612 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_frectab, 4)
1613 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_frectab, 2)
1614 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_frectab, 108)
1615 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_impmod, 4)
1616 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_impmod, 2)
1617 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_impmod, 112)
1618 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_impmodcnt, 4)
1619 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_impmodcnt, 2)
1620 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_impmodcnt, 116)
1621 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_impproc, 4)
1622 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_impproc, 2)
1623 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_impproc, 120)
1624 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_pagesum, 4)
1625 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_pagesum, 2)
1626 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_pagesum, 124)
1627 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_datapage, 4)
1628 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_datapage, 2)
1629 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_datapage, 128)
1630 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_preload, 4)
1631 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_preload, 2)
1632 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_preload, 132)
1633 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_nrestab, 4)
1634 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_nrestab, 2)
1635 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_nrestab, 136)
1636 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_cbnrestab, 4)
1637 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_cbnrestab, 2)
1638 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_cbnrestab, 140)
1639 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_nressum, 4)
1640 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_nressum, 2)
1641 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_nressum, 144)
1642 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_autodata, 4)
1643 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_autodata, 2)
1644 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_autodata, 148)
1645 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_debuginfo, 4)
1646 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_debuginfo, 2)
1647 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_debuginfo, 152)
1648 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_debuglen, 4)
1649 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_debuglen, 2)
1650 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_debuglen, 156)
1651 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_instpreload, 4)
1652 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_instpreload, 2)
1653 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_instpreload, 160)
1654 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_instdemand, 4)
1655 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_instdemand, 2)
1656 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_instdemand, 164)
1657 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_heapsize, 4)
1658 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_heapsize, 2)
1659 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_heapsize, 168)
1660 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_res3, 12)
1661 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_res3, 1)
1662 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_res3, 172)
1663 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_winresoff, 4)
1664 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_winresoff, 2)
1665 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_winresoff, 184)
1666 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_winreslen, 4)
1667 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_winreslen, 2)
1668 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_winreslen, 188)
1669 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_devid, 2)
1670 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_devid, 2)
1671 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_devid, 192)
1672 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_ddkver, 2)
1673 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_ddkver, 2)
1674 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_ddkver, 194)
1675}
1676
1677static void test_pack_IO_COUNTERS(void)
1678{
1679 /* IO_COUNTERS (pack 8) */
1682 TEST_FIELD_SIZE (IO_COUNTERS, ReadOperationCount, 8)
1683 TEST_FIELD_ALIGN (IO_COUNTERS, ReadOperationCount, 8)
1684 TEST_FIELD_OFFSET(IO_COUNTERS, ReadOperationCount, 0)
1685 TEST_FIELD_SIZE (IO_COUNTERS, WriteOperationCount, 8)
1686 TEST_FIELD_ALIGN (IO_COUNTERS, WriteOperationCount, 8)
1687 TEST_FIELD_OFFSET(IO_COUNTERS, WriteOperationCount, 8)
1688 TEST_FIELD_SIZE (IO_COUNTERS, OtherOperationCount, 8)
1689 TEST_FIELD_ALIGN (IO_COUNTERS, OtherOperationCount, 8)
1690 TEST_FIELD_OFFSET(IO_COUNTERS, OtherOperationCount, 16)
1691 TEST_FIELD_SIZE (IO_COUNTERS, ReadTransferCount, 8)
1692 TEST_FIELD_ALIGN (IO_COUNTERS, ReadTransferCount, 8)
1693 TEST_FIELD_OFFSET(IO_COUNTERS, ReadTransferCount, 24)
1694 TEST_FIELD_SIZE (IO_COUNTERS, WriteTransferCount, 8)
1695 TEST_FIELD_ALIGN (IO_COUNTERS, WriteTransferCount, 8)
1696 TEST_FIELD_OFFSET(IO_COUNTERS, WriteTransferCount, 32)
1697 TEST_FIELD_SIZE (IO_COUNTERS, OtherTransferCount, 8)
1698 TEST_FIELD_ALIGN (IO_COUNTERS, OtherTransferCount, 8)
1699 TEST_FIELD_OFFSET(IO_COUNTERS, OtherTransferCount, 40)
1700}
1701
1702static void test_pack_LANGID(void)
1703{
1704 /* LANGID */
1708}
1709
1710static void test_pack_LARGE_INTEGER(void)
1711{
1712 /* LARGE_INTEGER */
1713}
1714
1715static void test_pack_LCID(void)
1716{
1717 /* LCID */
1718 TEST_TYPE_SIZE (LCID, 4)
1721}
1722
1723static void test_pack_LIST_ENTRY(void)
1724{
1725 /* LIST_ENTRY */
1728 TEST_FIELD_SIZE (LIST_ENTRY, Flink, 8)
1729 TEST_FIELD_ALIGN (LIST_ENTRY, Flink, 8)
1730 TEST_FIELD_OFFSET(LIST_ENTRY, Flink, 0)
1731 TEST_FIELD_SIZE (LIST_ENTRY, Blink, 8)
1732 TEST_FIELD_ALIGN (LIST_ENTRY, Blink, 8)
1733 TEST_FIELD_OFFSET(LIST_ENTRY, Blink, 8)
1734}
1735
1736static void test_pack_LONG(void)
1737{
1738 /* LONG */
1739 TEST_TYPE_SIZE (LONG, 4)
1742}
1743
1744static void test_pack_LONGLONG(void)
1745{
1746 /* LONGLONG */
1750}
1751
1752static void test_pack_LUID(void)
1753{
1754 /* LUID */
1755 TEST_TYPE_SIZE (LUID, 8)
1757 TEST_FIELD_SIZE (LUID, LowPart, 4)
1758 TEST_FIELD_ALIGN (LUID, LowPart, 4)
1759 TEST_FIELD_OFFSET(LUID, LowPart, 0)
1760 TEST_FIELD_SIZE (LUID, HighPart, 4)
1761 TEST_FIELD_ALIGN (LUID, HighPart, 4)
1762 TEST_FIELD_OFFSET(LUID, HighPart, 4)
1763}
1764
1765static void test_pack_LUID_AND_ATTRIBUTES(void)
1766{
1767 /* LUID_AND_ATTRIBUTES (pack 4) */
1776}
1777
1778static void test_pack_MEMORY_BASIC_INFORMATION(void)
1779{
1780 /* MEMORY_BASIC_INFORMATION */
1786 TEST_FIELD_SIZE (MEMORY_BASIC_INFORMATION, AllocationBase, 8)
1787 TEST_FIELD_ALIGN (MEMORY_BASIC_INFORMATION, AllocationBase, 8)
1789 TEST_FIELD_SIZE (MEMORY_BASIC_INFORMATION, AllocationProtect, 4)
1790 TEST_FIELD_ALIGN (MEMORY_BASIC_INFORMATION, AllocationProtect, 4)
1791 TEST_FIELD_OFFSET(MEMORY_BASIC_INFORMATION, AllocationProtect, 16)
1804}
1805
1806static void test_pack_MESSAGE_RESOURCE_BLOCK(void)
1807{
1808 /* MESSAGE_RESOURCE_BLOCK */
1817 TEST_FIELD_SIZE (MESSAGE_RESOURCE_BLOCK, OffsetToEntries, 4)
1818 TEST_FIELD_ALIGN (MESSAGE_RESOURCE_BLOCK, OffsetToEntries, 4)
1819 TEST_FIELD_OFFSET(MESSAGE_RESOURCE_BLOCK, OffsetToEntries, 8)
1820}
1821
1822static void test_pack_MESSAGE_RESOURCE_DATA(void)
1823{
1824 /* MESSAGE_RESOURCE_DATA */
1827 TEST_FIELD_SIZE (MESSAGE_RESOURCE_DATA, NumberOfBlocks, 4)
1828 TEST_FIELD_ALIGN (MESSAGE_RESOURCE_DATA, NumberOfBlocks, 4)
1829 TEST_FIELD_OFFSET(MESSAGE_RESOURCE_DATA, NumberOfBlocks, 0)
1833}
1834
1835static void test_pack_MESSAGE_RESOURCE_ENTRY(void)
1836{
1837 /* MESSAGE_RESOURCE_ENTRY */
1849}
1850
1851static void test_pack_NT_TIB(void)
1852{
1853 /* NT_TIB */
1854 TEST_FIELD_SIZE (NT_TIB, ExceptionList, 8)
1855 TEST_FIELD_ALIGN (NT_TIB, ExceptionList, 8)
1856 TEST_FIELD_OFFSET(NT_TIB, ExceptionList, 0)
1857 TEST_FIELD_SIZE (NT_TIB, StackBase, 8)
1858 TEST_FIELD_ALIGN (NT_TIB, StackBase, 8)
1859 TEST_FIELD_OFFSET(NT_TIB, StackBase, 8)
1860 TEST_FIELD_SIZE (NT_TIB, StackLimit, 8)
1861 TEST_FIELD_ALIGN (NT_TIB, StackLimit, 8)
1862 TEST_FIELD_OFFSET(NT_TIB, StackLimit, 16)
1863 TEST_FIELD_SIZE (NT_TIB, SubSystemTib, 8)
1864 TEST_FIELD_ALIGN (NT_TIB, SubSystemTib, 8)
1865 TEST_FIELD_OFFSET(NT_TIB, SubSystemTib, 24)
1866}
1867
1868static void test_pack_OBJECT_TYPE_LIST(void)
1869{
1870 /* OBJECT_TYPE_LIST */
1882}
1883
1884static void test_pack_PACCESS_ALLOWED_ACE(void)
1885{
1886 /* PACCESS_ALLOWED_ACE */
1891}
1892
1893static void test_pack_PACCESS_DENIED_ACE(void)
1894{
1895 /* PACCESS_DENIED_ACE */
1900}
1901
1902static void test_pack_PACCESS_TOKEN(void)
1903{
1904 /* PACCESS_TOKEN */
1907}
1908
1909static void test_pack_PACE_HEADER(void)
1910{
1911 /* PACE_HEADER */
1916}
1917
1918static void test_pack_PACL(void)
1919{
1920 /* PACL */
1921 TEST_TYPE_SIZE (PACL, 8)
1925}
1926
1928{
1929 /* PACL_REVISION_INFORMATION */
1934}
1935
1936static void test_pack_PACL_SIZE_INFORMATION(void)
1937{
1938 /* PACL_SIZE_INFORMATION */
1943}
1944
1945static void test_pack_PCCH(void)
1946{
1947 /* PCCH */
1948 TEST_TYPE_SIZE (PCCH, 8)
1952}
1953
1954static void test_pack_PCH(void)
1955{
1956 /* PCH */
1957 TEST_TYPE_SIZE (PCH, 8)
1958 TEST_TYPE_ALIGN (PCH, 8)
1961}
1962
1963static void test_pack_PCSTR(void)
1964{
1965 /* PCSTR */
1970}
1971
1972static void test_pack_PCWCH(void)
1973{
1974 /* PCWCH */
1979}
1980
1981static void test_pack_PCWSTR(void)
1982{
1983 /* PCWSTR */
1988}
1989
1990static void test_pack_PEXCEPTION_POINTERS(void)
1991{
1992 /* PEXCEPTION_POINTERS */
1997}
1998
1999static void test_pack_PEXCEPTION_RECORD(void)
2000{
2001 /* PEXCEPTION_RECORD */
2006}
2007
2008static void test_pack_PFPO_DATA(void)
2009{
2010 /* PFPO_DATA */
2015}
2016
2017static void test_pack_PGENERIC_MAPPING(void)
2018{
2019 /* PGENERIC_MAPPING */
2024}
2025
2026static void test_pack_PHANDLE(void)
2027{
2028 /* PHANDLE */
2033}
2034
2036{
2037 /* PIMAGE_ARCHIVE_MEMBER_HEADER */
2042}
2043
2044static void test_pack_PIMAGE_AUX_SYMBOL(void)
2045{
2046 /* PIMAGE_AUX_SYMBOL */
2049}
2050
2051static void test_pack_PIMAGE_BASE_RELOCATION(void)
2052{
2053 /* PIMAGE_BASE_RELOCATION */
2058}
2059
2061{
2062 /* PIMAGE_BOUND_FORWARDER_REF */
2067}
2068
2070{
2071 /* PIMAGE_BOUND_IMPORT_DESCRIPTOR */
2076}
2077
2079{
2080 /* PIMAGE_COFF_SYMBOLS_HEADER */
2085}
2086
2087static void test_pack_PIMAGE_DATA_DIRECTORY(void)
2088{
2089 /* PIMAGE_DATA_DIRECTORY */
2094}
2095
2096static void test_pack_PIMAGE_DEBUG_DIRECTORY(void)
2097{
2098 /* PIMAGE_DEBUG_DIRECTORY */
2103}
2104
2105static void test_pack_PIMAGE_DEBUG_MISC(void)
2106{
2107 /* PIMAGE_DEBUG_MISC */
2112}
2113
2114static void test_pack_PIMAGE_DOS_HEADER(void)
2115{
2116 /* PIMAGE_DOS_HEADER */
2121}
2122
2123static void test_pack_PIMAGE_EXPORT_DIRECTORY(void)
2124{
2125 /* PIMAGE_EXPORT_DIRECTORY */
2130}
2131
2132static void test_pack_PIMAGE_FILE_HEADER(void)
2133{
2134 /* PIMAGE_FILE_HEADER */
2139}
2140
2141static void test_pack_PIMAGE_FUNCTION_ENTRY(void)
2142{
2143 /* PIMAGE_FUNCTION_ENTRY */
2148}
2149
2150static void test_pack_PIMAGE_IMPORT_BY_NAME(void)
2151{
2152 /* PIMAGE_IMPORT_BY_NAME */
2157}
2158
2159static void test_pack_PIMAGE_IMPORT_DESCRIPTOR(void)
2160{
2161 /* PIMAGE_IMPORT_DESCRIPTOR */
2164}
2165
2166static void test_pack_PIMAGE_LINENUMBER(void)
2167{
2168 /* PIMAGE_LINENUMBER */
2171}
2172
2174{
2175 /* PIMAGE_LOAD_CONFIG_DIRECTORY */
2178}
2179
2180static void test_pack_PIMAGE_NT_HEADERS(void)
2181{
2182 /* PIMAGE_NT_HEADERS */
2185}
2186
2187static void test_pack_PIMAGE_NT_HEADERS32(void)
2188{
2189 /* PIMAGE_NT_HEADERS32 */
2194}
2195
2196static void test_pack_PIMAGE_NT_HEADERS64(void)
2197{
2198 /* PIMAGE_NT_HEADERS64 */
2203}
2204
2205static void test_pack_PIMAGE_OPTIONAL_HEADER(void)
2206{
2207 /* PIMAGE_OPTIONAL_HEADER */
2210}
2211
2212static void test_pack_PIMAGE_OPTIONAL_HEADER32(void)
2213{
2214 /* PIMAGE_OPTIONAL_HEADER32 */
2219}
2220
2221static void test_pack_PIMAGE_OPTIONAL_HEADER64(void)
2222{
2223 /* PIMAGE_OPTIONAL_HEADER64 */
2228}
2229
2230static void test_pack_PIMAGE_OS2_HEADER(void)
2231{
2232 /* PIMAGE_OS2_HEADER */
2237}
2238
2239static void test_pack_PIMAGE_RELOCATION(void)
2240{
2241 /* PIMAGE_RELOCATION */
2244}
2245
2247{
2248 /* PIMAGE_RESOURCE_DATA_ENTRY */
2253}
2254
2256{
2257 /* PIMAGE_RESOURCE_DIRECTORY */
2262}
2263
2265{
2266 /* PIMAGE_RESOURCE_DIRECTORY_ENTRY */
2269}
2270
2272{
2273 /* PIMAGE_RESOURCE_DIRECTORY_STRING */
2278}
2279
2281{
2282 /* PIMAGE_RESOURCE_DIR_STRING_U */
2287}
2288
2289static void test_pack_PIMAGE_SECTION_HEADER(void)
2290{
2291 /* PIMAGE_SECTION_HEADER */
2294}
2295
2297{
2298 /* PIMAGE_SEPARATE_DEBUG_HEADER */
2303}
2304
2305static void test_pack_PIMAGE_SYMBOL(void)
2306{
2307 /* PIMAGE_SYMBOL */
2310}
2311
2312static void test_pack_PIMAGE_THUNK_DATA(void)
2313{
2314 /* PIMAGE_THUNK_DATA */
2317}
2318
2319static void test_pack_PIMAGE_TLS_CALLBACK(void)
2320{
2321 /* PIMAGE_TLS_CALLBACK */
2324}
2325
2326static void test_pack_PIMAGE_TLS_DIRECTORY(void)
2327{
2328 /* PIMAGE_TLS_DIRECTORY */
2331}
2332
2333static void test_pack_PIMAGE_VXD_HEADER(void)
2334{
2335 /* PIMAGE_VXD_HEADER */
2340}
2341
2342static void test_pack_PIO_COUNTERS(void)
2343{
2344 /* PIO_COUNTERS */
2349}
2350
2351static void test_pack_PISECURITY_DESCRIPTOR(void)
2352{
2353 /* PISECURITY_DESCRIPTOR */
2358}
2359
2361{
2362 /* PISECURITY_DESCRIPTOR_RELATIVE */
2367}
2368
2369static void test_pack_PISID(void)
2370{
2371 /* PISID */
2376}
2377
2378static void test_pack_PLARGE_INTEGER(void)
2379{
2380 /* PLARGE_INTEGER */
2383}
2384
2385static void test_pack_PLIST_ENTRY(void)
2386{
2387 /* PLIST_ENTRY */
2392}
2393
2394static void test_pack_PLUID(void)
2395{
2396 /* PLUID */
2401}
2402
2403static void test_pack_PLUID_AND_ATTRIBUTES(void)
2404{
2405 /* PLUID_AND_ATTRIBUTES */
2410}
2411
2413{
2414 /* PMEMORY_BASIC_INFORMATION */
2419}
2420
2421static void test_pack_PMESSAGE_RESOURCE_BLOCK(void)
2422{
2423 /* PMESSAGE_RESOURCE_BLOCK */
2428}
2429
2430static void test_pack_PMESSAGE_RESOURCE_DATA(void)
2431{
2432 /* PMESSAGE_RESOURCE_DATA */
2437}
2438
2439static void test_pack_PMESSAGE_RESOURCE_ENTRY(void)
2440{
2441 /* PMESSAGE_RESOURCE_ENTRY */
2446}
2447
2448static void test_pack_PNT_TIB(void)
2449{
2450 /* PNT_TIB */
2453}
2454
2455static void test_pack_POBJECT_TYPE_LIST(void)
2456{
2457 /* POBJECT_TYPE_LIST */
2462}
2463
2464static void test_pack_PPRIVILEGE_SET(void)
2465{
2466 /* PPRIVILEGE_SET */
2471}
2472
2473static void test_pack_PRIVILEGE_SET(void)
2474{
2475 /* PRIVILEGE_SET */
2478 TEST_FIELD_SIZE (PRIVILEGE_SET, PrivilegeCount, 4)
2479 TEST_FIELD_ALIGN (PRIVILEGE_SET, PrivilegeCount, 4)
2480 TEST_FIELD_OFFSET(PRIVILEGE_SET, PrivilegeCount, 0)
2487}
2488
2489static void test_pack_PRLIST_ENTRY(void)
2490{
2491 /* PRLIST_ENTRY */
2496}
2497
2498static void test_pack_PRTL_CRITICAL_SECTION(void)
2499{
2500 /* PRTL_CRITICAL_SECTION */
2505}
2506
2508{
2509 /* PRTL_CRITICAL_SECTION_DEBUG */
2512}
2513
2514static void test_pack_PRTL_OSVERSIONINFOEXW(void)
2515{
2516 /* PRTL_OSVERSIONINFOEXW */
2521}
2522
2523static void test_pack_PRTL_OSVERSIONINFOW(void)
2524{
2525 /* PRTL_OSVERSIONINFOW */
2530}
2531
2532static void test_pack_PRTL_RESOURCE_DEBUG(void)
2533{
2534 /* PRTL_RESOURCE_DEBUG */
2537}
2538
2539static void test_pack_PSECURITY_DESCRIPTOR(void)
2540{
2541 /* PSECURITY_DESCRIPTOR */
2544}
2545
2547{
2548 /* PSECURITY_QUALITY_OF_SERVICE */
2551}
2552
2553static void test_pack_PSID(void)
2554{
2555 /* PSID */
2556 TEST_TYPE_SIZE (PSID, 8)
2558}
2559
2561{
2562 /* PSID_IDENTIFIER_AUTHORITY */
2567}
2568
2569static void test_pack_PSINGLE_LIST_ENTRY(void)
2570{
2571 /* PSINGLE_LIST_ENTRY */
2576}
2577
2578static void test_pack_PSTR(void)
2579{
2580 /* PSTR */
2581 TEST_TYPE_SIZE (PSTR, 8)
2585}
2586
2587static void test_pack_PSYSTEM_ALARM_ACE(void)
2588{
2589 /* PSYSTEM_ALARM_ACE */
2594}
2595
2596static void test_pack_PSYSTEM_AUDIT_ACE(void)
2597{
2598 /* PSYSTEM_AUDIT_ACE */
2603}
2604
2605static void test_pack_PTOKEN_GROUPS(void)
2606{
2607 /* PTOKEN_GROUPS */
2612}
2613
2614static void test_pack_PTOKEN_PRIVILEGES(void)
2615{
2616 /* PTOKEN_PRIVILEGES */
2621}
2622
2623static void test_pack_PTOKEN_USER(void)
2624{
2625 /* PTOKEN_USER */
2630}
2631
2632static void test_pack_PULARGE_INTEGER(void)
2633{
2634 /* PULARGE_INTEGER */
2637}
2638
2640{
2641 /* PVECTORED_EXCEPTION_HANDLER */
2644}
2645
2646static void test_pack_PVOID(void)
2647{
2648 /* PVOID */
2651}
2652
2653static void test_pack_PWCH(void)
2654{
2655 /* PWCH */
2656 TEST_TYPE_SIZE (PWCH, 8)
2660}
2661
2662static void test_pack_PWSTR(void)
2663{
2664 /* PWSTR */
2669}
2670
2671static void test_pack_RTL_CRITICAL_SECTION(void)
2672{
2673 /* RTL_CRITICAL_SECTION */
2682 TEST_FIELD_SIZE (RTL_CRITICAL_SECTION, RecursionCount, 4)
2683 TEST_FIELD_ALIGN (RTL_CRITICAL_SECTION, RecursionCount, 4)
2684 TEST_FIELD_OFFSET(RTL_CRITICAL_SECTION, RecursionCount, 12)
2688 TEST_FIELD_SIZE (RTL_CRITICAL_SECTION, LockSemaphore, 8)
2689 TEST_FIELD_ALIGN (RTL_CRITICAL_SECTION, LockSemaphore, 8)
2690 TEST_FIELD_OFFSET(RTL_CRITICAL_SECTION, LockSemaphore, 24)
2694}
2695
2697{
2698 /* RTL_CRITICAL_SECTION_DEBUG */
2702 TEST_FIELD_SIZE (RTL_CRITICAL_SECTION_DEBUG, CreatorBackTraceIndex, 2)
2703 TEST_FIELD_ALIGN (RTL_CRITICAL_SECTION_DEBUG, CreatorBackTraceIndex, 2)
2704 TEST_FIELD_OFFSET(RTL_CRITICAL_SECTION_DEBUG, CreatorBackTraceIndex, 2)
2708 TEST_FIELD_SIZE (RTL_CRITICAL_SECTION_DEBUG, ProcessLocksList, 16)
2709 TEST_FIELD_ALIGN (RTL_CRITICAL_SECTION_DEBUG, ProcessLocksList, 8)
2710 TEST_FIELD_OFFSET(RTL_CRITICAL_SECTION_DEBUG, ProcessLocksList, 16)
2714 TEST_FIELD_SIZE (RTL_CRITICAL_SECTION_DEBUG, ContentionCount, 4)
2715 TEST_FIELD_ALIGN (RTL_CRITICAL_SECTION_DEBUG, ContentionCount, 4)
2716 TEST_FIELD_OFFSET(RTL_CRITICAL_SECTION_DEBUG, ContentionCount, 36)
2717}
2718
2719static void test_pack_RTL_OSVERSIONINFOEXW(void)
2720{
2721 /* RTL_OSVERSIONINFOEXW */
2724 TEST_FIELD_SIZE (RTL_OSVERSIONINFOEXW, dwOSVersionInfoSize, 4)
2725 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOEXW, dwOSVersionInfoSize, 4)
2726 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOEXW, dwOSVersionInfoSize, 0)
2727 TEST_FIELD_SIZE (RTL_OSVERSIONINFOEXW, dwMajorVersion, 4)
2728 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOEXW, dwMajorVersion, 4)
2729 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOEXW, dwMajorVersion, 4)
2730 TEST_FIELD_SIZE (RTL_OSVERSIONINFOEXW, dwMinorVersion, 4)
2731 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOEXW, dwMinorVersion, 4)
2732 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOEXW, dwMinorVersion, 8)
2733 TEST_FIELD_SIZE (RTL_OSVERSIONINFOEXW, dwBuildNumber, 4)
2734 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOEXW, dwBuildNumber, 4)
2735 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOEXW, dwBuildNumber, 12)
2736 TEST_FIELD_SIZE (RTL_OSVERSIONINFOEXW, dwPlatformId, 4)
2737 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOEXW, dwPlatformId, 4)
2738 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOEXW, dwPlatformId, 16)
2739 TEST_FIELD_SIZE (RTL_OSVERSIONINFOEXW, szCSDVersion, 256)
2740 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOEXW, szCSDVersion, 2)
2741 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOEXW, szCSDVersion, 20)
2742 TEST_FIELD_SIZE (RTL_OSVERSIONINFOEXW, wServicePackMajor, 2)
2743 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOEXW, wServicePackMajor, 2)
2744 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOEXW, wServicePackMajor, 276)
2745 TEST_FIELD_SIZE (RTL_OSVERSIONINFOEXW, wServicePackMinor, 2)
2746 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOEXW, wServicePackMinor, 2)
2747 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOEXW, wServicePackMinor, 278)
2748 TEST_FIELD_SIZE (RTL_OSVERSIONINFOEXW, wSuiteMask, 2)
2749 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOEXW, wSuiteMask, 2)
2750 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOEXW, wSuiteMask, 280)
2751 TEST_FIELD_SIZE (RTL_OSVERSIONINFOEXW, wProductType, 1)
2752 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOEXW, wProductType, 1)
2753 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOEXW, wProductType, 282)
2757}
2758
2759static void test_pack_RTL_OSVERSIONINFOW(void)
2760{
2761 /* RTL_OSVERSIONINFOW */
2764 TEST_FIELD_SIZE (RTL_OSVERSIONINFOW, dwOSVersionInfoSize, 4)
2765 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOW, dwOSVersionInfoSize, 4)
2766 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOW, dwOSVersionInfoSize, 0)
2767 TEST_FIELD_SIZE (RTL_OSVERSIONINFOW, dwMajorVersion, 4)
2768 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOW, dwMajorVersion, 4)
2769 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOW, dwMajorVersion, 4)
2770 TEST_FIELD_SIZE (RTL_OSVERSIONINFOW, dwMinorVersion, 4)
2771 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOW, dwMinorVersion, 4)
2772 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOW, dwMinorVersion, 8)
2773 TEST_FIELD_SIZE (RTL_OSVERSIONINFOW, dwBuildNumber, 4)
2774 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOW, dwBuildNumber, 4)
2775 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOW, dwBuildNumber, 12)
2776 TEST_FIELD_SIZE (RTL_OSVERSIONINFOW, dwPlatformId, 4)
2777 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOW, dwPlatformId, 4)
2778 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOW, dwPlatformId, 16)
2779 TEST_FIELD_SIZE (RTL_OSVERSIONINFOW, szCSDVersion, 256)
2780 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOW, szCSDVersion, 2)
2781 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOW, szCSDVersion, 20)
2782}
2783
2784static void test_pack_RTL_RESOURCE_DEBUG(void)
2785{
2786 /* RTL_RESOURCE_DEBUG */
2790 TEST_FIELD_SIZE (RTL_RESOURCE_DEBUG, CreatorBackTraceIndex, 2)
2791 TEST_FIELD_ALIGN (RTL_RESOURCE_DEBUG, CreatorBackTraceIndex, 2)
2792 TEST_FIELD_OFFSET(RTL_RESOURCE_DEBUG, CreatorBackTraceIndex, 2)
2796 TEST_FIELD_SIZE (RTL_RESOURCE_DEBUG, ProcessLocksList, 16)
2797 TEST_FIELD_ALIGN (RTL_RESOURCE_DEBUG, ProcessLocksList, 8)
2798 TEST_FIELD_OFFSET(RTL_RESOURCE_DEBUG, ProcessLocksList, 16)
2799 TEST_FIELD_SIZE (RTL_RESOURCE_DEBUG, EntryCount, 4)
2800 TEST_FIELD_ALIGN (RTL_RESOURCE_DEBUG, EntryCount, 4)
2801 TEST_FIELD_OFFSET(RTL_RESOURCE_DEBUG, EntryCount, 32)
2802 TEST_FIELD_SIZE (RTL_RESOURCE_DEBUG, ContentionCount, 4)
2803 TEST_FIELD_ALIGN (RTL_RESOURCE_DEBUG, ContentionCount, 4)
2804 TEST_FIELD_OFFSET(RTL_RESOURCE_DEBUG, ContentionCount, 36)
2805}
2806
2808{
2809 /* SECURITY_CONTEXT_TRACKING_MODE */
2812}
2813
2814static void test_pack_SECURITY_DESCRIPTOR(void)
2815{
2816 /* SECURITY_DESCRIPTOR */
2840}
2841
2843{
2844 /* SECURITY_DESCRIPTOR_CONTROL */
2848}
2849
2851{
2852 /* SECURITY_DESCRIPTOR_RELATIVE */
2876}
2877
2878static void test_pack_SECURITY_INFORMATION(void)
2879{
2880 /* SECURITY_INFORMATION */
2884}
2885
2887{
2888 /* SECURITY_QUALITY_OF_SERVICE */
2892}
2893
2894static void test_pack_SHORT(void)
2895{
2896 /* SHORT */
2900}
2901
2902static void test_pack_SID(void)
2903{
2904 /* SID */
2905 TEST_TYPE_SIZE (SID, 12)
2906 TEST_TYPE_ALIGN (SID, 4)
2916 TEST_FIELD_SIZE (SID, SubAuthority, 4)
2917 TEST_FIELD_ALIGN (SID, SubAuthority, 4)
2918 TEST_FIELD_OFFSET(SID, SubAuthority, 8)
2919}
2920
2921static void test_pack_SID_AND_ATTRIBUTES(void)
2922{
2923 /* SID_AND_ATTRIBUTES */
2932}
2933
2934static void test_pack_SID_IDENTIFIER_AUTHORITY(void)
2935{
2936 /* SID_IDENTIFIER_AUTHORITY */
2942}
2943
2944static void test_pack_SINGLE_LIST_ENTRY(void)
2945{
2946 /* SINGLE_LIST_ENTRY */
2952}
2953
2954static void test_pack_SYSTEM_ALARM_ACE(void)
2955{
2956 /* SYSTEM_ALARM_ACE */
2965 TEST_FIELD_SIZE (SYSTEM_ALARM_ACE, SidStart, 4)
2966 TEST_FIELD_ALIGN (SYSTEM_ALARM_ACE, SidStart, 4)
2968}
2969
2970static void test_pack_SYSTEM_AUDIT_ACE(void)
2971{
2972 /* SYSTEM_AUDIT_ACE */
2981 TEST_FIELD_SIZE (SYSTEM_AUDIT_ACE, SidStart, 4)
2982 TEST_FIELD_ALIGN (SYSTEM_AUDIT_ACE, SidStart, 4)
2984}
2985
2986static void test_pack_TOKEN_DEFAULT_DACL(void)
2987{
2988 /* TOKEN_DEFAULT_DACL */
2991 TEST_FIELD_SIZE (TOKEN_DEFAULT_DACL, DefaultDacl, 8)
2992 TEST_FIELD_ALIGN (TOKEN_DEFAULT_DACL, DefaultDacl, 8)
2993 TEST_FIELD_OFFSET(TOKEN_DEFAULT_DACL, DefaultDacl, 0)
2994}
2995
2996static void test_pack_TOKEN_GROUPS(void)
2997{
2998 /* TOKEN_GROUPS */
3001 TEST_FIELD_SIZE (TOKEN_GROUPS, GroupCount, 4)
3002 TEST_FIELD_ALIGN (TOKEN_GROUPS, GroupCount, 4)
3003 TEST_FIELD_OFFSET(TOKEN_GROUPS, GroupCount, 0)
3004 TEST_FIELD_SIZE (TOKEN_GROUPS, Groups, 16)
3005 TEST_FIELD_ALIGN (TOKEN_GROUPS, Groups, 8)
3007}
3008
3009static void test_pack_TOKEN_OWNER(void)
3010{
3011 /* TOKEN_OWNER */
3017}
3018
3019static void test_pack_TOKEN_PRIMARY_GROUP(void)
3020{
3021 /* TOKEN_PRIMARY_GROUP */
3027}
3028
3029static void test_pack_TOKEN_PRIVILEGES(void)
3030{
3031 /* TOKEN_PRIVILEGES */
3034 TEST_FIELD_SIZE (TOKEN_PRIVILEGES, PrivilegeCount, 4)
3035 TEST_FIELD_ALIGN (TOKEN_PRIVILEGES, PrivilegeCount, 4)
3036 TEST_FIELD_OFFSET(TOKEN_PRIVILEGES, PrivilegeCount, 0)
3040}
3041
3042static void test_pack_TOKEN_SOURCE(void)
3043{
3044 /* TOKEN_SOURCE */
3050 TEST_FIELD_SIZE (TOKEN_SOURCE, SourceIdentifier, 8)
3051 TEST_FIELD_ALIGN (TOKEN_SOURCE, SourceIdentifier, 4)
3052 TEST_FIELD_OFFSET(TOKEN_SOURCE, SourceIdentifier, 8)
3053}
3054
3055static void test_pack_TOKEN_STATISTICS(void)
3056{
3057 /* TOKEN_STATISTICS (pack 4) */
3058 TEST_FIELD_SIZE (TOKEN_STATISTICS, TokenId, 8)
3061 TEST_FIELD_SIZE (TOKEN_STATISTICS, AuthenticationId, 8)
3062 TEST_FIELD_ALIGN (TOKEN_STATISTICS, AuthenticationId, 4)
3063 TEST_FIELD_OFFSET(TOKEN_STATISTICS, AuthenticationId, 8)
3064 TEST_FIELD_SIZE (TOKEN_STATISTICS, ExpirationTime, 8)
3065 TEST_FIELD_ALIGN (TOKEN_STATISTICS, ExpirationTime, 4)
3066 TEST_FIELD_OFFSET(TOKEN_STATISTICS, ExpirationTime, 16)
3067}
3068
3069static void test_pack_TOKEN_USER(void)
3070{
3071 /* TOKEN_USER */
3074 TEST_FIELD_SIZE (TOKEN_USER, User, 16)
3075 TEST_FIELD_ALIGN (TOKEN_USER, User, 8)
3077}
3078
3079static void test_pack_ULARGE_INTEGER(void)
3080{
3081 /* ULARGE_INTEGER */
3082}
3083
3084static void test_pack_ULONGLONG(void)
3085{
3086 /* ULONGLONG */
3090}
3091
3092static void test_pack_WAITORTIMERCALLBACKFUNC(void)
3093{
3094 /* WAITORTIMERCALLBACKFUNC */
3097}
3098
3099static void test_pack_WCHAR(void)
3100{
3101 /* WCHAR */
3105}
3106
3107static void test_pack_ATOM(void)
3108{
3109 /* ATOM */
3110 TEST_TYPE_SIZE (ATOM, 2)
3113}
3114
3115static void test_pack_BOOL(void)
3116{
3117 /* BOOL */
3118 TEST_TYPE_SIZE (BOOL, 4)
3121}
3122
3123static void test_pack_BYTE(void)
3124{
3125 /* BYTE */
3126 TEST_TYPE_SIZE (BYTE, 1)
3129}
3130
3131static void test_pack_COLORREF(void)
3132{
3133 /* COLORREF */
3137}
3138
3139static void test_pack_DWORD(void)
3140{
3141 /* DWORD */
3145}
3146
3147static void test_pack_FARPROC(void)
3148{
3149 /* FARPROC */
3152}
3153
3154static void test_pack_FLOAT(void)
3155{
3156 /* FLOAT */
3159}
3160
3161static void test_pack_GLOBALHANDLE(void)
3162{
3163 /* GLOBALHANDLE */
3166}
3167
3168static void test_pack_HCURSOR(void)
3169{
3170 /* HCURSOR */
3173}
3174
3175static void test_pack_HFILE(void)
3176{
3177 /* HFILE */
3181}
3182
3183static void test_pack_HGDIOBJ(void)
3184{
3185 /* HGDIOBJ */
3188}
3189
3190static void test_pack_HGLOBAL(void)
3191{
3192 /* HGLOBAL */
3195}
3196
3197static void test_pack_HLOCAL(void)
3198{
3199 /* HLOCAL */
3202}
3203
3204static void test_pack_HMODULE(void)
3205{
3206 /* HMODULE */
3209}
3210
3211static void test_pack_INT(void)
3212{
3213 /* INT */
3214 TEST_TYPE_SIZE (INT, 4)
3215 TEST_TYPE_ALIGN (INT, 4)
3217}
3218
3219static void test_pack_LOCALHANDLE(void)
3220{
3221 /* LOCALHANDLE */
3224}
3225
3226static void test_pack_LPARAM(void)
3227{
3228 /* LPARAM */
3231}
3232
3233static void test_pack_LPCRECT(void)
3234{
3235 /* LPCRECT */
3240}
3241
3242static void test_pack_LPCRECTL(void)
3243{
3244 /* LPCRECTL */
3249}
3250
3251static void test_pack_LPCVOID(void)
3252{
3253 /* LPCVOID */
3256}
3257
3258static void test_pack_LPPOINT(void)
3259{
3260 /* LPPOINT */
3265}
3266
3267static void test_pack_LPRECT(void)
3268{
3269 /* LPRECT */
3274}
3275
3276static void test_pack_LPRECTL(void)
3277{
3278 /* LPRECTL */
3283}
3284
3285static void test_pack_LPSIZE(void)
3286{
3287 /* LPSIZE */
3292}
3293
3294static void test_pack_LRESULT(void)
3295{
3296 /* LRESULT */
3299}
3300
3301static void test_pack_POINT(void)
3302{
3303 /* POINT */
3306 TEST_FIELD_SIZE (POINT, x, 4)
3309 TEST_FIELD_SIZE (POINT, y, 4)
3312}
3313
3314static void test_pack_POINTL(void)
3315{
3316 /* POINTL */
3325}
3326
3327static void test_pack_PPOINT(void)
3328{
3329 /* PPOINT */
3334}
3335
3336static void test_pack_PPOINTL(void)
3337{
3338 /* PPOINTL */
3343}
3344
3345static void test_pack_PRECT(void)
3346{
3347 /* PRECT */
3352}
3353
3354static void test_pack_PRECTL(void)
3355{
3356 /* PRECTL */
3361}
3362
3363static void test_pack_PROC(void)
3364{
3365 /* PROC */
3366 TEST_TYPE_SIZE (PROC, 8)
3368}
3369
3370static void test_pack_PSIZE(void)
3371{
3372 /* PSIZE */
3377}
3378
3379static void test_pack_PSZ(void)
3380{
3381 /* PSZ */
3382 TEST_TYPE_SIZE (PSZ, 8)
3383 TEST_TYPE_ALIGN (PSZ, 8)
3384}
3385
3386static void test_pack_RECT(void)
3387{
3388 /* RECT */
3389 TEST_TYPE_SIZE (RECT, 16)
3403}
3404
3405static void test_pack_RECTL(void)
3406{
3407 /* RECTL */
3408 TEST_TYPE_SIZE (RECTL, 16)
3422}
3423
3424static void test_pack_SIZE(void)
3425{
3426 /* SIZE */
3427 TEST_TYPE_SIZE (SIZE, 8)
3429 TEST_FIELD_SIZE (SIZE, cx, 4)
3432 TEST_FIELD_SIZE (SIZE, cy, 4)
3435}
3436
3437static void test_pack_SIZEL(void)
3438{
3439 /* SIZEL */
3442}
3443
3444static void test_pack_UCHAR(void)
3445{
3446 /* UCHAR */
3450}
3451
3452static void test_pack_UINT(void)
3453{
3454 /* UINT */
3455 TEST_TYPE_SIZE (UINT, 4)
3458}
3459
3460static void test_pack_ULONG(void)
3461{
3462 /* ULONG */
3466}
3467
3468static void test_pack_USHORT(void)
3469{
3470 /* USHORT */
3474}
3475
3476static void test_pack_WORD(void)
3477{
3478 /* WORD */
3479 TEST_TYPE_SIZE (WORD, 2)
3482}
3483
3484static void test_pack_WPARAM(void)
3485{
3486 /* WPARAM */
3489}
3490
3491#else /* _WIN64 */
3492
3493static void test_pack_DWORD32(void)
3494{
3495 /* DWORD32 */
3499}
3500
3501static void test_pack_DWORD64(void)
3502{
3503 /* DWORD64 */
3507}
3508
3509static void test_pack_DWORD_PTR(void)
3510{
3511 /* DWORD_PTR */
3514}
3515
3516static void test_pack_HALF_PTR(void)
3517{
3518 /* HALF_PTR */
3522}
3523
3524static void test_pack_INT16(void)
3525{
3526 /* INT16 */
3530}
3531
3532static void test_pack_INT32(void)
3533{
3534 /* INT32 */
3538}
3539
3540static void test_pack_INT64(void)
3541{
3542 /* INT64 */
3546}
3547
3548static void test_pack_INT8(void)
3549{
3550 /* INT8 */
3551 TEST_TYPE_SIZE (INT8, 1)
3554}
3555
3556static void test_pack_INT_PTR(void)
3557{
3558 /* INT_PTR */
3562}
3563
3564static void test_pack_LONG32(void)
3565{
3566 /* LONG32 */
3570}
3571
3572static void test_pack_LONG64(void)
3573{
3574 /* LONG64 */
3578}
3579
3580static void test_pack_LONG_PTR(void)
3581{
3582 /* LONG_PTR */
3586}
3587
3588static void test_pack_SIZE_T(void)
3589{
3590 /* SIZE_T */
3593}
3594
3595static void test_pack_SSIZE_T(void)
3596{
3597 /* SSIZE_T */
3600}
3601
3602static void test_pack_UHALF_PTR(void)
3603{
3604 /* UHALF_PTR */
3608}
3609
3610static void test_pack_UINT16(void)
3611{
3612 /* UINT16 */
3616}
3617
3618static void test_pack_UINT32(void)
3619{
3620 /* UINT32 */
3624}
3625
3626static void test_pack_UINT64(void)
3627{
3628 /* UINT64 */
3632}
3633
3634static void test_pack_UINT8(void)
3635{
3636 /* UINT8 */
3640}
3641
3642static void test_pack_UINT_PTR(void)
3643{
3644 /* UINT_PTR */
3648}
3649
3650static void test_pack_ULONG32(void)
3651{
3652 /* ULONG32 */
3656}
3657
3658static void test_pack_ULONG64(void)
3659{
3660 /* ULONG64 */
3664}
3665
3666static void test_pack_ULONG_PTR(void)
3667{
3668 /* ULONG_PTR */
3672}
3673
3675{
3676 /* ACCESS_ALLOWED_ACE */
3685 TEST_FIELD_SIZE (ACCESS_ALLOWED_ACE, SidStart, 4)
3688}
3689
3691{
3692 /* ACCESS_DENIED_ACE */
3701 TEST_FIELD_SIZE (ACCESS_DENIED_ACE, SidStart, 4)
3702 TEST_FIELD_ALIGN (ACCESS_DENIED_ACE, SidStart, 4)
3704}
3705
3706static void test_pack_ACCESS_MASK(void)
3707{
3708 /* ACCESS_MASK */
3712}
3713
3714static void test_pack_ACE_HEADER(void)
3715{
3716 /* ACE_HEADER */
3725 TEST_FIELD_SIZE (ACE_HEADER, AceSize, 2)
3726 TEST_FIELD_ALIGN (ACE_HEADER, AceSize, 2)
3727 TEST_FIELD_OFFSET(ACE_HEADER, AceSize, 2)
3728}
3729
3730static void test_pack_ACL(void)
3731{
3732 /* ACL */
3733 TEST_TYPE_SIZE (ACL, 8)
3734 TEST_TYPE_ALIGN (ACL, 2)
3738 TEST_FIELD_SIZE (ACL, Sbz1, 1)
3739 TEST_FIELD_ALIGN (ACL, Sbz1, 1)
3740 TEST_FIELD_OFFSET(ACL, Sbz1, 1)
3741 TEST_FIELD_SIZE (ACL, AclSize, 2)
3742 TEST_FIELD_ALIGN (ACL, AclSize, 2)
3743 TEST_FIELD_OFFSET(ACL, AclSize, 2)
3744 TEST_FIELD_SIZE (ACL, AceCount, 2)
3745 TEST_FIELD_ALIGN (ACL, AceCount, 2)
3746 TEST_FIELD_OFFSET(ACL, AceCount, 4)
3747 TEST_FIELD_SIZE (ACL, Sbz2, 2)
3748 TEST_FIELD_ALIGN (ACL, Sbz2, 2)
3749 TEST_FIELD_OFFSET(ACL, Sbz2, 6)
3750}
3751
3753{
3754 /* ACL_REVISION_INFORMATION */
3760}
3761
3763{
3764 /* ACL_SIZE_INFORMATION */
3770 TEST_FIELD_SIZE (ACL_SIZE_INFORMATION, AclBytesInUse, 4)
3771 TEST_FIELD_ALIGN (ACL_SIZE_INFORMATION, AclBytesInUse, 4)
3772 TEST_FIELD_OFFSET(ACL_SIZE_INFORMATION, AclBytesInUse, 4)
3773 TEST_FIELD_SIZE (ACL_SIZE_INFORMATION, AclBytesFree, 4)
3774 TEST_FIELD_ALIGN (ACL_SIZE_INFORMATION, AclBytesFree, 4)
3775 TEST_FIELD_OFFSET(ACL_SIZE_INFORMATION, AclBytesFree, 8)
3776}
3777
3778static void test_pack_BOOLEAN(void)
3779{
3780 /* BOOLEAN */
3784}
3785
3786static void test_pack_CCHAR(void)
3787{
3788 /* CCHAR */
3791}
3792
3793static void test_pack_CHAR(void)
3794{
3795 /* CHAR */
3796 TEST_TYPE_SIZE (CHAR, 1)
3798}
3799
3800static void test_pack_DWORDLONG(void)
3801{
3802 /* DWORDLONG */
3806}
3807
3809{
3810 /* EXCEPTION_POINTERS */
3813 TEST_FIELD_SIZE (EXCEPTION_POINTERS, ExceptionRecord, 4)
3814 TEST_FIELD_ALIGN (EXCEPTION_POINTERS, ExceptionRecord, 4)
3815 TEST_FIELD_OFFSET(EXCEPTION_POINTERS, ExceptionRecord, 0)
3819}
3820
3822{
3823 /* EXCEPTION_RECORD */
3829 TEST_FIELD_SIZE (EXCEPTION_RECORD, ExceptionFlags, 4)
3830 TEST_FIELD_ALIGN (EXCEPTION_RECORD, ExceptionFlags, 4)
3831 TEST_FIELD_OFFSET(EXCEPTION_RECORD, ExceptionFlags, 4)
3832 TEST_FIELD_SIZE (EXCEPTION_RECORD, ExceptionRecord, 4)
3833 TEST_FIELD_ALIGN (EXCEPTION_RECORD, ExceptionRecord, 4)
3834 TEST_FIELD_OFFSET(EXCEPTION_RECORD, ExceptionRecord, 8)
3835 TEST_FIELD_SIZE (EXCEPTION_RECORD, ExceptionAddress, 4)
3836 TEST_FIELD_ALIGN (EXCEPTION_RECORD, ExceptionAddress, 4)
3837 TEST_FIELD_OFFSET(EXCEPTION_RECORD, ExceptionAddress, 12)
3838 TEST_FIELD_SIZE (EXCEPTION_RECORD, NumberParameters, 4)
3839 TEST_FIELD_ALIGN (EXCEPTION_RECORD, NumberParameters, 4)
3840 TEST_FIELD_OFFSET(EXCEPTION_RECORD, NumberParameters, 16)
3841 TEST_FIELD_SIZE (EXCEPTION_RECORD, ExceptionInformation, 60)
3842 TEST_FIELD_ALIGN (EXCEPTION_RECORD, ExceptionInformation, 4)
3843 TEST_FIELD_OFFSET(EXCEPTION_RECORD, ExceptionInformation, 20)
3844}
3845
3847{
3848 /* EXECUTION_STATE */
3852}
3853
3854static void test_pack_FPO_DATA(void)
3855{
3856 /* FPO_DATA */
3859 TEST_FIELD_SIZE (FPO_DATA, ulOffStart, 4)
3860 TEST_FIELD_ALIGN (FPO_DATA, ulOffStart, 4)
3861 TEST_FIELD_OFFSET(FPO_DATA, ulOffStart, 0)
3862 TEST_FIELD_SIZE (FPO_DATA, cbProcSize, 4)
3863 TEST_FIELD_ALIGN (FPO_DATA, cbProcSize, 4)
3864 TEST_FIELD_OFFSET(FPO_DATA, cbProcSize, 4)
3865 TEST_FIELD_SIZE (FPO_DATA, cdwLocals, 4)
3866 TEST_FIELD_ALIGN (FPO_DATA, cdwLocals, 4)
3867 TEST_FIELD_OFFSET(FPO_DATA, cdwLocals, 8)
3868 TEST_FIELD_SIZE (FPO_DATA, cdwParams, 2)
3869 TEST_FIELD_ALIGN (FPO_DATA, cdwParams, 2)
3870 TEST_FIELD_OFFSET(FPO_DATA, cdwParams, 12)
3871}
3872
3874{
3875 /* GENERIC_MAPPING */
3878 TEST_FIELD_SIZE (GENERIC_MAPPING, GenericRead, 4)
3879 TEST_FIELD_ALIGN (GENERIC_MAPPING, GenericRead, 4)
3880 TEST_FIELD_OFFSET(GENERIC_MAPPING, GenericRead, 0)
3881 TEST_FIELD_SIZE (GENERIC_MAPPING, GenericWrite, 4)
3882 TEST_FIELD_ALIGN (GENERIC_MAPPING, GenericWrite, 4)
3883 TEST_FIELD_OFFSET(GENERIC_MAPPING, GenericWrite, 4)
3884 TEST_FIELD_SIZE (GENERIC_MAPPING, GenericExecute, 4)
3885 TEST_FIELD_ALIGN (GENERIC_MAPPING, GenericExecute, 4)
3886 TEST_FIELD_OFFSET(GENERIC_MAPPING, GenericExecute, 8)
3887 TEST_FIELD_SIZE (GENERIC_MAPPING, GenericAll, 4)
3888 TEST_FIELD_ALIGN (GENERIC_MAPPING, GenericAll, 4)
3889 TEST_FIELD_OFFSET(GENERIC_MAPPING, GenericAll, 12)
3890}
3891
3892static void test_pack_HANDLE(void)
3893{
3894 /* HANDLE */
3897}
3898
3899static void test_pack_HRESULT(void)
3900{
3901 /* HRESULT */
3904}
3905
3907{
3908 /* IMAGE_ARCHIVE_MEMBER_HEADER */
3932}
3933
3935{
3936 /* IMAGE_AUX_SYMBOL (pack 2) */
3937}
3938
3940{
3941 /* IMAGE_BASE_RELOCATION */
3947 TEST_FIELD_SIZE (IMAGE_BASE_RELOCATION, SizeOfBlock, 4)
3948 TEST_FIELD_ALIGN (IMAGE_BASE_RELOCATION, SizeOfBlock, 4)
3950}
3951
3953{
3954 /* IMAGE_BOUND_FORWARDER_REF */
3957 TEST_FIELD_SIZE (IMAGE_BOUND_FORWARDER_REF, TimeDateStamp, 4)
3960 TEST_FIELD_SIZE (IMAGE_BOUND_FORWARDER_REF, OffsetModuleName, 2)
3961 TEST_FIELD_ALIGN (IMAGE_BOUND_FORWARDER_REF, OffsetModuleName, 2)
3962 TEST_FIELD_OFFSET(IMAGE_BOUND_FORWARDER_REF, OffsetModuleName, 4)
3966}
3967
3969{
3970 /* IMAGE_BOUND_IMPORT_DESCRIPTOR */
3976 TEST_FIELD_SIZE (IMAGE_BOUND_IMPORT_DESCRIPTOR, OffsetModuleName, 2)
3977 TEST_FIELD_ALIGN (IMAGE_BOUND_IMPORT_DESCRIPTOR, OffsetModuleName, 2)
3979 TEST_FIELD_SIZE (IMAGE_BOUND_IMPORT_DESCRIPTOR, NumberOfModuleForwarderRefs, 2)
3980 TEST_FIELD_ALIGN (IMAGE_BOUND_IMPORT_DESCRIPTOR, NumberOfModuleForwarderRefs, 2)
3981 TEST_FIELD_OFFSET(IMAGE_BOUND_IMPORT_DESCRIPTOR, NumberOfModuleForwarderRefs, 6)
3982}
3983
3985{
3986 /* IMAGE_COFF_SYMBOLS_HEADER */
3989 TEST_FIELD_SIZE (IMAGE_COFF_SYMBOLS_HEADER, NumberOfSymbols, 4)
3990 TEST_FIELD_ALIGN (IMAGE_COFF_SYMBOLS_HEADER, NumberOfSymbols, 4)
3991 TEST_FIELD_OFFSET(IMAGE_COFF_SYMBOLS_HEADER, NumberOfSymbols, 0)
3992 TEST_FIELD_SIZE (IMAGE_COFF_SYMBOLS_HEADER, LvaToFirstSymbol, 4)
3993 TEST_FIELD_ALIGN (IMAGE_COFF_SYMBOLS_HEADER, LvaToFirstSymbol, 4)
3994 TEST_FIELD_OFFSET(IMAGE_COFF_SYMBOLS_HEADER, LvaToFirstSymbol, 4)
3995 TEST_FIELD_SIZE (IMAGE_COFF_SYMBOLS_HEADER, NumberOfLinenumbers, 4)
3996 TEST_FIELD_ALIGN (IMAGE_COFF_SYMBOLS_HEADER, NumberOfLinenumbers, 4)
3997 TEST_FIELD_OFFSET(IMAGE_COFF_SYMBOLS_HEADER, NumberOfLinenumbers, 8)
3998 TEST_FIELD_SIZE (IMAGE_COFF_SYMBOLS_HEADER, LvaToFirstLinenumber, 4)
3999 TEST_FIELD_ALIGN (IMAGE_COFF_SYMBOLS_HEADER, LvaToFirstLinenumber, 4)
4000 TEST_FIELD_OFFSET(IMAGE_COFF_SYMBOLS_HEADER, LvaToFirstLinenumber, 12)
4001 TEST_FIELD_SIZE (IMAGE_COFF_SYMBOLS_HEADER, RvaToFirstByteOfCode, 4)
4002 TEST_FIELD_ALIGN (IMAGE_COFF_SYMBOLS_HEADER, RvaToFirstByteOfCode, 4)
4003 TEST_FIELD_OFFSET(IMAGE_COFF_SYMBOLS_HEADER, RvaToFirstByteOfCode, 16)
4004 TEST_FIELD_SIZE (IMAGE_COFF_SYMBOLS_HEADER, RvaToLastByteOfCode, 4)
4005 TEST_FIELD_ALIGN (IMAGE_COFF_SYMBOLS_HEADER, RvaToLastByteOfCode, 4)
4006 TEST_FIELD_OFFSET(IMAGE_COFF_SYMBOLS_HEADER, RvaToLastByteOfCode, 20)
4007 TEST_FIELD_SIZE (IMAGE_COFF_SYMBOLS_HEADER, RvaToFirstByteOfData, 4)
4008 TEST_FIELD_ALIGN (IMAGE_COFF_SYMBOLS_HEADER, RvaToFirstByteOfData, 4)
4009 TEST_FIELD_OFFSET(IMAGE_COFF_SYMBOLS_HEADER, RvaToFirstByteOfData, 24)
4010 TEST_FIELD_SIZE (IMAGE_COFF_SYMBOLS_HEADER, RvaToLastByteOfData, 4)
4011 TEST_FIELD_ALIGN (IMAGE_COFF_SYMBOLS_HEADER, RvaToLastByteOfData, 4)
4012 TEST_FIELD_OFFSET(IMAGE_COFF_SYMBOLS_HEADER, RvaToLastByteOfData, 28)
4013}
4014
4016{
4017 /* IMAGE_DATA_DIRECTORY */
4026}
4027
4029{
4030 /* IMAGE_DEBUG_DIRECTORY */
4033 TEST_FIELD_SIZE (IMAGE_DEBUG_DIRECTORY, Characteristics, 4)
4034 TEST_FIELD_ALIGN (IMAGE_DEBUG_DIRECTORY, Characteristics, 4)
4035 TEST_FIELD_OFFSET(IMAGE_DEBUG_DIRECTORY, Characteristics, 0)
4036 TEST_FIELD_SIZE (IMAGE_DEBUG_DIRECTORY, TimeDateStamp, 4)
4037 TEST_FIELD_ALIGN (IMAGE_DEBUG_DIRECTORY, TimeDateStamp, 4)
4038 TEST_FIELD_OFFSET(IMAGE_DEBUG_DIRECTORY, TimeDateStamp, 4)
4048 TEST_FIELD_SIZE (IMAGE_DEBUG_DIRECTORY, SizeOfData, 4)
4051 TEST_FIELD_SIZE (IMAGE_DEBUG_DIRECTORY, AddressOfRawData, 4)
4052 TEST_FIELD_ALIGN (IMAGE_DEBUG_DIRECTORY, AddressOfRawData, 4)
4053 TEST_FIELD_OFFSET(IMAGE_DEBUG_DIRECTORY, AddressOfRawData, 20)
4054 TEST_FIELD_SIZE (IMAGE_DEBUG_DIRECTORY, PointerToRawData, 4)
4055 TEST_FIELD_ALIGN (IMAGE_DEBUG_DIRECTORY, PointerToRawData, 4)
4056 TEST_FIELD_OFFSET(IMAGE_DEBUG_DIRECTORY, PointerToRawData, 24)
4057}
4058
4060{
4061 /* IMAGE_DEBUG_MISC */
4070 TEST_FIELD_SIZE (IMAGE_DEBUG_MISC, Unicode, 1)
4079}
4080
4082{
4083 /* IMAGE_DOS_HEADER (pack 2) */
4098 TEST_FIELD_SIZE (IMAGE_DOS_HEADER, e_cparhdr, 2)
4099 TEST_FIELD_ALIGN (IMAGE_DOS_HEADER, e_cparhdr, 2)
4100 TEST_FIELD_OFFSET(IMAGE_DOS_HEADER, e_cparhdr, 8)
4101 TEST_FIELD_SIZE (IMAGE_DOS_HEADER, e_minalloc, 2)
4102 TEST_FIELD_ALIGN (IMAGE_DOS_HEADER, e_minalloc, 2)
4103 TEST_FIELD_OFFSET(IMAGE_DOS_HEADER, e_minalloc, 10)
4104 TEST_FIELD_SIZE (IMAGE_DOS_HEADER, e_maxalloc, 2)
4105 TEST_FIELD_ALIGN (IMAGE_DOS_HEADER, e_maxalloc, 2)
4106 TEST_FIELD_OFFSET(IMAGE_DOS_HEADER, e_maxalloc, 12)
4122 TEST_FIELD_SIZE (IMAGE_DOS_HEADER, e_lfarlc, 2)
4123 TEST_FIELD_ALIGN (IMAGE_DOS_HEADER, e_lfarlc, 2)
4124 TEST_FIELD_OFFSET(IMAGE_DOS_HEADER, e_lfarlc, 24)
4131 TEST_FIELD_SIZE (IMAGE_DOS_HEADER, e_oemid, 2)
4134 TEST_FIELD_SIZE (IMAGE_DOS_HEADER, e_oeminfo, 2)
4135 TEST_FIELD_ALIGN (IMAGE_DOS_HEADER, e_oeminfo, 2)
4136 TEST_FIELD_OFFSET(IMAGE_DOS_HEADER, e_oeminfo, 38)
4137 TEST_FIELD_SIZE (IMAGE_DOS_HEADER, e_res2, 20)
4143}
4144
4146{
4147 /* IMAGE_EXPORT_DIRECTORY */
4150 TEST_FIELD_SIZE (IMAGE_EXPORT_DIRECTORY, Characteristics, 4)
4151 TEST_FIELD_ALIGN (IMAGE_EXPORT_DIRECTORY, Characteristics, 4)
4152 TEST_FIELD_OFFSET(IMAGE_EXPORT_DIRECTORY, Characteristics, 0)
4153 TEST_FIELD_SIZE (IMAGE_EXPORT_DIRECTORY, TimeDateStamp, 4)
4154 TEST_FIELD_ALIGN (IMAGE_EXPORT_DIRECTORY, TimeDateStamp, 4)
4155 TEST_FIELD_OFFSET(IMAGE_EXPORT_DIRECTORY, TimeDateStamp, 4)
4168 TEST_FIELD_SIZE (IMAGE_EXPORT_DIRECTORY, NumberOfFunctions, 4)
4169 TEST_FIELD_ALIGN (IMAGE_EXPORT_DIRECTORY, NumberOfFunctions, 4)
4170 TEST_FIELD_OFFSET(IMAGE_EXPORT_DIRECTORY, NumberOfFunctions, 20)
4171 TEST_FIELD_SIZE (IMAGE_EXPORT_DIRECTORY, NumberOfNames, 4)
4172 TEST_FIELD_ALIGN (IMAGE_EXPORT_DIRECTORY, NumberOfNames, 4)
4173 TEST_FIELD_OFFSET(IMAGE_EXPORT_DIRECTORY, NumberOfNames, 24)
4174 TEST_FIELD_SIZE (IMAGE_EXPORT_DIRECTORY, AddressOfFunctions, 4)
4175 TEST_FIELD_ALIGN (IMAGE_EXPORT_DIRECTORY, AddressOfFunctions, 4)
4176 TEST_FIELD_OFFSET(IMAGE_EXPORT_DIRECTORY, AddressOfFunctions, 28)
4177 TEST_FIELD_SIZE (IMAGE_EXPORT_DIRECTORY, AddressOfNames, 4)
4178 TEST_FIELD_ALIGN (IMAGE_EXPORT_DIRECTORY, AddressOfNames, 4)
4179 TEST_FIELD_OFFSET(IMAGE_EXPORT_DIRECTORY, AddressOfNames, 32)
4180 TEST_FIELD_SIZE (IMAGE_EXPORT_DIRECTORY, AddressOfNameOrdinals, 4)
4181 TEST_FIELD_ALIGN (IMAGE_EXPORT_DIRECTORY, AddressOfNameOrdinals, 4)
4182 TEST_FIELD_OFFSET(IMAGE_EXPORT_DIRECTORY, AddressOfNameOrdinals, 36)
4183}
4184
4186{
4187 /* IMAGE_FILE_HEADER */
4193 TEST_FIELD_SIZE (IMAGE_FILE_HEADER, NumberOfSections, 2)
4194 TEST_FIELD_ALIGN (IMAGE_FILE_HEADER, NumberOfSections, 2)
4195 TEST_FIELD_OFFSET(IMAGE_FILE_HEADER, NumberOfSections, 2)
4196 TEST_FIELD_SIZE (IMAGE_FILE_HEADER, TimeDateStamp, 4)
4197 TEST_FIELD_ALIGN (IMAGE_FILE_HEADER, TimeDateStamp, 4)
4198 TEST_FIELD_OFFSET(IMAGE_FILE_HEADER, TimeDateStamp, 4)
4199 TEST_FIELD_SIZE (IMAGE_FILE_HEADER, PointerToSymbolTable, 4)
4200 TEST_FIELD_ALIGN (IMAGE_FILE_HEADER, PointerToSymbolTable, 4)
4201 TEST_FIELD_OFFSET(IMAGE_FILE_HEADER, PointerToSymbolTable, 8)
4202 TEST_FIELD_SIZE (IMAGE_FILE_HEADER, NumberOfSymbols, 4)
4203 TEST_FIELD_ALIGN (IMAGE_FILE_HEADER, NumberOfSymbols, 4)
4204 TEST_FIELD_OFFSET(IMAGE_FILE_HEADER, NumberOfSymbols, 12)
4205 TEST_FIELD_SIZE (IMAGE_FILE_HEADER, SizeOfOptionalHeader, 2)
4206 TEST_FIELD_ALIGN (IMAGE_FILE_HEADER, SizeOfOptionalHeader, 2)
4207 TEST_FIELD_OFFSET(IMAGE_FILE_HEADER, SizeOfOptionalHeader, 16)
4208 TEST_FIELD_SIZE (IMAGE_FILE_HEADER, Characteristics, 2)
4209 TEST_FIELD_ALIGN (IMAGE_FILE_HEADER, Characteristics, 2)
4210 TEST_FIELD_OFFSET(IMAGE_FILE_HEADER, Characteristics, 18)
4211}
4212
4214{
4215 /* IMAGE_FUNCTION_ENTRY */
4218 TEST_FIELD_SIZE (IMAGE_FUNCTION_ENTRY, StartingAddress, 4)
4219 TEST_FIELD_ALIGN (IMAGE_FUNCTION_ENTRY, StartingAddress, 4)
4220 TEST_FIELD_OFFSET(IMAGE_FUNCTION_ENTRY, StartingAddress, 0)
4221 TEST_FIELD_SIZE (IMAGE_FUNCTION_ENTRY, EndingAddress, 4)
4222 TEST_FIELD_ALIGN (IMAGE_FUNCTION_ENTRY, EndingAddress, 4)
4223 TEST_FIELD_OFFSET(IMAGE_FUNCTION_ENTRY, EndingAddress, 4)
4224 TEST_FIELD_SIZE (IMAGE_FUNCTION_ENTRY, EndOfPrologue, 4)
4225 TEST_FIELD_ALIGN (IMAGE_FUNCTION_ENTRY, EndOfPrologue, 4)
4226 TEST_FIELD_OFFSET(IMAGE_FUNCTION_ENTRY, EndOfPrologue, 8)
4227}
4228
4230{
4231 /* IMAGE_IMPORT_BY_NAME */
4240}
4241
4243{
4244 /* IMAGE_IMPORT_DESCRIPTOR */
4245}
4246
4248{
4249 /* IMAGE_LINENUMBER (pack 2) */
4250}
4251
4253{
4254 /* IMAGE_LOAD_CONFIG_DIRECTORY */
4257}
4258
4260{
4261 /* IMAGE_LOAD_CONFIG_DIRECTORY32 */
4276 TEST_FIELD_SIZE (IMAGE_LOAD_CONFIG_DIRECTORY32, GlobalFlagsClear, 4)
4277 TEST_FIELD_ALIGN (IMAGE_LOAD_CONFIG_DIRECTORY32, GlobalFlagsClear, 4)
4282 TEST_FIELD_SIZE (IMAGE_LOAD_CONFIG_DIRECTORY32, CriticalSectionDefaultTimeout, 4)
4283 TEST_FIELD_ALIGN (IMAGE_LOAD_CONFIG_DIRECTORY32, CriticalSectionDefaultTimeout, 4)
4284 TEST_FIELD_OFFSET(IMAGE_LOAD_CONFIG_DIRECTORY32, CriticalSectionDefaultTimeout, 20)
4285 TEST_FIELD_SIZE (IMAGE_LOAD_CONFIG_DIRECTORY32, DeCommitFreeBlockThreshold, 4)
4286 TEST_FIELD_ALIGN (IMAGE_LOAD_CONFIG_DIRECTORY32, DeCommitFreeBlockThreshold, 4)
4287 TEST_FIELD_OFFSET(IMAGE_LOAD_CONFIG_DIRECTORY32, DeCommitFreeBlockThreshold, 24)
4288 TEST_FIELD_SIZE (IMAGE_LOAD_CONFIG_DIRECTORY32, DeCommitTotalFreeThreshold, 4)
4289 TEST_FIELD_ALIGN (IMAGE_LOAD_CONFIG_DIRECTORY32, DeCommitTotalFreeThreshold, 4)
4290 TEST_FIELD_OFFSET(IMAGE_LOAD_CONFIG_DIRECTORY32, DeCommitTotalFreeThreshold, 28)
4294 TEST_FIELD_SIZE (IMAGE_LOAD_CONFIG_DIRECTORY32, MaximumAllocationSize, 4)
4295 TEST_FIELD_ALIGN (IMAGE_LOAD_CONFIG_DIRECTORY32, MaximumAllocationSize, 4)
4296 TEST_FIELD_OFFSET(IMAGE_LOAD_CONFIG_DIRECTORY32, MaximumAllocationSize, 36)
4297 TEST_FIELD_SIZE (IMAGE_LOAD_CONFIG_DIRECTORY32, VirtualMemoryThreshold, 4)
4298 TEST_FIELD_ALIGN (IMAGE_LOAD_CONFIG_DIRECTORY32, VirtualMemoryThreshold, 4)
4299 TEST_FIELD_OFFSET(IMAGE_LOAD_CONFIG_DIRECTORY32, VirtualMemoryThreshold, 40)
4300 TEST_FIELD_SIZE (IMAGE_LOAD_CONFIG_DIRECTORY32, ProcessHeapFlags, 4)
4301 TEST_FIELD_ALIGN (IMAGE_LOAD_CONFIG_DIRECTORY32, ProcessHeapFlags, 4)
4324}
4325
4327{
4328 /* IMAGE_LOAD_CONFIG_DIRECTORY64 */
4343 TEST_FIELD_SIZE (IMAGE_LOAD_CONFIG_DIRECTORY64, GlobalFlagsClear, 4)
4344 TEST_FIELD_ALIGN (IMAGE_LOAD_CONFIG_DIRECTORY64, GlobalFlagsClear, 4)
4349 TEST_FIELD_SIZE (IMAGE_LOAD_CONFIG_DIRECTORY64, CriticalSectionDefaultTimeout, 4)
4350 TEST_FIELD_ALIGN (IMAGE_LOAD_CONFIG_DIRECTORY64, CriticalSectionDefaultTimeout, 4)
4351 TEST_FIELD_OFFSET(IMAGE_LOAD_CONFIG_DIRECTORY64, CriticalSectionDefaultTimeout, 20)
4352 TEST_FIELD_SIZE (IMAGE_LOAD_CONFIG_DIRECTORY64, DeCommitFreeBlockThreshold, 8)
4353 TEST_FIELD_ALIGN (IMAGE_LOAD_CONFIG_DIRECTORY64, DeCommitFreeBlockThreshold, 8)
4354 TEST_FIELD_OFFSET(IMAGE_LOAD_CONFIG_DIRECTORY64, DeCommitFreeBlockThreshold, 24)
4355 TEST_FIELD_SIZE (IMAGE_LOAD_CONFIG_DIRECTORY64, DeCommitTotalFreeThreshold, 8)
4356 TEST_FIELD_ALIGN (IMAGE_LOAD_CONFIG_DIRECTORY64, DeCommitTotalFreeThreshold, 8)
4357 TEST_FIELD_OFFSET(IMAGE_LOAD_CONFIG_DIRECTORY64, DeCommitTotalFreeThreshold, 32)
4361 TEST_FIELD_SIZE (IMAGE_LOAD_CONFIG_DIRECTORY64, MaximumAllocationSize, 8)
4362 TEST_FIELD_ALIGN (IMAGE_LOAD_CONFIG_DIRECTORY64, MaximumAllocationSize, 8)
4363 TEST_FIELD_OFFSET(IMAGE_LOAD_CONFIG_DIRECTORY64, MaximumAllocationSize, 48)
4364 TEST_FIELD_SIZE (IMAGE_LOAD_CONFIG_DIRECTORY64, VirtualMemoryThreshold, 8)
4365 TEST_FIELD_ALIGN (IMAGE_LOAD_CONFIG_DIRECTORY64, VirtualMemoryThreshold, 8)
4366 TEST_FIELD_OFFSET(IMAGE_LOAD_CONFIG_DIRECTORY64, VirtualMemoryThreshold, 56)
4370 TEST_FIELD_SIZE (IMAGE_LOAD_CONFIG_DIRECTORY64, ProcessHeapFlags, 4)
4371 TEST_FIELD_ALIGN (IMAGE_LOAD_CONFIG_DIRECTORY64, ProcessHeapFlags, 4)
4391}
4392
4394{
4395 /* IMAGE_NT_HEADERS */
4398}
4399
4401{
4402 /* IMAGE_NT_HEADERS32 */
4408 TEST_FIELD_SIZE (IMAGE_NT_HEADERS32, FileHeader, 20)
4409 TEST_FIELD_ALIGN (IMAGE_NT_HEADERS32, FileHeader, 4)
4411 TEST_FIELD_SIZE (IMAGE_NT_HEADERS32, OptionalHeader, 224)
4412 TEST_FIELD_ALIGN (IMAGE_NT_HEADERS32, OptionalHeader, 4)
4413 TEST_FIELD_OFFSET(IMAGE_NT_HEADERS32, OptionalHeader, 24)
4414}
4415
4417{
4418 /* IMAGE_NT_HEADERS64 */
4424 TEST_FIELD_SIZE (IMAGE_NT_HEADERS64, FileHeader, 20)
4425 TEST_FIELD_ALIGN (IMAGE_NT_HEADERS64, FileHeader, 4)
4427 TEST_FIELD_SIZE (IMAGE_NT_HEADERS64, OptionalHeader, 240)
4428 TEST_FIELD_ALIGN (IMAGE_NT_HEADERS64, OptionalHeader, 8)
4429 TEST_FIELD_OFFSET(IMAGE_NT_HEADERS64, OptionalHeader, 24)
4430}
4431
4433{
4434 /* IMAGE_OPTIONAL_HEADER */
4437}
4438
4440{
4441 /* IMAGE_OPTIONAL_HEADER32 */
4447 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, MajorLinkerVersion, 1)
4448 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, MajorLinkerVersion, 1)
4449 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, MajorLinkerVersion, 2)
4450 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, MinorLinkerVersion, 1)
4451 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, MinorLinkerVersion, 1)
4452 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, MinorLinkerVersion, 3)
4456 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, SizeOfInitializedData, 4)
4457 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, SizeOfInitializedData, 4)
4458 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, SizeOfInitializedData, 8)
4459 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, SizeOfUninitializedData, 4)
4460 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, SizeOfUninitializedData, 4)
4461 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, SizeOfUninitializedData, 12)
4462 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, AddressOfEntryPoint, 4)
4463 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, AddressOfEntryPoint, 4)
4464 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, AddressOfEntryPoint, 16)
4474 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, SectionAlignment, 4)
4475 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, SectionAlignment, 4)
4476 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, SectionAlignment, 32)
4477 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, FileAlignment, 4)
4478 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, FileAlignment, 4)
4479 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, FileAlignment, 36)
4480 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, MajorOperatingSystemVersion, 2)
4481 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, MajorOperatingSystemVersion, 2)
4482 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, MajorOperatingSystemVersion, 40)
4483 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, MinorOperatingSystemVersion, 2)
4484 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, MinorOperatingSystemVersion, 2)
4485 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, MinorOperatingSystemVersion, 42)
4486 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, MajorImageVersion, 2)
4487 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, MajorImageVersion, 2)
4488 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, MajorImageVersion, 44)
4489 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, MinorImageVersion, 2)
4490 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, MinorImageVersion, 2)
4491 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, MinorImageVersion, 46)
4492 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, MajorSubsystemVersion, 2)
4493 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, MajorSubsystemVersion, 2)
4494 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, MajorSubsystemVersion, 48)
4495 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, MinorSubsystemVersion, 2)
4496 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, MinorSubsystemVersion, 2)
4497 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, MinorSubsystemVersion, 50)
4498 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, Win32VersionValue, 4)
4499 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, Win32VersionValue, 4)
4500 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, Win32VersionValue, 52)
4504 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, SizeOfHeaders, 4)
4505 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, SizeOfHeaders, 4)
4506 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, SizeOfHeaders, 60)
4513 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, DllCharacteristics, 2)
4514 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, DllCharacteristics, 2)
4515 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, DllCharacteristics, 70)
4516 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, SizeOfStackReserve, 4)
4517 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, SizeOfStackReserve, 4)
4518 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, SizeOfStackReserve, 72)
4519 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, SizeOfStackCommit, 4)
4520 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, SizeOfStackCommit, 4)
4521 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, SizeOfStackCommit, 76)
4522 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, SizeOfHeapReserve, 4)
4523 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, SizeOfHeapReserve, 4)
4524 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, SizeOfHeapReserve, 80)
4525 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, SizeOfHeapCommit, 4)
4526 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, SizeOfHeapCommit, 4)
4527 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, SizeOfHeapCommit, 84)
4531 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, NumberOfRvaAndSizes, 4)
4532 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, NumberOfRvaAndSizes, 4)
4533 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, NumberOfRvaAndSizes, 92)
4534 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER32, DataDirectory, 128)
4535 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER32, DataDirectory, 4)
4536 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER32, DataDirectory, 96)
4537}
4538
4540{
4541 /* IMAGE_OPTIONAL_HEADER64 */
4547 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, MajorLinkerVersion, 1)
4548 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, MajorLinkerVersion, 1)
4549 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, MajorLinkerVersion, 2)
4550 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, MinorLinkerVersion, 1)
4551 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, MinorLinkerVersion, 1)
4552 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, MinorLinkerVersion, 3)
4556 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, SizeOfInitializedData, 4)
4557 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, SizeOfInitializedData, 4)
4558 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, SizeOfInitializedData, 8)
4559 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, SizeOfUninitializedData, 4)
4560 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, SizeOfUninitializedData, 4)
4561 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, SizeOfUninitializedData, 12)
4562 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, AddressOfEntryPoint, 4)
4563 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, AddressOfEntryPoint, 4)
4564 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, AddressOfEntryPoint, 16)
4571 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, SectionAlignment, 4)
4572 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, SectionAlignment, 4)
4573 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, SectionAlignment, 32)
4574 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, FileAlignment, 4)
4575 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, FileAlignment, 4)
4576 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, FileAlignment, 36)
4577 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, MajorOperatingSystemVersion, 2)
4578 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, MajorOperatingSystemVersion, 2)
4579 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, MajorOperatingSystemVersion, 40)
4580 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, MinorOperatingSystemVersion, 2)
4581 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, MinorOperatingSystemVersion, 2)
4582 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, MinorOperatingSystemVersion, 42)
4583 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, MajorImageVersion, 2)
4584 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, MajorImageVersion, 2)
4585 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, MajorImageVersion, 44)
4586 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, MinorImageVersion, 2)
4587 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, MinorImageVersion, 2)
4588 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, MinorImageVersion, 46)
4589 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, MajorSubsystemVersion, 2)
4590 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, MajorSubsystemVersion, 2)
4591 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, MajorSubsystemVersion, 48)
4592 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, MinorSubsystemVersion, 2)
4593 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, MinorSubsystemVersion, 2)
4594 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, MinorSubsystemVersion, 50)
4595 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, Win32VersionValue, 4)
4596 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, Win32VersionValue, 4)
4597 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, Win32VersionValue, 52)
4601 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, SizeOfHeaders, 4)
4602 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, SizeOfHeaders, 4)
4603 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, SizeOfHeaders, 60)
4610 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, DllCharacteristics, 2)
4611 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, DllCharacteristics, 2)
4612 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, DllCharacteristics, 70)
4613 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, SizeOfStackReserve, 8)
4614 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, SizeOfStackReserve, 8)
4615 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, SizeOfStackReserve, 72)
4616 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, SizeOfStackCommit, 8)
4617 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, SizeOfStackCommit, 8)
4618 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, SizeOfStackCommit, 80)
4619 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, SizeOfHeapReserve, 8)
4620 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, SizeOfHeapReserve, 8)
4621 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, SizeOfHeapReserve, 88)
4622 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, SizeOfHeapCommit, 8)
4623 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, SizeOfHeapCommit, 8)
4624 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, SizeOfHeapCommit, 96)
4628 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, NumberOfRvaAndSizes, 4)
4629 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, NumberOfRvaAndSizes, 4)
4630 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, NumberOfRvaAndSizes, 108)
4631 TEST_FIELD_SIZE (IMAGE_OPTIONAL_HEADER64, DataDirectory, 128)
4632 TEST_FIELD_ALIGN (IMAGE_OPTIONAL_HEADER64, DataDirectory, 4)
4633 TEST_FIELD_OFFSET(IMAGE_OPTIONAL_HEADER64, DataDirectory, 112)
4634}
4635
4637{
4638 /* IMAGE_OS2_HEADER (pack 2) */
4641 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_magic, 2)
4642 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_magic, 2)
4650 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_enttab, 2)
4651 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_enttab, 2)
4652 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_enttab, 4)
4653 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_cbenttab, 2)
4654 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_cbenttab, 2)
4655 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_cbenttab, 6)
4659 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_flags, 2)
4660 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_flags, 2)
4661 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_flags, 12)
4662 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_autodata, 2)
4663 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_autodata, 2)
4664 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_autodata, 14)
4665 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_heap, 2)
4668 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_stack, 2)
4669 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_stack, 2)
4670 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_stack, 18)
4671 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_csip, 4)
4674 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_sssp, 4)
4677 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_cseg, 2)
4680 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_cmod, 2)
4683 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_cbnrestab, 2)
4684 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_cbnrestab, 2)
4685 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_cbnrestab, 32)
4686 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_segtab, 2)
4687 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_segtab, 2)
4688 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_segtab, 34)
4689 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_rsrctab, 2)
4690 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_rsrctab, 2)
4691 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_rsrctab, 36)
4692 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_restab, 2)
4693 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_restab, 2)
4694 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_restab, 38)
4695 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_modtab, 2)
4696 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_modtab, 2)
4697 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_modtab, 40)
4698 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_imptab, 2)
4699 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_imptab, 2)
4700 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_imptab, 42)
4701 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_nrestab, 4)
4702 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_nrestab, 2)
4703 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_nrestab, 44)
4704 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_cmovent, 2)
4705 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_cmovent, 2)
4706 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_cmovent, 48)
4707 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_align, 2)
4708 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_align, 2)
4709 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_align, 50)
4710 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_cres, 2)
4713 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_exetyp, 1)
4714 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_exetyp, 1)
4715 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_exetyp, 54)
4716 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_flagsothers, 1)
4717 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_flagsothers, 1)
4718 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_flagsothers, 55)
4719 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_pretthunks, 2)
4720 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_pretthunks, 2)
4721 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_pretthunks, 56)
4722 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_psegrefbytes, 2)
4723 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_psegrefbytes, 2)
4724 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_psegrefbytes, 58)
4725 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_swaparea, 2)
4726 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_swaparea, 2)
4727 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_swaparea, 60)
4728 TEST_FIELD_SIZE (IMAGE_OS2_HEADER, ne_expver, 2)
4729 TEST_FIELD_ALIGN (IMAGE_OS2_HEADER, ne_expver, 2)
4730 TEST_FIELD_OFFSET(IMAGE_OS2_HEADER, ne_expver, 62)
4731}
4732
4734{
4735 /* IMAGE_RELOCATION (pack 2) */
4736}
4737
4739{
4740 /* IMAGE_RESOURCE_DATA_ENTRY */
4755}
4756
4758{
4759 /* IMAGE_RESOURCE_DIRECTORY */
4762 TEST_FIELD_SIZE (IMAGE_RESOURCE_DIRECTORY, Characteristics, 4)
4763 TEST_FIELD_ALIGN (IMAGE_RESOURCE_DIRECTORY, Characteristics, 4)
4764 TEST_FIELD_OFFSET(IMAGE_RESOURCE_DIRECTORY, Characteristics, 0)
4765 TEST_FIELD_SIZE (IMAGE_RESOURCE_DIRECTORY, TimeDateStamp, 4)
4766 TEST_FIELD_ALIGN (IMAGE_RESOURCE_DIRECTORY, TimeDateStamp, 4)
4774 TEST_FIELD_SIZE (IMAGE_RESOURCE_DIRECTORY, NumberOfNamedEntries, 2)
4775 TEST_FIELD_ALIGN (IMAGE_RESOURCE_DIRECTORY, NumberOfNamedEntries, 2)
4776 TEST_FIELD_OFFSET(IMAGE_RESOURCE_DIRECTORY, NumberOfNamedEntries, 12)
4777 TEST_FIELD_SIZE (IMAGE_RESOURCE_DIRECTORY, NumberOfIdEntries, 2)
4778 TEST_FIELD_ALIGN (IMAGE_RESOURCE_DIRECTORY, NumberOfIdEntries, 2)
4779 TEST_FIELD_OFFSET(IMAGE_RESOURCE_DIRECTORY, NumberOfIdEntries, 14)
4780}
4781
4783{
4784 /* IMAGE_RESOURCE_DIRECTORY_ENTRY */
4785}
4786
4788{
4789 /* IMAGE_RESOURCE_DIRECTORY_STRING */
4798}
4799
4801{
4802 /* IMAGE_RESOURCE_DIR_STRING_U */
4811}
4812
4814{
4815 /* IMAGE_SECTION_HEADER */
4819}
4820
4822{
4823 /* IMAGE_SEPARATE_DEBUG_HEADER */
4835 TEST_FIELD_SIZE (IMAGE_SEPARATE_DEBUG_HEADER, Characteristics, 2)
4836 TEST_FIELD_ALIGN (IMAGE_SEPARATE_DEBUG_HEADER, Characteristics, 2)
4850 TEST_FIELD_SIZE (IMAGE_SEPARATE_DEBUG_HEADER, NumberOfSections, 4)
4851 TEST_FIELD_ALIGN (IMAGE_SEPARATE_DEBUG_HEADER, NumberOfSections, 4)
4852 TEST_FIELD_OFFSET(IMAGE_SEPARATE_DEBUG_HEADER, NumberOfSections, 24)
4853 TEST_FIELD_SIZE (IMAGE_SEPARATE_DEBUG_HEADER, ExportedNamesSize, 4)
4854 TEST_FIELD_ALIGN (IMAGE_SEPARATE_DEBUG_HEADER, ExportedNamesSize, 4)
4855 TEST_FIELD_OFFSET(IMAGE_SEPARATE_DEBUG_HEADER, ExportedNamesSize, 28)
4856 TEST_FIELD_SIZE (IMAGE_SEPARATE_DEBUG_HEADER, DebugDirectorySize, 4)
4857 TEST_FIELD_ALIGN (IMAGE_SEPARATE_DEBUG_HEADER, DebugDirectorySize, 4)
4858 TEST_FIELD_OFFSET(IMAGE_SEPARATE_DEBUG_HEADER, DebugDirectorySize, 32)
4859 TEST_FIELD_SIZE (IMAGE_SEPARATE_DEBUG_HEADER, SectionAlignment, 4)
4860 TEST_FIELD_ALIGN (IMAGE_SEPARATE_DEBUG_HEADER, SectionAlignment, 4)
4861 TEST_FIELD_OFFSET(IMAGE_SEPARATE_DEBUG_HEADER, SectionAlignment, 36)
4865}
4866
4867static void test_pack_IMAGE_SYMBOL(void)
4868{
4869 /* IMAGE_SYMBOL (pack 2) */
4870}
4871
4873{
4874 /* IMAGE_THUNK_DATA */
4875}
4876
4878{
4879 /* IMAGE_TLS_DIRECTORY */
4882}
4883
4885{
4886 /* IMAGE_TLS_DIRECTORY32 */
4889 TEST_FIELD_SIZE (IMAGE_TLS_DIRECTORY32, StartAddressOfRawData, 4)
4890 TEST_FIELD_ALIGN (IMAGE_TLS_DIRECTORY32, StartAddressOfRawData, 4)
4891 TEST_FIELD_OFFSET(IMAGE_TLS_DIRECTORY32, StartAddressOfRawData, 0)
4892 TEST_FIELD_SIZE (IMAGE_TLS_DIRECTORY32, EndAddressOfRawData, 4)
4893 TEST_FIELD_ALIGN (IMAGE_TLS_DIRECTORY32, EndAddressOfRawData, 4)
4894 TEST_FIELD_OFFSET(IMAGE_TLS_DIRECTORY32, EndAddressOfRawData, 4)
4895 TEST_FIELD_SIZE (IMAGE_TLS_DIRECTORY32, AddressOfIndex, 4)
4896 TEST_FIELD_ALIGN (IMAGE_TLS_DIRECTORY32, AddressOfIndex, 4)
4897 TEST_FIELD_OFFSET(IMAGE_TLS_DIRECTORY32, AddressOfIndex, 8)
4898 TEST_FIELD_SIZE (IMAGE_TLS_DIRECTORY32, AddressOfCallBacks, 4)
4899 TEST_FIELD_ALIGN (IMAGE_TLS_DIRECTORY32, AddressOfCallBacks, 4)
4900 TEST_FIELD_OFFSET(IMAGE_TLS_DIRECTORY32, AddressOfCallBacks, 12)
4901 TEST_FIELD_SIZE (IMAGE_TLS_DIRECTORY32, SizeOfZeroFill, 4)
4902 TEST_FIELD_ALIGN (IMAGE_TLS_DIRECTORY32, SizeOfZeroFill, 4)
4903 TEST_FIELD_OFFSET(IMAGE_TLS_DIRECTORY32, SizeOfZeroFill, 16)
4904 TEST_FIELD_SIZE (IMAGE_TLS_DIRECTORY32, Characteristics, 4)
4905 TEST_FIELD_ALIGN (IMAGE_TLS_DIRECTORY32, Characteristics, 4)
4906 TEST_FIELD_OFFSET(IMAGE_TLS_DIRECTORY32, Characteristics, 20)
4907}
4908
4910{
4911 /* IMAGE_TLS_DIRECTORY64 */
4914 TEST_FIELD_SIZE (IMAGE_TLS_DIRECTORY64, StartAddressOfRawData, 8)
4915 TEST_FIELD_ALIGN (IMAGE_TLS_DIRECTORY64, StartAddressOfRawData, 8)
4916 TEST_FIELD_OFFSET(IMAGE_TLS_DIRECTORY64, StartAddressOfRawData, 0)
4917 TEST_FIELD_SIZE (IMAGE_TLS_DIRECTORY64, EndAddressOfRawData, 8)
4918 TEST_FIELD_ALIGN (IMAGE_TLS_DIRECTORY64, EndAddressOfRawData, 8)
4919 TEST_FIELD_OFFSET(IMAGE_TLS_DIRECTORY64, EndAddressOfRawData, 8)
4920 TEST_FIELD_SIZE (IMAGE_TLS_DIRECTORY64, AddressOfIndex, 8)
4921 TEST_FIELD_ALIGN (IMAGE_TLS_DIRECTORY64, AddressOfIndex, 8)
4922 TEST_FIELD_OFFSET(IMAGE_TLS_DIRECTORY64, AddressOfIndex, 16)
4923 TEST_FIELD_SIZE (IMAGE_TLS_DIRECTORY64, AddressOfCallBacks, 8)
4924 TEST_FIELD_ALIGN (IMAGE_TLS_DIRECTORY64, AddressOfCallBacks, 8)
4925 TEST_FIELD_OFFSET(IMAGE_TLS_DIRECTORY64, AddressOfCallBacks, 24)
4926 TEST_FIELD_SIZE (IMAGE_TLS_DIRECTORY64, SizeOfZeroFill, 4)
4927 TEST_FIELD_ALIGN (IMAGE_TLS_DIRECTORY64, SizeOfZeroFill, 4)
4928 TEST_FIELD_OFFSET(IMAGE_TLS_DIRECTORY64, SizeOfZeroFill, 32)
4929 TEST_FIELD_SIZE (IMAGE_TLS_DIRECTORY64, Characteristics, 4)
4930 TEST_FIELD_ALIGN (IMAGE_TLS_DIRECTORY64, Characteristics, 4)
4931 TEST_FIELD_OFFSET(IMAGE_TLS_DIRECTORY64, Characteristics, 36)
4932}
4933
4935{
4936 /* IMAGE_VXD_HEADER (pack 2) */
4939 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_magic, 2)
4940 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_magic, 2)
4941 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_magic, 0)
4942 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_border, 1)
4943 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_border, 1)
4944 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_border, 2)
4945 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_worder, 1)
4946 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_worder, 1)
4947 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_worder, 3)
4948 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_level, 4)
4949 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_level, 2)
4950 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_level, 4)
4951 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_cpu, 2)
4957 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_ver, 4)
4960 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_mflags, 4)
4961 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_mflags, 2)
4962 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_mflags, 16)
4963 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_mpages, 4)
4964 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_mpages, 2)
4965 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_mpages, 20)
4966 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_startobj, 4)
4967 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_startobj, 2)
4968 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_startobj, 24)
4969 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_eip, 4)
4972 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_stackobj, 4)
4973 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_stackobj, 2)
4974 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_stackobj, 32)
4975 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_esp, 4)
4978 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_pagesize, 4)
4979 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_pagesize, 2)
4980 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_pagesize, 40)
4981 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_lastpagesize, 4)
4982 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_lastpagesize, 2)
4983 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_lastpagesize, 44)
4984 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_fixupsize, 4)
4985 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_fixupsize, 2)
4986 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_fixupsize, 48)
4987 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_fixupsum, 4)
4988 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_fixupsum, 2)
4989 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_fixupsum, 52)
4990 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_ldrsize, 4)
4991 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_ldrsize, 2)
4992 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_ldrsize, 56)
4993 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_ldrsum, 4)
4994 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_ldrsum, 2)
4995 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_ldrsum, 60)
4996 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_objtab, 4)
4997 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_objtab, 2)
4998 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_objtab, 64)
4999 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_objcnt, 4)
5000 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_objcnt, 2)
5001 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_objcnt, 68)
5002 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_objmap, 4)
5003 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_objmap, 2)
5004 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_objmap, 72)
5005 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_itermap, 4)
5006 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_itermap, 2)
5007 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_itermap, 76)
5008 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_rsrctab, 4)
5009 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_rsrctab, 2)
5010 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_rsrctab, 80)
5011 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_rsrccnt, 4)
5012 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_rsrccnt, 2)
5013 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_rsrccnt, 84)
5014 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_restab, 4)
5015 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_restab, 2)
5016 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_restab, 88)
5017 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_enttab, 4)
5018 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_enttab, 2)
5019 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_enttab, 92)
5020 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_dirtab, 4)
5021 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_dirtab, 2)
5022 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_dirtab, 96)
5023 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_dircnt, 4)
5024 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_dircnt, 2)
5025 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_dircnt, 100)
5026 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_fpagetab, 4)
5027 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_fpagetab, 2)
5028 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_fpagetab, 104)
5029 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_frectab, 4)
5030 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_frectab, 2)
5031 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_frectab, 108)
5032 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_impmod, 4)
5033 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_impmod, 2)
5034 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_impmod, 112)
5035 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_impmodcnt, 4)
5036 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_impmodcnt, 2)
5037 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_impmodcnt, 116)
5038 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_impproc, 4)
5039 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_impproc, 2)
5040 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_impproc, 120)
5041 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_pagesum, 4)
5042 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_pagesum, 2)
5043 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_pagesum, 124)
5044 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_datapage, 4)
5045 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_datapage, 2)
5046 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_datapage, 128)
5047 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_preload, 4)
5048 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_preload, 2)
5049 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_preload, 132)
5050 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_nrestab, 4)
5051 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_nrestab, 2)
5052 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_nrestab, 136)
5053 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_cbnrestab, 4)
5054 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_cbnrestab, 2)
5055 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_cbnrestab, 140)
5056 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_nressum, 4)
5057 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_nressum, 2)
5058 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_nressum, 144)
5059 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_autodata, 4)
5060 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_autodata, 2)
5061 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_autodata, 148)
5062 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_debuginfo, 4)
5063 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_debuginfo, 2)
5064 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_debuginfo, 152)
5065 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_debuglen, 4)
5066 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_debuglen, 2)
5067 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_debuglen, 156)
5068 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_instpreload, 4)
5069 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_instpreload, 2)
5070 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_instpreload, 160)
5071 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_instdemand, 4)
5072 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_instdemand, 2)
5073 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_instdemand, 164)
5074 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_heapsize, 4)
5075 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_heapsize, 2)
5076 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_heapsize, 168)
5077 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_res3, 12)
5078 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_res3, 1)
5079 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_res3, 172)
5080 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_winresoff, 4)
5081 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_winresoff, 2)
5082 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_winresoff, 184)
5083 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_winreslen, 4)
5084 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_winreslen, 2)
5085 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_winreslen, 188)
5086 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_devid, 2)
5087 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_devid, 2)
5088 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_devid, 192)
5089 TEST_FIELD_SIZE (IMAGE_VXD_HEADER, e32_ddkver, 2)
5090 TEST_FIELD_ALIGN (IMAGE_VXD_HEADER, e32_ddkver, 2)
5091 TEST_FIELD_OFFSET(IMAGE_VXD_HEADER, e32_ddkver, 194)
5092}
5093
5094static void test_pack_IO_COUNTERS(void)
5095{
5096 /* IO_COUNTERS (pack 8) */
5099 TEST_FIELD_SIZE (IO_COUNTERS, ReadOperationCount, 8)
5100 TEST_FIELD_ALIGN (IO_COUNTERS, ReadOperationCount, 8)
5101 TEST_FIELD_OFFSET(IO_COUNTERS, ReadOperationCount, 0)
5102 TEST_FIELD_SIZE (IO_COUNTERS, WriteOperationCount, 8)
5103 TEST_FIELD_ALIGN (IO_COUNTERS, WriteOperationCount, 8)
5104 TEST_FIELD_OFFSET(IO_COUNTERS, WriteOperationCount, 8)
5105 TEST_FIELD_SIZE (IO_COUNTERS, OtherOperationCount, 8)
5106 TEST_FIELD_ALIGN (IO_COUNTERS, OtherOperationCount, 8)
5107 TEST_FIELD_OFFSET(IO_COUNTERS, OtherOperationCount, 16)
5108 TEST_FIELD_SIZE (IO_COUNTERS, ReadTransferCount, 8)
5109 TEST_FIELD_ALIGN (IO_COUNTERS, ReadTransferCount, 8)
5110 TEST_FIELD_OFFSET(IO_COUNTERS, ReadTransferCount, 24)
5111 TEST_FIELD_SIZE (IO_COUNTERS, WriteTransferCount, 8)
5112 TEST_FIELD_ALIGN (IO_COUNTERS, WriteTransferCount, 8)
5113 TEST_FIELD_OFFSET(IO_COUNTERS, WriteTransferCount, 32)
5114 TEST_FIELD_SIZE (IO_COUNTERS, OtherTransferCount, 8)
5115 TEST_FIELD_ALIGN (IO_COUNTERS, OtherTransferCount, 8)
5116 TEST_FIELD_OFFSET(IO_COUNTERS, OtherTransferCount, 40)
5117}
5118
5119static void test_pack_LANGID(void)
5120{
5121 /* LANGID */
5125}
5126
5128{
5129 /* LARGE_INTEGER */
5130}
5131
5132static void test_pack_LCID(void)
5133{
5134 /* LCID */
5135 TEST_TYPE_SIZE (LCID, 4)
5138}
5139
5140static void test_pack_LIST_ENTRY(void)
5141{
5142 /* LIST_ENTRY */
5145 TEST_FIELD_SIZE (LIST_ENTRY, Flink, 4)
5146 TEST_FIELD_ALIGN (LIST_ENTRY, Flink, 4)
5147 TEST_FIELD_OFFSET(LIST_ENTRY, Flink, 0)
5148 TEST_FIELD_SIZE (LIST_ENTRY, Blink, 4)
5149 TEST_FIELD_ALIGN (LIST_ENTRY, Blink, 4)
5150 TEST_FIELD_OFFSET(LIST_ENTRY, Blink, 4)
5151}
5152
5153static void test_pack_LONG(void)
5154{
5155 /* LONG */
5156 TEST_TYPE_SIZE (LONG, 4)
5159}
5160
5161static void test_pack_LONGLONG(void)
5162{
5163 /* LONGLONG */
5167}
5168
5169static void test_pack_LUID(void)
5170{
5171 /* LUID */
5172 TEST_TYPE_SIZE (LUID, 8)
5174 TEST_FIELD_SIZE (LUID, LowPart, 4)
5175 TEST_FIELD_ALIGN (LUID, LowPart, 4)
5176 TEST_FIELD_OFFSET(LUID, LowPart, 0)
5177 TEST_FIELD_SIZE (LUID, HighPart, 4)
5178 TEST_FIELD_ALIGN (LUID, HighPart, 4)
5179 TEST_FIELD_OFFSET(LUID, HighPart, 4)
5180}
5181
5183{
5184 /* LUID_AND_ATTRIBUTES (pack 4) */
5193}
5194
5196{
5197 /* MEMORY_BASIC_INFORMATION */
5203 TEST_FIELD_SIZE (MEMORY_BASIC_INFORMATION, AllocationBase, 4)
5204 TEST_FIELD_ALIGN (MEMORY_BASIC_INFORMATION, AllocationBase, 4)
5206 TEST_FIELD_SIZE (MEMORY_BASIC_INFORMATION, AllocationProtect, 4)
5207 TEST_FIELD_ALIGN (MEMORY_BASIC_INFORMATION, AllocationProtect, 4)
5208 TEST_FIELD_OFFSET(MEMORY_BASIC_INFORMATION, AllocationProtect, 8)
5221}
5222
5224{
5225 /* MESSAGE_RESOURCE_BLOCK */
5234 TEST_FIELD_SIZE (MESSAGE_RESOURCE_BLOCK, OffsetToEntries, 4)
5235 TEST_FIELD_ALIGN (MESSAGE_RESOURCE_BLOCK, OffsetToEntries, 4)
5236 TEST_FIELD_OFFSET(MESSAGE_RESOURCE_BLOCK, OffsetToEntries, 8)
5237}
5238
5240{
5241 /* MESSAGE_RESOURCE_DATA */
5244 TEST_FIELD_SIZE (MESSAGE_RESOURCE_DATA, NumberOfBlocks, 4)
5245 TEST_FIELD_ALIGN (MESSAGE_RESOURCE_DATA, NumberOfBlocks, 4)
5246 TEST_FIELD_OFFSET(MESSAGE_RESOURCE_DATA, NumberOfBlocks, 0)
5250}
5251
5253{
5254 /* MESSAGE_RESOURCE_ENTRY */
5266}
5267
5268static void test_pack_NT_TIB(void)
5269{
5270 /* NT_TIB */
5271 TEST_FIELD_SIZE (NT_TIB, ExceptionList, 4)
5272 TEST_FIELD_ALIGN (NT_TIB, ExceptionList, 4)
5273 TEST_FIELD_OFFSET(NT_TIB, ExceptionList, 0)
5274 TEST_FIELD_SIZE (NT_TIB, StackBase, 4)
5275 TEST_FIELD_ALIGN (NT_TIB, StackBase, 4)
5276 TEST_FIELD_OFFSET(NT_TIB, StackBase, 4)
5277 TEST_FIELD_SIZE (NT_TIB, StackLimit, 4)
5278 TEST_FIELD_ALIGN (NT_TIB, StackLimit, 4)
5279 TEST_FIELD_OFFSET(NT_TIB, StackLimit, 8)
5280 TEST_FIELD_SIZE (NT_TIB, SubSystemTib, 4)
5281 TEST_FIELD_ALIGN (NT_TIB, SubSystemTib, 4)
5282 TEST_FIELD_OFFSET(NT_TIB, SubSystemTib, 12)
5283}
5284
5286{
5287 /* OBJECT_TYPE_LIST */
5299}
5300
5302{
5303 /* PACCESS_ALLOWED_ACE */
5308}
5309
5311{
5312 /* PACCESS_DENIED_ACE */
5317}
5318
5320{
5321 /* PACCESS_TOKEN */
5324}
5325
5326static void test_pack_PACE_HEADER(void)
5327{
5328 /* PACE_HEADER */
5333}
5334
5335static void test_pack_PACL(void)
5336{
5337 /* PACL */
5338 TEST_TYPE_SIZE (PACL, 4)
5342}
5343
5345{
5346 /* PACL_REVISION_INFORMATION */
5351}
5352
5354{
5355 /* PACL_SIZE_INFORMATION */
5360}
5361
5362static void test_pack_PCCH(void)
5363{
5364 /* PCCH */
5365 TEST_TYPE_SIZE (PCCH, 4)
5369}
5370
5371static void test_pack_PCH(void)
5372{
5373 /* PCH */
5374 TEST_TYPE_SIZE (PCH, 4)
5375 TEST_TYPE_ALIGN (PCH, 4)
5378}
5379
5380static void test_pack_PCSTR(void)
5381{
5382 /* PCSTR */
5387}
5388
5389static void test_pack_PCWCH(void)
5390{
5391 /* PCWCH */
5396}
5397
5398static void test_pack_PCWSTR(void)
5399{
5400 /* PCWSTR */
5405}
5406
5408{
5409 /* PEXCEPTION_POINTERS */
5414}
5415
5417{
5418 /* PEXCEPTION_RECORD */
5423}
5424
5425static void test_pack_PFPO_DATA(void)
5426{
5427 /* PFPO_DATA */
5432}
5433
5435{
5436 /* PGENERIC_MAPPING */
5441}
5442
5443static void test_pack_PHANDLE(void)
5444{
5445 /* PHANDLE */
5450}
5451
5453{
5454 /* PIMAGE_ARCHIVE_MEMBER_HEADER */
5459}
5460
5462{
5463 /* PIMAGE_AUX_SYMBOL */
5466}
5467
5469{
5470 /* PIMAGE_BASE_RELOCATION */
5475}
5476
5478{
5479 /* PIMAGE_BOUND_FORWARDER_REF */
5484}
5485
5487{
5488 /* PIMAGE_BOUND_IMPORT_DESCRIPTOR */
5493}
5494
5496{
5497 /* PIMAGE_COFF_SYMBOLS_HEADER */
5502}
5503
5505{
5506 /* PIMAGE_DATA_DIRECTORY */
5511}
5512
5514{
5515 /* PIMAGE_DEBUG_DIRECTORY */
5520}
5521
5523{
5524 /* PIMAGE_DEBUG_MISC */
5529}
5530
5532{
5533 /* PIMAGE_DOS_HEADER */
5538}
5539
5541{
5542 /* PIMAGE_EXPORT_DIRECTORY */
5547}
5548
5550{
5551 /* PIMAGE_FILE_HEADER */
5556}
5557
5559{
5560 /* PIMAGE_FUNCTION_ENTRY */
5565}
5566
5568{
5569 /* PIMAGE_IMPORT_BY_NAME */
5574}
5575
5577{
5578 /* PIMAGE_IMPORT_DESCRIPTOR */
5581}
5582
5584{
5585 /* PIMAGE_LINENUMBER */
5588}
5589
5591{
5592 /* PIMAGE_LOAD_CONFIG_DIRECTORY */
5595}
5596
5598{
5599 /* PIMAGE_NT_HEADERS */
5602}
5603
5605{
5606 /* PIMAGE_NT_HEADERS32 */
5611}
5612
5614{
5615 /* PIMAGE_NT_HEADERS64 */
5620}
5621
5623{
5624 /* PIMAGE_OPTIONAL_HEADER */
5627}
5628
5630{
5631 /* PIMAGE_OPTIONAL_HEADER32 */
5636}
5637
5639{
5640 /* PIMAGE_OPTIONAL_HEADER64 */
5645}
5646
5648{
5649 /* PIMAGE_OS2_HEADER */
5654}
5655
5657{
5658 /* PIMAGE_RELOCATION */
5661}
5662
5664{
5665 /* PIMAGE_RESOURCE_DATA_ENTRY */
5670}
5671
5673{
5674 /* PIMAGE_RESOURCE_DIRECTORY */
5679}
5680
5682{
5683 /* PIMAGE_RESOURCE_DIRECTORY_ENTRY */
5686}
5687
5689{
5690 /* PIMAGE_RESOURCE_DIRECTORY_STRING */
5695}
5696
5698{
5699 /* PIMAGE_RESOURCE_DIR_STRING_U */
5704}
5705
5707{
5708 /* PIMAGE_SECTION_HEADER */
5711}
5712
5714{
5715 /* PIMAGE_SEPARATE_DEBUG_HEADER */
5720}
5721
5723{
5724 /* PIMAGE_SYMBOL */
5727}
5728
5730{
5731 /* PIMAGE_THUNK_DATA */
5734}
5735
5737{
5738 /* PIMAGE_TLS_CALLBACK */
5741}
5742
5744{
5745 /* PIMAGE_TLS_DIRECTORY */
5748}
5749
5751{
5752 /* PIMAGE_VXD_HEADER */
5757}
5758
5759static void test_pack_PIO_COUNTERS(void)
5760{
5761 /* PIO_COUNTERS */
5766}
5767
5769{
5770 /* PISECURITY_DESCRIPTOR */
5775}
5776
5778{
5779 /* PISECURITY_DESCRIPTOR_RELATIVE */
5784}
5785
5786static void test_pack_PISID(void)
5787{
5788 /* PISID */
5793}
5794
5796{
5797 /* PLARGE_INTEGER */
5800}
5801
5802static void test_pack_PLIST_ENTRY(void)
5803{
5804 /* PLIST_ENTRY */
5809}
5810
5811static void test_pack_PLUID(void)
5812{
5813 /* PLUID */
5818}
5819
5821{
5822 /* PLUID_AND_ATTRIBUTES */
5827}
5828
5830{
5831 /* PMEMORY_BASIC_INFORMATION */
5836}
5837
5839{
5840 /* PMESSAGE_RESOURCE_BLOCK */
5845}
5846
5848{
5849 /* PMESSAGE_RESOURCE_DATA */
5854}
5855
5857{
5858 /* PMESSAGE_RESOURCE_ENTRY */
5863}
5864
5865static void test_pack_PNT_TIB(void)
5866{
5867 /* PNT_TIB */
5870}
5871
5873{
5874 /* POBJECT_TYPE_LIST */
5879}
5880
5882{
5883 /* PPRIVILEGE_SET */
5888}
5889
5891{
5892 /* PRIVILEGE_SET */
5895 TEST_FIELD_SIZE (PRIVILEGE_SET, PrivilegeCount, 4)
5896 TEST_FIELD_ALIGN (PRIVILEGE_SET, PrivilegeCount, 4)
5897 TEST_FIELD_OFFSET(PRIVILEGE_SET, PrivilegeCount, 0)
5904}
5905
5906static void test_pack_PRLIST_ENTRY(void)
5907{
5908 /* PRLIST_ENTRY */
5913}
5914
5916{
5917 /* PRTL_CRITICAL_SECTION */
5922}
5923
5925{
5926 /* PRTL_CRITICAL_SECTION_DEBUG */
5929}
5930
5932{
5933 /* PRTL_OSVERSIONINFOEXW */
5938}
5939
5941{
5942 /* PRTL_OSVERSIONINFOW */
5947}
5948
5950{
5951 /* PRTL_RESOURCE_DEBUG */
5954}
5955
5957{
5958 /* PSECURITY_DESCRIPTOR */
5961}
5962
5964{
5965 /* PSECURITY_QUALITY_OF_SERVICE */
5968}
5969
5970static void test_pack_PSID(void)
5971{
5972 /* PSID */
5973 TEST_TYPE_SIZE (PSID, 4)
5975}
5976
5978{
5979 /* PSID_IDENTIFIER_AUTHORITY */
5984}
5985
5987{
5988 /* PSINGLE_LIST_ENTRY */
5993}
5994
5995static void test_pack_PSTR(void)
5996{
5997 /* PSTR */
5998 TEST_TYPE_SIZE (PSTR, 4)
6002}
6003
6005{
6006 /* PSYSTEM_ALARM_ACE */
6011}
6012
6014{
6015 /* PSYSTEM_AUDIT_ACE */
6020}
6021
6023{
6024 /* PTOKEN_GROUPS */
6029}
6030
6032{
6033 /* PTOKEN_PRIVILEGES */
6038}
6039
6040static void test_pack_PTOKEN_USER(void)
6041{
6042 /* PTOKEN_USER */
6047}
6048
6050{
6051 /* PULARGE_INTEGER */
6054}
6055
6057{
6058 /* PVECTORED_EXCEPTION_HANDLER */
6061}
6062
6063static void test_pack_PVOID(void)
6064{
6065 /* PVOID */
6068}
6069
6070static void test_pack_PWCH(void)
6071{
6072 /* PWCH */
6073 TEST_TYPE_SIZE (PWCH, 4)
6077}
6078
6079static void test_pack_PWSTR(void)
6080{
6081 /* PWSTR */
6086}
6087
6089{
6090 /* RTL_CRITICAL_SECTION */
6099 TEST_FIELD_SIZE (RTL_CRITICAL_SECTION, RecursionCount, 4)
6100 TEST_FIELD_ALIGN (RTL_CRITICAL_SECTION, RecursionCount, 4)
6101 TEST_FIELD_OFFSET(RTL_CRITICAL_SECTION, RecursionCount, 8)
6105 TEST_FIELD_SIZE (RTL_CRITICAL_SECTION, LockSemaphore, 4)
6106 TEST_FIELD_ALIGN (RTL_CRITICAL_SECTION, LockSemaphore, 4)
6107 TEST_FIELD_OFFSET(RTL_CRITICAL_SECTION, LockSemaphore, 16)
6111}
6112
6114{
6115 /* RTL_CRITICAL_SECTION_DEBUG */
6119 TEST_FIELD_SIZE (RTL_CRITICAL_SECTION_DEBUG, CreatorBackTraceIndex, 2)
6120 TEST_FIELD_ALIGN (RTL_CRITICAL_SECTION_DEBUG, CreatorBackTraceIndex, 2)
6121 TEST_FIELD_OFFSET(RTL_CRITICAL_SECTION_DEBUG, CreatorBackTraceIndex, 2)
6125 TEST_FIELD_SIZE (RTL_CRITICAL_SECTION_DEBUG, ProcessLocksList, 8)
6126 TEST_FIELD_ALIGN (RTL_CRITICAL_SECTION_DEBUG, ProcessLocksList, 4)
6127 TEST_FIELD_OFFSET(RTL_CRITICAL_SECTION_DEBUG, ProcessLocksList, 8)
6131 TEST_FIELD_SIZE (RTL_CRITICAL_SECTION_DEBUG, ContentionCount, 4)
6132 TEST_FIELD_ALIGN (RTL_CRITICAL_SECTION_DEBUG, ContentionCount, 4)
6133 TEST_FIELD_OFFSET(RTL_CRITICAL_SECTION_DEBUG, ContentionCount, 20)
6134}
6135
6137{
6138 /* RTL_OSVERSIONINFOEXW */
6141 TEST_FIELD_SIZE (RTL_OSVERSIONINFOEXW, dwOSVersionInfoSize, 4)
6142 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOEXW, dwOSVersionInfoSize, 4)
6143 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOEXW, dwOSVersionInfoSize, 0)
6144 TEST_FIELD_SIZE (RTL_OSVERSIONINFOEXW, dwMajorVersion, 4)
6145 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOEXW, dwMajorVersion, 4)
6146 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOEXW, dwMajorVersion, 4)
6147 TEST_FIELD_SIZE (RTL_OSVERSIONINFOEXW, dwMinorVersion, 4)
6148 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOEXW, dwMinorVersion, 4)
6149 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOEXW, dwMinorVersion, 8)
6150 TEST_FIELD_SIZE (RTL_OSVERSIONINFOEXW, dwBuildNumber, 4)
6151 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOEXW, dwBuildNumber, 4)
6152 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOEXW, dwBuildNumber, 12)
6153 TEST_FIELD_SIZE (RTL_OSVERSIONINFOEXW, dwPlatformId, 4)
6154 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOEXW, dwPlatformId, 4)
6155 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOEXW, dwPlatformId, 16)
6156 TEST_FIELD_SIZE (RTL_OSVERSIONINFOEXW, szCSDVersion, 256)
6157 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOEXW, szCSDVersion, 2)
6158 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOEXW, szCSDVersion, 20)
6159 TEST_FIELD_SIZE (RTL_OSVERSIONINFOEXW, wServicePackMajor, 2)
6160 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOEXW, wServicePackMajor, 2)
6161 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOEXW, wServicePackMajor, 276)
6162 TEST_FIELD_SIZE (RTL_OSVERSIONINFOEXW, wServicePackMinor, 2)
6163 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOEXW, wServicePackMinor, 2)
6164 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOEXW, wServicePackMinor, 278)
6165 TEST_FIELD_SIZE (RTL_OSVERSIONINFOEXW, wSuiteMask, 2)
6166 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOEXW, wSuiteMask, 2)
6167 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOEXW, wSuiteMask, 280)
6168 TEST_FIELD_SIZE (RTL_OSVERSIONINFOEXW, wProductType, 1)
6169 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOEXW, wProductType, 1)
6170 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOEXW, wProductType, 282)
6174}
6175
6177{
6178 /* RTL_OSVERSIONINFOW */
6181 TEST_FIELD_SIZE (RTL_OSVERSIONINFOW, dwOSVersionInfoSize, 4)
6182 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOW, dwOSVersionInfoSize, 4)
6183 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOW, dwOSVersionInfoSize, 0)
6184 TEST_FIELD_SIZE (RTL_OSVERSIONINFOW, dwMajorVersion, 4)
6185 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOW, dwMajorVersion, 4)
6186 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOW, dwMajorVersion, 4)
6187 TEST_FIELD_SIZE (RTL_OSVERSIONINFOW, dwMinorVersion, 4)
6188 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOW, dwMinorVersion, 4)
6189 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOW, dwMinorVersion, 8)
6190 TEST_FIELD_SIZE (RTL_OSVERSIONINFOW, dwBuildNumber, 4)
6191 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOW, dwBuildNumber, 4)
6192 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOW, dwBuildNumber, 12)
6193 TEST_FIELD_SIZE (RTL_OSVERSIONINFOW, dwPlatformId, 4)
6194 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOW, dwPlatformId, 4)
6195 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOW, dwPlatformId, 16)
6196 TEST_FIELD_SIZE (RTL_OSVERSIONINFOW, szCSDVersion, 256)
6197 TEST_FIELD_ALIGN (RTL_OSVERSIONINFOW, szCSDVersion, 2)
6198 TEST_FIELD_OFFSET(RTL_OSVERSIONINFOW, szCSDVersion, 20)
6199}
6200
6202{
6203 /* RTL_RESOURCE_DEBUG */
6207 TEST_FIELD_SIZE (RTL_RESOURCE_DEBUG, CreatorBackTraceIndex, 2)
6208 TEST_FIELD_ALIGN (RTL_RESOURCE_DEBUG, CreatorBackTraceIndex, 2)
6209 TEST_FIELD_OFFSET(RTL_RESOURCE_DEBUG, CreatorBackTraceIndex, 2)
6213 TEST_FIELD_SIZE (RTL_RESOURCE_DEBUG, ProcessLocksList, 8)
6214 TEST_FIELD_ALIGN (RTL_RESOURCE_DEBUG, ProcessLocksList, 4)
6215 TEST_FIELD_OFFSET(RTL_RESOURCE_DEBUG, ProcessLocksList, 8)
6216 TEST_FIELD_SIZE (RTL_RESOURCE_DEBUG, EntryCount, 4)
6217 TEST_FIELD_ALIGN (RTL_RESOURCE_DEBUG, EntryCount, 4)
6218 TEST_FIELD_OFFSET(RTL_RESOURCE_DEBUG, EntryCount, 16)
6219 TEST_FIELD_SIZE (RTL_RESOURCE_DEBUG, ContentionCount, 4)
6220 TEST_FIELD_ALIGN (RTL_RESOURCE_DEBUG, ContentionCount, 4)
6221 TEST_FIELD_OFFSET(RTL_RESOURCE_DEBUG, ContentionCount, 20)
6222}
6223
6225{
6226 /* SECURITY_CONTEXT_TRACKING_MODE */
6229}
6230
6232{
6233 /* SECURITY_DESCRIPTOR */
6257}
6258
6260{
6261 /* SECURITY_DESCRIPTOR_CONTROL */
6265}
6266
6268{
6269 /* SECURITY_DESCRIPTOR_RELATIVE */
6293}
6294
6296{
6297 /* SECURITY_INFORMATION */
6301}
6302
6304{
6305 /* SECURITY_QUALITY_OF_SERVICE */
6309}
6310
6311static void test_pack_SHORT(void)
6312{
6313 /* SHORT */
6317}
6318
6319static void test_pack_SID(void)
6320{
6321 /* SID */
6322 TEST_TYPE_SIZE (SID, 12)
6323 TEST_TYPE_ALIGN (SID, 4)
6333 TEST_FIELD_SIZE (SID, SubAuthority, 4)
6334 TEST_FIELD_ALIGN (SID, SubAuthority, 4)
6335 TEST_FIELD_OFFSET(SID, SubAuthority, 8)
6336}
6337
6339{
6340 /* SID_AND_ATTRIBUTES */
6349}
6350
6352{
6353 /* SID_IDENTIFIER_AUTHORITY */
6359}
6360
6362{
6363 /* SINGLE_LIST_ENTRY */
6369}
6370
6372{
6373 /* SYSTEM_ALARM_ACE */
6382 TEST_FIELD_SIZE (SYSTEM_ALARM_ACE, SidStart, 4)
6383 TEST_FIELD_ALIGN (SYSTEM_ALARM_ACE, SidStart, 4)
6385}
6386
6388{
6389 /* SYSTEM_AUDIT_ACE */
6398 TEST_FIELD_SIZE (SYSTEM_AUDIT_ACE, SidStart, 4)
6399 TEST_FIELD_ALIGN (SYSTEM_AUDIT_ACE, SidStart, 4)
6401}
6402
6404{
6405 /* TOKEN_DEFAULT_DACL */
6408 TEST_FIELD_SIZE (TOKEN_DEFAULT_DACL, DefaultDacl, 4)
6409 TEST_FIELD_ALIGN (TOKEN_DEFAULT_DACL, DefaultDacl, 4)
6410 TEST_FIELD_OFFSET(TOKEN_DEFAULT_DACL, DefaultDacl, 0)
6411}
6412
6413static void test_pack_TOKEN_GROUPS(void)
6414{
6415 /* TOKEN_GROUPS */
6418 TEST_FIELD_SIZE (TOKEN_GROUPS, GroupCount, 4)
6419 TEST_FIELD_ALIGN (TOKEN_GROUPS, GroupCount, 4)
6420 TEST_FIELD_OFFSET(TOKEN_GROUPS, GroupCount, 0)
6421 TEST_FIELD_SIZE (TOKEN_GROUPS, Groups, 8)
6422 TEST_FIELD_ALIGN (TOKEN_GROUPS, Groups, 4)
6424}
6425
6426static void test_pack_TOKEN_OWNER(void)
6427{
6428 /* TOKEN_OWNER */
6434}
6435
6437{
6438 /* TOKEN_PRIMARY_GROUP */
6444}
6445
6447{
6448 /* TOKEN_PRIVILEGES */
6451 TEST_FIELD_SIZE (TOKEN_PRIVILEGES, PrivilegeCount, 4)
6452 TEST_FIELD_ALIGN (TOKEN_PRIVILEGES, PrivilegeCount, 4)
6453 TEST_FIELD_OFFSET(TOKEN_PRIVILEGES, PrivilegeCount, 0)
6457}
6458
6459static void test_pack_TOKEN_SOURCE(void)
6460{
6461 /* TOKEN_SOURCE */
6467 TEST_FIELD_SIZE (TOKEN_SOURCE, SourceIdentifier, 8)
6468 TEST_FIELD_ALIGN (TOKEN_SOURCE, SourceIdentifier, 4)
6469 TEST_FIELD_OFFSET(TOKEN_SOURCE, SourceIdentifier, 8)
6470}
6471
6473{
6474 /* TOKEN_STATISTICS (pack 4) */
6475 TEST_FIELD_SIZE (TOKEN_STATISTICS, TokenId, 8)
6478 TEST_FIELD_SIZE (TOKEN_STATISTICS, AuthenticationId, 8)
6479 TEST_FIELD_ALIGN (TOKEN_STATISTICS, AuthenticationId, 4)
6480 TEST_FIELD_OFFSET(TOKEN_STATISTICS, AuthenticationId, 8)
6481 TEST_FIELD_SIZE (TOKEN_STATISTICS, ExpirationTime, 8)
6482 TEST_FIELD_ALIGN (TOKEN_STATISTICS, ExpirationTime, 4)
6483 TEST_FIELD_OFFSET(TOKEN_STATISTICS, ExpirationTime, 16)
6484}
6485
6486static void test_pack_TOKEN_USER(void)
6487{
6488 /* TOKEN_USER */
6491 TEST_FIELD_SIZE (TOKEN_USER, User, 8)
6492 TEST_FIELD_ALIGN (TOKEN_USER, User, 4)
6494}
6495
6497{
6498 /* ULARGE_INTEGER */
6499}
6500
6501static void test_pack_ULONGLONG(void)
6502{
6503 /* ULONGLONG */
6507}
6508
6510{
6511 /* WAITORTIMERCALLBACKFUNC */
6514}
6515
6516static void test_pack_WCHAR(void)
6517{
6518 /* WCHAR */
6522}
6523
6524static void test_pack_ATOM(void)
6525{
6526 /* ATOM */
6527 TEST_TYPE_SIZE (ATOM, 2)
6530}
6531
6532static void test_pack_BOOL(void)
6533{
6534 /* BOOL */
6535 TEST_TYPE_SIZE (BOOL, 4)
6538}
6539
6540static void test_pack_BYTE(void)
6541{
6542 /* BYTE */
6543 TEST_TYPE_SIZE (BYTE, 1)
6546}
6547
6548static void test_pack_COLORREF(void)
6549{
6550 /* COLORREF */
6554}
6555
6556static void test_pack_DWORD(void)
6557{
6558 /* DWORD */
6562}
6563
6564static void test_pack_FARPROC(void)
6565{
6566 /* FARPROC */
6569}
6570
6571static void test_pack_FLOAT(void)
6572{
6573 /* FLOAT */
6576}
6577
6578static void test_pack_GLOBALHANDLE(void)
6579{
6580 /* GLOBALHANDLE */
6583}
6584
6585static void test_pack_HCURSOR(void)
6586{
6587 /* HCURSOR */
6590}
6591
6592static void test_pack_HFILE(void)
6593{
6594 /* HFILE */
6598}
6599
6600static void test_pack_HGDIOBJ(void)
6601{
6602 /* HGDIOBJ */
6605}
6606
6607static void test_pack_HGLOBAL(void)
6608{
6609 /* HGLOBAL */
6612}
6613
6614static void test_pack_HLOCAL(void)
6615{
6616 /* HLOCAL */
6619}
6620
6621static void test_pack_HMODULE(void)
6622{
6623 /* HMODULE */
6626}
6627
6628static void test_pack_INT(void)
6629{
6630 /* INT */
6631 TEST_TYPE_SIZE (INT, 4)
6632 TEST_TYPE_ALIGN (INT, 4)
6634}
6635
6636static void test_pack_LOCALHANDLE(void)
6637{
6638 /* LOCALHANDLE */
6641}
6642
6643static void test_pack_LPARAM(void)
6644{
6645 /* LPARAM */
6648}
6649
6650static void test_pack_LPCRECT(void)
6651{
6652 /* LPCRECT */
6657}
6658
6659static void test_pack_LPCRECTL(void)
6660{
6661 /* LPCRECTL */
6666}
6667
6668static void test_pack_LPCVOID(void)
6669{
6670 /* LPCVOID */
6673}
6674
6675static void test_pack_LPPOINT(void)
6676{
6677 /* LPPOINT */
6682}
6683
6684static void test_pack_LPRECT(void)
6685{
6686 /* LPRECT */
6691}
6692
6693static void test_pack_LPRECTL(void)
6694{
6695 /* LPRECTL */
6700}
6701
6702static void test_pack_LPSIZE(void)
6703{
6704 /* LPSIZE */
6709}
6710
6711static void test_pack_LRESULT(void)
6712{
6713 /* LRESULT */
6716}
6717
6718static void test_pack_POINT(void)
6719{
6720 /* POINT */
6723 TEST_FIELD_SIZE (POINT, x, 4)
6726 TEST_FIELD_SIZE (POINT, y, 4)
6729}
6730
6731static void test_pack_POINTL(void)
6732{
6733 /* POINTL */
6742}
6743
6744static void test_pack_PPOINT(void)
6745{
6746 /* PPOINT */
6751}
6752
6753static void test_pack_PPOINTL(void)
6754{
6755 /* PPOINTL */
6760}
6761
6762static void test_pack_PRECT(void)
6763{
6764 /* PRECT */
6769}
6770
6771static void test_pack_PRECTL(void)
6772{
6773 /* PRECTL */
6778}
6779
6780static void test_pack_PROC(void)
6781{
6782 /* PROC */
6783 TEST_TYPE_SIZE (PROC, 4)
6785}
6786
6787static void test_pack_PSIZE(void)
6788{
6789 /* PSIZE */
6794}
6795
6796static void test_pack_PSZ(void)
6797{
6798 /* PSZ */
6799 TEST_TYPE_SIZE (PSZ, 4)
6800 TEST_TYPE_ALIGN (PSZ, 4)
6801}
6802
6803static void test_pack_RECT(void)
6804{
6805 /* RECT */
6806 TEST_TYPE_SIZE (RECT, 16)
6820}
6821
6822static void test_pack_RECTL(void)
6823{
6824 /* RECTL */
6825 TEST_TYPE_SIZE (RECTL, 16)
6839}
6840
6841static void test_pack_SIZE(void)
6842{
6843 /* SIZE */
6844 TEST_TYPE_SIZE (SIZE, 8)
6846 TEST_FIELD_SIZE (SIZE, cx, 4)
6849 TEST_FIELD_SIZE (SIZE, cy, 4)
6852}
6853
6854static void test_pack_SIZEL(void)
6855{
6856 /* SIZEL */
6859}
6860
6861static void test_pack_UCHAR(void)
6862{
6863 /* UCHAR */
6867}
6868
6869static void test_pack_UINT(void)
6870{
6871 /* UINT */
6872 TEST_TYPE_SIZE (UINT, 4)
6875}
6876
6877static void test_pack_ULONG(void)
6878{
6879 /* ULONG */
6883}
6884
6885static void test_pack_USHORT(void)
6886{
6887 /* USHORT */
6891}
6892
6893static void test_pack_WORD(void)
6894{
6895 /* WORD */
6896 TEST_TYPE_SIZE (WORD, 2)
6899}
6900
6901static void test_pack_WPARAM(void)
6902{
6903 /* WPARAM */
6906}
6907
6908#endif /* _WIN64 */
6909
6910static void test_pack(void)
6911{
6916 test_pack_ACL();
6988 test_pack_INT();
7030 test_pack_PCH();
7114 test_pack_PSZ();
7137 test_pack_SID();
7174}
7175
7176START_TEST(generated)
7177{
7178 test_pack();
7179}
unsigned short UINT16
signed int INT32
unsigned char BOOLEAN
signed short INT16
unsigned long long UINT64
signed char INT8
unsigned char UINT8
unsigned int UINT32
signed long long INT64
Type
Definition: Type.h:7
#define PROC(name)
Definition: WinHttpOpen.c:37
WCHAR SourceName[256]
Definition: arping.c:28
#define START_TEST(x)
Definition: atltest.h:75
int LONG32
Definition: basetsd.h:121
LONG_PTR SSIZE_T
Definition: basetsd.h:181
unsigned int ULONG32
Definition: basetsd.h:123
short HALF_PTR
Definition: basetsd.h:76
unsigned short UHALF_PTR
Definition: basetsd.h:75
unsigned int DWORD32
Definition: basetsd.h:124
@ Reserved1
Definition: bcd.h:201
_Inout_ PIRP _In_ NTSTATUS ExceptionCode
Definition: cdprocs.h:1774
Definition: Header.h:9
char * Text
Definition: combotst.c:136
LONG LockCount
Definition: comsup.c:6
WORD ATOM
Definition: dimm.idl:113
static const ACEFLAG AceFlags[]
Definition: security.c:2624
static const ACEFLAG AceType[]
Definition: security.c:2583
int(* FARPROC)()
Definition: compat.h:36
static const WCHAR Signature[]
Definition: parser.c:141
ULONG MajorVersion
Definition: ros_glue.cpp:4
ULONG MinorVersion
Definition: ros_glue.cpp:5
unsigned int BOOL
Definition: ntddk_ex.h:94
unsigned long DWORD
Definition: ntddk_ex.h:95
unsigned short WORD
Definition: ntddk_ex.h:93
unsigned int Mask
Definition: fpcontrol.c:82
#define TEST_TARGET_SIZE(type, size)
Definition: generated.c:68
#define TEST_FIELD_OFFSET(type, field, offset)
Definition: generated.c:66
#define TEST_TARGET_ALIGN(type, align)
Definition: generated.c:62
static void test_pack(void)
Definition: generated.c:13122
#define TEST_TYPE_SIZE(type, size)
Definition: generated.c:50
#define TEST_FIELD_SIZE(type, field, size)
Definition: generated.c:69
#define TEST_TYPE_ALIGN(type, align)
Definition: generated.c:55
#define TEST_FIELD_ALIGN(type, field, align)
Definition: generated.c:63
GLint GLint GLint GLint GLint x
Definition: gl.h:1548
GLint GLint GLint GLint GLint GLint y
Definition: gl.h:1548
GLdouble GLdouble GLdouble GLdouble top
Definition: glext.h:10859
GLdouble GLdouble right
Definition: glext.h:10859
GLint left
Definition: glext.h:7726
GLint GLint bottom
Definition: glext.h:7726
_In_ ULONG Mode
Definition: hubbusif.h:303
@ ProcessAffinityMask
Definition: winternl.h:877
unsigned long long DWORDLONG
Definition: intsafe.h:93
CRITICAL_SECTION CriticalSection
Definition: iprtprio.c:40
USHORT LANGID
Definition: mui.h:9
BYTE SECURITY_CONTEXT_TRACKING_MODE
Definition: lsa.idl:61
WORD SECURITY_DESCRIPTOR_CONTROL
Definition: lsa.idl:37
unsigned __int64 ULONG64
Definition: imports.h:198
ObjectType
Definition: metafile.c:81
DWORD e_lfanew
Definition: crypt.c:1156
WORD e_magic
Definition: crypt.c:1154
DWORD SECURITY_INFORMATION
Definition: ms-dtyp.idl:311
__int3264 LONG_PTR
Definition: mstsclib_h.h:276
unsigned __int3264 UINT_PTR
Definition: mstsclib_h.h:274
unsigned int UINT
Definition: ndis.h:50
_In_ HANDLE _Outptr_result_bytebuffer_ ViewSize PVOID * BaseAddress
Definition: mmfuncs.h:404
__kernel_entry _Inout_ _Inout_ PSIZE_T RegionSize
Definition: mmfuncs.h:172
_Out_writes_bytes_to_opt_ AbsoluteSecurityDescriptorSize PSECURITY_DESCRIPTOR _Inout_ PULONG _Out_writes_bytes_to_opt_ DaclSize PACL Dacl
Definition: rtlfuncs.h:1605
_In_opt_ PSID Group
Definition: rtlfuncs.h:1658
_Out_writes_bytes_to_opt_ AbsoluteSecurityDescriptorSize PSECURITY_DESCRIPTOR _Inout_ PULONG _Out_writes_bytes_to_opt_ DaclSize PACL _Inout_ PULONG _Out_writes_bytes_to_opt_ SaclSize PACL _Inout_ PULONG _Out_writes_bytes_to_opt_ OwnerSize PSID Owner
Definition: rtlfuncs.h:1609
_Out_writes_bytes_to_opt_ AbsoluteSecurityDescriptorSize PSECURITY_DESCRIPTOR _Inout_ PULONG _Out_writes_bytes_to_opt_ DaclSize PACL _Inout_ PULONG _Out_writes_bytes_to_opt_ SaclSize PACL _Inout_ PULONG _Out_writes_bytes_to_opt_ OwnerSize PSID _Inout_ PULONG _Out_writes_bytes_to_opt_ PrimaryGroupSize PSID PrimaryGroup
Definition: rtlfuncs.h:1611
_In_ PSID_IDENTIFIER_AUTHORITY _In_ UCHAR SubAuthorityCount
Definition: rtlfuncs.h:1527
_In_opt_ ULONG Base
Definition: rtlfuncs.h:2451
_Out_writes_bytes_to_opt_ AbsoluteSecurityDescriptorSize PSECURITY_DESCRIPTOR _Inout_ PULONG _Out_writes_bytes_to_opt_ DaclSize PACL _Inout_ PULONG _Out_writes_bytes_to_opt_ SaclSize PACL Sacl
Definition: rtlfuncs.h:1607
_In_ ULONG _In_ ACCESS_MASK _In_ PSID Sid
Definition: rtlfuncs.h:1145
_In_ ULONG Revision
Definition: rtlfuncs.h:1142
_In_ PSID_IDENTIFIER_AUTHORITY IdentifierAuthority
Definition: rtlfuncs.h:1525
VOID(NTAPI * WAITORTIMERCALLBACKFUNC)(PVOID pvContext, BOOLEAN fTimerOrWaitFired)
Definition: rtltypes.h:496
LONG(NTAPI * PVECTORED_EXCEPTION_HANDLER)(PEXCEPTION_POINTERS ExceptionPointers)
Definition: rtltypes.h:505
ULONG ACCESS_MASK
Definition: nt_native.h:40
WCHAR * PWCH
Definition: ntbasedef.h:410
_IRQL_requires_same_ _In_ PVOID _Inout_ struct _CONTEXT * ContextRecord
Definition: ntbasedef.h:654
CHAR * PCH
Definition: ntbasedef.h:391
CONST WCHAR * PCWCH
Definition: ntbasedef.h:411
*RESTRICTED_POINTER PRLIST_ENTRY
Definition: ntbasedef.h:615
CONST CHAR * PCCH
Definition: ntbasedef.h:392
_In_ ULONG _In_ ULONG _In_ ULONG Length
Definition: ntddpcm.h:102
static void test_pack_IMAGE_NT_HEADERS(void)
Definition: generated.c:4393
static void test_pack_PEXCEPTION_RECORD(void)
Definition: generated.c:5416
static void test_pack_OBJECT_TYPE_LIST(void)
Definition: generated.c:5285
static void test_pack_INT(void)
Definition: generated.c:6628
static void test_pack_IMAGE_RESOURCE_DIRECTORY_STRING(void)
Definition: generated.c:4787
static void test_pack_PSTR(void)
Definition: generated.c:5995
static void test_pack_IMAGE_BOUND_FORWARDER_REF(void)
Definition: generated.c:3952
static void test_pack_IMAGE_COFF_SYMBOLS_HEADER(void)
Definition: generated.c:3984
static void test_pack_PIMAGE_RESOURCE_DIR_STRING_U(void)
Definition: generated.c:5697
static void test_pack_IMAGE_SECTION_HEADER(void)
Definition: generated.c:4813
static void test_pack_IMAGE_VXD_HEADER(void)
Definition: generated.c:4934
static void test_pack_PIMAGE_SECTION_HEADER(void)
Definition: generated.c:5706
static void test_pack_IMAGE_TLS_DIRECTORY32(void)
Definition: generated.c:4884
static void test_pack_PIMAGE_RESOURCE_DIRECTORY(void)
Definition: generated.c:5672
static void test_pack_TOKEN_USER(void)
Definition: generated.c:6486
static void test_pack_PIMAGE_THUNK_DATA(void)
Definition: generated.c:5729
static void test_pack_POINTL(void)
Definition: generated.c:6731
static void test_pack_IMAGE_OPTIONAL_HEADER32(void)
Definition: generated.c:4439
static void test_pack_IMAGE_DOS_HEADER(void)
Definition: generated.c:4081
static void test_pack_PIMAGE_EXPORT_DIRECTORY(void)
Definition: generated.c:5540
static void test_pack_ULONG64(void)
Definition: generated.c:3658
static void test_pack_INT64(void)
Definition: generated.c:3540
static void test_pack_ULONG_PTR(void)
Definition: generated.c:3666
static void test_pack_IMAGE_DEBUG_MISC(void)
Definition: generated.c:4059
static void test_pack_IMAGE_RESOURCE_DIRECTORY(void)
Definition: generated.c:4757
static void test_pack_PIMAGE_TLS_DIRECTORY(void)
Definition: generated.c:5743
static void test_pack_PIMAGE_FUNCTION_ENTRY(void)
Definition: generated.c:5558
static void test_pack_PACE_HEADER(void)
Definition: generated.c:5326
static void test_pack_SYSTEM_ALARM_ACE(void)
Definition: generated.c:6371
static void test_pack_PSYSTEM_ALARM_ACE(void)
Definition: generated.c:6004
static void test_pack_FPO_DATA(void)
Definition: generated.c:3854
static void test_pack_PCSTR(void)
Definition: generated.c:5380
static void test_pack_BYTE(void)
Definition: generated.c:6540
static void test_pack_LCID(void)
Definition: generated.c:5132
static void test_pack_PACCESS_ALLOWED_ACE(void)
Definition: generated.c:5301
static void test_pack_GENERIC_MAPPING(void)
Definition: generated.c:3873
static void test_pack_HMODULE(void)
Definition: generated.c:6621
static void test_pack_PACL(void)
Definition: generated.c:5335
static void test_pack_PLARGE_INTEGER(void)
Definition: generated.c:5795
static void test_pack_LONG32(void)
Definition: generated.c:3564
static void test_pack_PSYSTEM_AUDIT_ACE(void)
Definition: generated.c:6013
static void test_pack_HGDIOBJ(void)
Definition: generated.c:6600
static void test_pack_RTL_OSVERSIONINFOEXW(void)
Definition: generated.c:6136
static void test_pack_IMAGE_TLS_DIRECTORY64(void)
Definition: generated.c:4909
static void test_pack_PSZ(void)
Definition: generated.c:6796
static void test_pack_IMAGE_NT_HEADERS32(void)
Definition: generated.c:4400
static void test_pack_PIMAGE_LINENUMBER(void)
Definition: generated.c:5583
static void test_pack_TOKEN_STATISTICS(void)
Definition: generated.c:6472
static void test_pack_TOKEN_DEFAULT_DACL(void)
Definition: generated.c:6403
static void test_pack_PISID(void)
Definition: generated.c:5786
static void test_pack_LIST_ENTRY(void)
Definition: generated.c:5140
static void test_pack_PFPO_DATA(void)
Definition: generated.c:5425
static void test_pack_HALF_PTR(void)
Definition: generated.c:3516
static void test_pack_PSIZE(void)
Definition: generated.c:6787
static void test_pack_PIMAGE_OPTIONAL_HEADER64(void)
Definition: generated.c:5638
static void test_pack_PIMAGE_RESOURCE_DATA_ENTRY(void)
Definition: generated.c:5663
static void test_pack_PIMAGE_TLS_CALLBACK(void)
Definition: generated.c:5736
static void test_pack_CCHAR(void)
Definition: generated.c:3786
static void test_pack_INT8(void)
Definition: generated.c:3548
static void test_pack_PIMAGE_OS2_HEADER(void)
Definition: generated.c:5647
static void test_pack_PIMAGE_BOUND_IMPORT_DESCRIPTOR(void)
Definition: generated.c:5486
static void test_pack_PWCH(void)
Definition: generated.c:6070
static void test_pack_IMAGE_BASE_RELOCATION(void)
Definition: generated.c:3939
static void test_pack_IMAGE_BOUND_IMPORT_DESCRIPTOR(void)
Definition: generated.c:3968
static void test_pack_ATOM(void)
Definition: generated.c:6524
static void test_pack_LPRECTL(void)
Definition: generated.c:6693
static void test_pack_SIZE(void)
Definition: generated.c:6841
static void test_pack_RTL_OSVERSIONINFOW(void)
Definition: generated.c:6176
static void test_pack_IMAGE_AUX_SYMBOL(void)
Definition: generated.c:3934
static void test_pack_ACCESS_DENIED_ACE(void)
Definition: generated.c:3690
static void test_pack_IMAGE_RESOURCE_DIRECTORY_ENTRY(void)
Definition: generated.c:4782
static void test_pack_IMAGE_RELOCATION(void)
Definition: generated.c:4733
static void test_pack_PPOINT(void)
Definition: generated.c:6744
static void test_pack_PRLIST_ENTRY(void)
Definition: generated.c:5906
static void test_pack_INT32(void)
Definition: generated.c:3532
static void test_pack_SECURITY_DESCRIPTOR_CONTROL(void)
Definition: generated.c:6259
static void test_pack_PIMAGE_NT_HEADERS64(void)
Definition: generated.c:5613
static void test_pack_PIMAGE_DOS_HEADER(void)
Definition: generated.c:5531
static void test_pack_WAITORTIMERCALLBACKFUNC(void)
Definition: generated.c:6509
static void test_pack_TOKEN_PRIVILEGES(void)
Definition: generated.c:6446
static void test_pack_UINT16(void)
Definition: generated.c:3610
static void test_pack_PMESSAGE_RESOURCE_DATA(void)
Definition: generated.c:5847
static void test_pack_LOCALHANDLE(void)
Definition: generated.c:6636
static void test_pack_PSID_IDENTIFIER_AUTHORITY(void)
Definition: generated.c:5977
static void test_pack_LPCRECTL(void)
Definition: generated.c:6659
static void test_pack_LONG64(void)
Definition: generated.c:3572
static void test_pack_HRESULT(void)
Definition: generated.c:3899
static void test_pack_PTOKEN_USER(void)
Definition: generated.c:6040
static void test_pack_PIMAGE_VXD_HEADER(void)
Definition: generated.c:5750
static void test_pack_PIO_COUNTERS(void)
Definition: generated.c:5759
static void test_pack_SSIZE_T(void)
Definition: generated.c:3595
static void test_pack_IMAGE_SYMBOL(void)
Definition: generated.c:4867
static void test_pack_PTOKEN_PRIVILEGES(void)
Definition: generated.c:6031
static void test_pack_PRTL_RESOURCE_DEBUG(void)
Definition: generated.c:5949
static void test_pack_PIMAGE_COFF_SYMBOLS_HEADER(void)
Definition: generated.c:5495
static void test_pack_PEXCEPTION_POINTERS(void)
Definition: generated.c:5407
static void test_pack_HCURSOR(void)
Definition: generated.c:6585
static void test_pack_SID_IDENTIFIER_AUTHORITY(void)
Definition: generated.c:6351
static void test_pack_LARGE_INTEGER(void)
Definition: generated.c:5127
static void test_pack_PLIST_ENTRY(void)
Definition: generated.c:5802
static void test_pack_IMAGE_DATA_DIRECTORY(void)
Definition: generated.c:4015
static void test_pack_PRTL_OSVERSIONINFOW(void)
Definition: generated.c:5940
static void test_pack_PRECT(void)
Definition: generated.c:6762
static void test_pack_SIZEL(void)
Definition: generated.c:6854
static void test_pack_HLOCAL(void)
Definition: generated.c:6614
static void test_pack_IMAGE_FILE_HEADER(void)
Definition: generated.c:4185
static void test_pack_IMAGE_RESOURCE_DATA_ENTRY(void)
Definition: generated.c:4738
static void test_pack_LPPOINT(void)
Definition: generated.c:6675
static void test_pack_NT_TIB(void)
Definition: generated.c:5268
static void test_pack_USHORT(void)
Definition: generated.c:6885
static void test_pack_PIMAGE_ARCHIVE_MEMBER_HEADER(void)
Definition: generated.c:5452
static void test_pack_ACL_SIZE_INFORMATION(void)
Definition: generated.c:3762
static void test_pack_LONG(void)
Definition: generated.c:5153
static void test_pack_WORD(void)
Definition: generated.c:6893
static void test_pack_PSECURITY_DESCRIPTOR(void)
Definition: generated.c:5956
static void test_pack_LPARAM(void)
Definition: generated.c:6643
static void test_pack_IMAGE_IMPORT_BY_NAME(void)
Definition: generated.c:4229
static void test_pack_PROC(void)
Definition: generated.c:6780
static void test_pack_ACL(void)
Definition: generated.c:3730
static void test_pack_LPSIZE(void)
Definition: generated.c:6702
static void test_pack_TOKEN_PRIMARY_GROUP(void)
Definition: generated.c:6436
static void test_pack_IMAGE_LINENUMBER(void)
Definition: generated.c:4247
static void test_pack_LRESULT(void)
Definition: generated.c:6711
static void test_pack_LUID(void)
Definition: generated.c:5169
static void test_pack_FLOAT(void)
Definition: generated.c:6571
static void test_pack_DWORD64(void)
Definition: generated.c:3501
static void test_pack_PRIVILEGE_SET(void)
Definition: generated.c:5890
static void test_pack_DWORDLONG(void)
Definition: generated.c:3800
static void test_pack_ACL_REVISION_INFORMATION(void)
Definition: generated.c:3752
static void test_pack_UCHAR(void)
Definition: generated.c:6861
static void test_pack_ULARGE_INTEGER(void)
Definition: generated.c:6496
static void test_pack_INT_PTR(void)
Definition: generated.c:3556
static void test_pack_PMESSAGE_RESOURCE_BLOCK(void)
Definition: generated.c:5838
static void test_pack_LPCRECT(void)
Definition: generated.c:6650
static void test_pack_DWORD(void)
Definition: generated.c:6556
static void test_pack_MEMORY_BASIC_INFORMATION(void)
Definition: generated.c:5195
static void test_pack_RECT(void)
Definition: generated.c:6803
static void test_pack_IMAGE_LOAD_CONFIG_DIRECTORY64(void)
Definition: generated.c:4326
static void test_pack_PSECURITY_QUALITY_OF_SERVICE(void)
Definition: generated.c:5963
static void test_pack_PHANDLE(void)
Definition: generated.c:5443
static void test_pack_SINGLE_LIST_ENTRY(void)
Definition: generated.c:6361
static void test_pack_ULONG(void)
Definition: generated.c:6877
static void test_pack_GLOBALHANDLE(void)
Definition: generated.c:6578
static void test_pack_IMAGE_FUNCTION_ENTRY(void)
Definition: generated.c:4213
static void test_pack_IMAGE_EXPORT_DIRECTORY(void)
Definition: generated.c:4145
static void test_pack_IMAGE_SEPARATE_DEBUG_HEADER(void)
Definition: generated.c:4821
static void test_pack_SYSTEM_AUDIT_ACE(void)
Definition: generated.c:6387
#define TEST_TYPE_UNSIGNED(type)
Definition: generated.c:71
static void test_pack_HFILE(void)
Definition: generated.c:6592
static void test_pack_UINT32(void)
Definition: generated.c:3618
static void test_pack_RECTL(void)
Definition: generated.c:6822
static void test_pack_PPOINTL(void)
Definition: generated.c:6753
#define TEST_TYPE_SIGNED(type)
Definition: generated.c:70
static void test_pack_PIMAGE_BOUND_FORWARDER_REF(void)
Definition: generated.c:5477
static void test_pack_UINT64(void)
Definition: generated.c:3626
static void test_pack_SECURITY_DESCRIPTOR_RELATIVE(void)
Definition: generated.c:6267
static void test_pack_SID_AND_ATTRIBUTES(void)
Definition: generated.c:6338
static void test_pack_WPARAM(void)
Definition: generated.c:6901
static void test_pack_EXCEPTION_RECORD(void)
Definition: generated.c:3821
static void test_pack_PLUID_AND_ATTRIBUTES(void)
Definition: generated.c:5820
static void test_pack_IO_COUNTERS(void)
Definition: generated.c:5094
static void test_pack_PCWSTR(void)
Definition: generated.c:5398
static void test_pack_PIMAGE_NT_HEADERS32(void)
Definition: generated.c:5604
static void test_pack_LONGLONG(void)
Definition: generated.c:5161
static void test_pack_IMAGE_LOAD_CONFIG_DIRECTORY32(void)
Definition: generated.c:4259
static void test_pack_PRECTL(void)
Definition: generated.c:6771
static void test_pack_PISECURITY_DESCRIPTOR_RELATIVE(void)
Definition: generated.c:5777
static void test_pack_PISECURITY_DESCRIPTOR(void)
Definition: generated.c:5768
static void test_pack_IMAGE_TLS_DIRECTORY(void)
Definition: generated.c:4877
static void test_pack_PIMAGE_IMPORT_BY_NAME(void)
Definition: generated.c:5567
static void test_pack_PIMAGE_RESOURCE_DIRECTORY_STRING(void)
Definition: generated.c:5688
static void test_pack_ACCESS_ALLOWED_ACE(void)
Definition: generated.c:3674
static void test_pack_PIMAGE_DATA_DIRECTORY(void)
Definition: generated.c:5504
static void test_pack_SID(void)
Definition: generated.c:6319
static void test_pack_RTL_CRITICAL_SECTION(void)
Definition: generated.c:6088
static void test_pack_PACL_SIZE_INFORMATION(void)
Definition: generated.c:5353
static void test_pack_PTOKEN_GROUPS(void)
Definition: generated.c:6022
static void test_pack_UINT(void)
Definition: generated.c:6869
static void test_pack_RTL_CRITICAL_SECTION_DEBUG(void)
Definition: generated.c:6113
static void test_pack_LUID_AND_ATTRIBUTES(void)
Definition: generated.c:5182
static void test_pack_WCHAR(void)
Definition: generated.c:6516
static void test_pack_PIMAGE_NT_HEADERS(void)
Definition: generated.c:5597
static void test_pack_PIMAGE_OPTIONAL_HEADER(void)
Definition: generated.c:5622
static void test_pack_UHALF_PTR(void)
Definition: generated.c:3602
static void test_pack_POINT(void)
Definition: generated.c:6718
static void test_pack_PIMAGE_DEBUG_DIRECTORY(void)
Definition: generated.c:5513
static void test_pack_ULONGLONG(void)
Definition: generated.c:6501
static void test_pack_PIMAGE_IMPORT_DESCRIPTOR(void)
Definition: generated.c:5576
static void test_pack_UINT8(void)
Definition: generated.c:3634
static void test_pack_PIMAGE_OPTIONAL_HEADER32(void)
Definition: generated.c:5629
static void test_pack_LPCVOID(void)
Definition: generated.c:6668
static void test_pack_EXCEPTION_POINTERS(void)
Definition: generated.c:3808
static void test_pack_IMAGE_IMPORT_DESCRIPTOR(void)
Definition: generated.c:4242
static void test_pack_POBJECT_TYPE_LIST(void)
Definition: generated.c:5872
static void test_pack_SHORT(void)
Definition: generated.c:6311
static void test_pack_PRTL_CRITICAL_SECTION_DEBUG(void)
Definition: generated.c:5924
static void test_pack_PIMAGE_LOAD_CONFIG_DIRECTORY(void)
Definition: generated.c:5590
static void test_pack_PIMAGE_RELOCATION(void)
Definition: generated.c:5656
static void test_pack_PACCESS_DENIED_ACE(void)
Definition: generated.c:5310
static void test_pack_ACCESS_MASK(void)
Definition: generated.c:3706
static void test_pack_PIMAGE_SEPARATE_DEBUG_HEADER(void)
Definition: generated.c:5713
static void test_pack_MESSAGE_RESOURCE_DATA(void)
Definition: generated.c:5239
static void test_pack_SECURITY_CONTEXT_TRACKING_MODE(void)
Definition: generated.c:6224
static void test_pack_PLUID(void)
Definition: generated.c:5811
static void test_pack_PIMAGE_SYMBOL(void)
Definition: generated.c:5722
static void test_pack_ACE_HEADER(void)
Definition: generated.c:3714
static void test_pack_LONG_PTR(void)
Definition: generated.c:3580
static void test_pack_SECURITY_INFORMATION(void)
Definition: generated.c:6295
static void test_pack_PIMAGE_DEBUG_MISC(void)
Definition: generated.c:5522
static void test_pack_PGENERIC_MAPPING(void)
Definition: generated.c:5434
static void test_pack_COLORREF(void)
Definition: generated.c:6548
static void test_pack_PVOID(void)
Definition: generated.c:6063
static void test_pack_HGLOBAL(void)
Definition: generated.c:6607
static void test_pack_PSINGLE_LIST_ENTRY(void)
Definition: generated.c:5986
static void test_pack_PCCH(void)
Definition: generated.c:5362
static void test_pack_EXECUTION_STATE(void)
Definition: generated.c:3846
static void test_pack_TOKEN_OWNER(void)
Definition: generated.c:6426
static void test_pack_PVECTORED_EXCEPTION_HANDLER(void)
Definition: generated.c:6056
static void test_pack_TOKEN_SOURCE(void)
Definition: generated.c:6459
static void test_pack_SECURITY_DESCRIPTOR(void)
Definition: generated.c:6231
static void test_pack_FARPROC(void)
Definition: generated.c:6564
static void test_pack_MESSAGE_RESOURCE_BLOCK(void)
Definition: generated.c:5223
static void test_pack_IMAGE_OS2_HEADER(void)
Definition: generated.c:4636
static void test_pack_INT16(void)
Definition: generated.c:3524
static void test_pack_PIMAGE_RESOURCE_DIRECTORY_ENTRY(void)
Definition: generated.c:5681
static void test_pack_IMAGE_RESOURCE_DIR_STRING_U(void)
Definition: generated.c:4800
static void test_pack_PNT_TIB(void)
Definition: generated.c:5865
static void test_pack_IMAGE_THUNK_DATA(void)
Definition: generated.c:4872
static void test_pack_PSID(void)
Definition: generated.c:5970
static void test_pack_PACCESS_TOKEN(void)
Definition: generated.c:5319
static void test_pack_PPRIVILEGE_SET(void)
Definition: generated.c:5881
static void test_pack_CHAR(void)
Definition: generated.c:3793
static void test_pack_BOOLEAN(void)
Definition: generated.c:3778
static void test_pack_TOKEN_GROUPS(void)
Definition: generated.c:6413
static void test_pack_PIMAGE_BASE_RELOCATION(void)
Definition: generated.c:5468
static void test_pack_PWSTR(void)
Definition: generated.c:6079
static void test_pack_PRTL_OSVERSIONINFOEXW(void)
Definition: generated.c:5931
static void test_pack_IMAGE_DEBUG_DIRECTORY(void)
Definition: generated.c:4028
static void test_pack_MESSAGE_RESOURCE_ENTRY(void)
Definition: generated.c:5252
static void test_pack_IMAGE_OPTIONAL_HEADER(void)
Definition: generated.c:4432
static void test_pack_RTL_RESOURCE_DEBUG(void)
Definition: generated.c:6201
static void test_pack_PCH(void)
Definition: generated.c:5371
static void test_pack_LPRECT(void)
Definition: generated.c:6684
static void test_pack_IMAGE_LOAD_CONFIG_DIRECTORY(void)
Definition: generated.c:4252
static void test_pack_UINT_PTR(void)
Definition: generated.c:3642
static void test_pack_PACL_REVISION_INFORMATION(void)
Definition: generated.c:5344
static void test_pack_IMAGE_ARCHIVE_MEMBER_HEADER(void)
Definition: generated.c:3906
static void test_pack_DWORD32(void)
Definition: generated.c:3493
static void test_pack_PMESSAGE_RESOURCE_ENTRY(void)
Definition: generated.c:5856
static void test_pack_ULONG32(void)
Definition: generated.c:3650
static void test_pack_DWORD_PTR(void)
Definition: generated.c:3509
static void test_pack_SIZE_T(void)
Definition: generated.c:3588
static void test_pack_HANDLE(void)
Definition: generated.c:3892
static void test_pack_LANGID(void)
Definition: generated.c:5119
static void test_pack_PMEMORY_BASIC_INFORMATION(void)
Definition: generated.c:5829
static void test_pack_PRTL_CRITICAL_SECTION(void)
Definition: generated.c:5915
static void test_pack_IMAGE_NT_HEADERS64(void)
Definition: generated.c:4416
static void test_pack_IMAGE_OPTIONAL_HEADER64(void)
Definition: generated.c:4539
static void test_pack_PIMAGE_FILE_HEADER(void)
Definition: generated.c:5549
static void test_pack_PULARGE_INTEGER(void)
Definition: generated.c:6049
static void test_pack_SECURITY_QUALITY_OF_SERVICE(void)
Definition: generated.c:6303
static void test_pack_PIMAGE_AUX_SYMBOL(void)
Definition: generated.c:5461
static void test_pack_BOOL(void)
Definition: generated.c:6532
static void test_pack_PCWCH(void)
Definition: generated.c:5389
VOID(NTAPI * PIMAGE_TLS_CALLBACK)(PVOID DllHandle, ULONG Reason, PVOID Reserved)
Definition: ntimage.h:531
PVOID *typedef PHANDLE
Definition: ntsecpkg.h:455
struct _IMAGE_RELOCATION UNALIGNED * PIMAGE_RELOCATION
Definition: pecoff.h:239
struct _IMAGE_SYMBOL UNALIGNED * PIMAGE_SYMBOL
Definition: pecoff.h:258
short SHORT
Definition: pedump.c:59
long LONG
Definition: pedump.c:60
unsigned short USHORT
Definition: pedump.c:61
_Out_opt_ int _Out_opt_ int * cy
Definition: commctrl.h:586
_Out_opt_ int * cx
Definition: commctrl.h:585
DWORD LCID
Definition: nls.h:13
DataType
Definition: simd.h:252
Definition: winnt_old.h:3598
Definition: pedump.c:458
Definition: pedump.c:414
Definition: typedefs.h:120
Definition: rtltypes.h:1896
Definition: windef.h:314
Definition: ntbasedef.h:628
uint16_t * PWSTR
Definition: typedefs.h:56
int32_t INT_PTR
Definition: typedefs.h:64
char * PSTR
Definition: typedefs.h:51
const uint16_t * PCWSTR
Definition: typedefs.h:57
int64_t LONG64
Definition: typedefs.h:68
uint32_t DWORD_PTR
Definition: typedefs.h:65
uint64_t DWORD64
Definition: typedefs.h:67
float FLOAT
Definition: typedefs.h:69
int64_t LONGLONG
Definition: typedefs.h:68
ULONG_PTR SIZE_T
Definition: typedefs.h:80
int32_t INT
Definition: typedefs.h:58
const char * PCSTR
Definition: typedefs.h:52
uint32_t ULONG_PTR
Definition: typedefs.h:65
uint32_t ULONG
Definition: typedefs.h:59
uint64_t ULONGLONG
Definition: typedefs.h:67
char CCHAR
Definition: typedefs.h:51
BOOL Privilege(LPTSTR pszPrivilege, BOOL bEnable)
Definition: user_lib.cpp:531
_Must_inspect_result_ _In_ WDFDMAENABLER _In_ _In_opt_ PWDF_OBJECT_ATTRIBUTES Attributes
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_DEVICE_PROPERTY_DATA _In_ DEVPROPTYPE _In_ ULONG Size
Definition: wdfdevice.h:4533
_Must_inspect_result_ _In_ WDFDMATRANSACTION _In_ PFN_WDF_PROGRAM_DMA _In_ WDF_DMA_DIRECTION _In_ PMDL _In_ PVOID VirtualAddress
_Must_inspect_result_ _In_ WDFKEY _In_ PCUNICODE_STRING _Out_opt_ PUSHORT _Inout_opt_ PUNICODE_STRING Value
Definition: wdfregistry.h:413
_In_ WDF_WMI_PROVIDER_CONTROL Control
Definition: wdfwmi.h:166
_Reserved_ PVOID Reserved
Definition: winddi.h:3974
LONG_PTR LPARAM
Definition: windef.h:208
LONG_PTR LRESULT
Definition: windef.h:209
UINT_PTR WPARAM
Definition: windef.h:207
DWORD COLORREF
Definition: windef.h:300
int HFILE
Definition: windef.h:298
CONST void * LPCVOID
Definition: windef.h:191
char * PSZ
Definition: windef.h:57
HICON HCURSOR
Definition: windef.h:299
_IRQL_requires_same_ typedef _In_ ULONG _In_ UCHAR Level
Definition: wmitypes.h:56
_In_ USHORT _In_ ULONG _In_ PSOCKADDR _In_ PSOCKADDR _Reserved_ ULONG _In_opt_ PVOID _In_opt_ const WSK_CLIENT_CONNECTION_DISPATCH _In_opt_ PEPROCESS _In_opt_ PETHREAD OwningThread
Definition: wsk.h:190
_Must_inspect_result_ _In_ ULONG Flags
Definition: wsk.h:170
ULONG EXECUTION_STATE
Definition: potypes.h:213
_In_ ULONG _In_ ULONG AclRevision
Definition: rtlfuncs.h:1857
_In_ PSECURITY_SUBJECT_CONTEXT _In_ BOOLEAN _In_ ACCESS_MASK _In_ ACCESS_MASK _Outptr_opt_ PPRIVILEGE_SET * Privileges
Definition: sefuncs.h:17
* PSID_IDENTIFIER_AUTHORITY
Definition: setypes.h:464
unsigned char UCHAR
Definition: xmlstorage.h:181
__wchar_t WCHAR
Definition: xmlstorage.h:180
char CHAR
Definition: xmlstorage.h:175
unsigned char BYTE
Definition: xxhash.c:193
_In_ HANDLE _Outptr_result_bytebuffer_ ViewSize PVOID _In_ ULONG_PTR _In_ SIZE_T _Inout_opt_ PLARGE_INTEGER _Inout_ PSIZE_T _In_ SECTION_INHERIT _In_ ULONG _In_ ULONG Protect
Definition: zwfuncs.h:221