38 SIZE_T OldSize = *OldSizePtr;
47 skip(
"RtlReAllocateHeap failed for size %lu (%s)\n",
Size,
Action);
54 ok(
CheckBuffer(NewBuffer, OldSize, 0x7a),
"CheckBuffer failed at size 0x%lx -> 0x%lx\n", OldSize,
Size);
55 ok(
CheckBuffer(NewBuffer + OldSize,
Size - OldSize, 0),
"HEAP_ZERO_MEMORY not respected for 0x%lx -> 0x%lx\n", OldSize,
Size);
81 ok(
Buffer ==
NULL,
"RtlReAllocateHeap succeeded for NULL\n");
90 skip(
"RtlAllocateHeap failed for size %lu\n", OldSize);
95 for (
Size = 0x78000;
Size < 0x90000 && Continue;
Size += 0x100)
101 for (
Size -= 0x100;
Size >= 0x78000 && Continue;
Size -= 0x100)
114 skip(
"RtlAllocateHeap failed for size %lu\n", OldSize);
119 UserFlags = 0x55555555;
126 ok(UserValue ==
NULL,
"UserValue = %p\n", UserValue);
143 UserFlags = 0x55555555;
150 ok(UserValue == &UserValue,
"UserValue = %p, expected %p\n", UserValue, &UserValue);
158 ok(Buffer2 ==
Buffer,
"New Buffer is %p, expected %p\n", Buffer2,
Buffer);
159 if (Buffer2)
Buffer = Buffer2;
161 UserFlags = 0x55555555;
168 ok(UserValue == &UserValue,
"UserValue = %p, expected %p\n", UserValue, &UserValue);
176 ok(Buffer2 ==
Buffer,
"New Buffer is %p, expected %p\n", Buffer2,
Buffer);
177 if (Buffer2)
Buffer = Buffer2;
179 UserFlags = 0x55555555;
186 ok(UserValue == &UserValue,
"UserValue = %p, expected %p\n", UserValue, &UserValue);
static BOOLEAN ReAllocBuffer(PUCHAR *Buffer, SIZE_T Size, SIZE_T *OldSizePtr, PCSTR Action)
static BOOLEAN CheckBuffer(PVOID Buffer, SIZE_T Size, UCHAR Value)
#define ok_hex(expression, result)
PVOID NTAPI RtlAllocateHeap(IN PVOID HeapHandle, IN ULONG Flags, IN SIZE_T Size)
BOOLEAN NTAPI RtlFreeHeap(IN PVOID HeapHandle, IN ULONG Flags, IN PVOID HeapBase)
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
#define RtlFillMemory(Dest, Length, Fill)
NTSYSAPI PVOID WINAPI RtlReAllocateHeap(HANDLE, ULONG, PVOID, SIZE_T)
NTSYSAPI SIZE_T NTAPI RtlSizeHeap(_In_ PVOID HeapHandle, _In_ ULONG Flags, _In_ PVOID MemoryPointer)
#define HEAP_SETTABLE_USER_FLAG2
#define HEAP_SETTABLE_USER_FLAG1
#define HEAP_SETTABLE_USER_FLAG3
#define HEAP_SETTABLE_USER_VALUE
#define HEAP_REALLOC_IN_PLACE_ONLY
BOOLEAN NTAPI RtlGetUserInfoHeap(IN PVOID HeapHandle, IN ULONG Flags, IN PVOID BaseAddress, OUT PVOID *UserValue, OUT PULONG UserFlags)
BOOLEAN NTAPI RtlSetUserFlagsHeap(IN PVOID HeapHandle, IN ULONG Flags, IN PVOID BaseAddress, IN ULONG UserFlagsReset, IN ULONG UserFlagsSet)
BOOLEAN NTAPI RtlSetUserValueHeap(IN PVOID HeapHandle, IN ULONG Flags, IN PVOID BaseAddress, IN PVOID UserValue)
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_DEVICE_PROPERTY_DATA _In_ DEVPROPTYPE _In_ ULONG Size
_In_ WDFIOTARGET _In_ _Strict_type_match_ WDF_IO_TARGET_SENT_IO_ACTION Action
_Must_inspect_result_ _In_ WDFKEY _In_ PCUNICODE_STRING _Out_opt_ PUSHORT _Inout_opt_ PUNICODE_STRING Value