11{
12 HANDLE HeapArray[40] = {0};
14
15
17 ok(InitialNumHeaps > 0,
"Expected at least one heap\n");
18 ok(InitialNumHeaps < MaxHeapArraySize,
"Expected less heaps, got %lu\n", InitialNumHeaps);
19
20
23 for (
ULONG n = 0;
n <
min(NumHeaps, MaxHeapArraySize); ++
n)
24 {
25 ok(HeapArray[
n] !=
NULL,
"Heap[%lu] == NULL\n",
n);
26 }
27
29
30 memset(HeapArray, 0,
sizeof(HeapArray));
33 if (NumHeaps > 0 && NumHeaps <= MaxHeapArraySize)
34 {
35
36 ok_ptr(HeapArray[NumHeaps - 1], HeapPtr);
37 }
38
40
41
42 memset(HeapArray, 0xff,
sizeof(HeapArray));
45
46 ok_ptr(HeapArray[0], RtlGetProcessHeap());
48}
#define ok_eq_ulong(value, expected)
#define ok_ptr(expression, result)
#define INVALID_HANDLE_VALUE
NTSYSAPI ULONG WINAPI RtlGetProcessHeaps(ULONG, HANDLE *)
NTSYSAPI PVOID NTAPI RtlDestroyHeap(IN PVOID HeapHandle)
NTSYSAPI PVOID NTAPI RtlCreateHeap(IN ULONG Flags, IN PVOID HeapBase OPTIONAL, IN ULONG ReserveSize OPTIONAL, IN ULONG CommitSize OPTIONAL, IN PVOID Lock OPTIONAL, IN PRTL_HEAP_PARAMETERS Parameters OPTIONAL)