Class for simplification of heap using:
| 127 | |
| 128 | // Class for simplification of heap using: |
| 129 | class HeapObject final { |
| 130 | private: |
| 131 | PVOID HeapHandle; |
| 132 | public: |
| 133 | _IRQL_requires_max_(APC_LEVEL) |
| 134 | HeapObject(); |
| 135 | |
| 136 | _IRQL_requires_max_(APC_LEVEL) |
| 137 | ~HeapObject(); |
| 138 | |
| 139 | BOOLEAN IsHeapValid() const; |
| 140 | |
| 141 | _IRQL_requires_max_(APC_LEVEL) |
| 142 | PVOID Alloc(SIZE_T Size, BOOLEAN ZeroMemory = TRUE) const; |
| 143 | |
| 144 | _IRQL_requires_max_(APC_LEVEL) |
| 145 | VOID Free(PVOID Address) const; |
| 146 | |
| 147 | _IRQL_requires_max_(APC_LEVEL) |
| 148 | LPSTR AllocAnsiString(SIZE_T Characters) const; |
| 149 | |
| 150 | _IRQL_requires_max_(APC_LEVEL) |
| 151 | LPWSTR AllocWideString(SIZE_T Characters) const; |
| 152 | |
| 153 | _IRQL_requires_max_(APC_LEVEL) |
| 154 | PVOID AllocArray(SIZE_T ElementSize, SIZE_T ElementsCount) const; |
| 155 | }; |
| 156 | } |
| 157 | |
| 158 | namespace PhysicalMemory { |
nothing calls this directly
no outgoing calls
no test coverage detected