summaryrefslogtreecommitdiffhomepage
path: root/Public/Developer/System.Core/Sources/New+Delete.cxx
diff options
context:
space:
mode:
authorAmlal El Mahrouss <amlal@el-mahrouss-logic.com>2024-03-28 20:54:33 +0100
committerAmlal El Mahrouss <amlal@el-mahrouss-logic.com>2024-03-28 20:54:33 +0100
commitb2c7b8604ed3a4c209a15a9ffd718a43163dd9b4 (patch)
tree851d79e3a9b1c676b48ec8dfcd2b989f4da45c9b /Public/Developer/System.Core/Sources/New+Delete.cxx
parent215518ae55a54973a1ae18f572ca5bf0ac2a499e (diff)
NewKernel: Add PowerPC partition type inside EPM, add Leak() FileStream method. and documentation.
SystemLib: Start implementing the API. Signed-off-by: Amlal El Mahrouss <amlal@el-mahrouss-logic.com>
Diffstat (limited to 'Public/Developer/System.Core/Sources/New+Delete.cxx')
-rw-r--r--Public/Developer/System.Core/Sources/New+Delete.cxx13
1 files changed, 6 insertions, 7 deletions
diff --git a/Public/Developer/System.Core/Sources/New+Delete.cxx b/Public/Developer/System.Core/Sources/New+Delete.cxx
index 3e2942c5..0800da22 100644
--- a/Public/Developer/System.Core/Sources/New+Delete.cxx
+++ b/Public/Developer/System.Core/Sources/New+Delete.cxx
@@ -11,31 +11,30 @@ typedef SizeType size_t;
void* operator new[](size_t sz) {
if (sz == 0) ++sz;
- return RtAllocateProcessHeap(kApplicationObject, sz, kStandardAllocation);
+ return RtAllocateProcessPtr(sz, kStandardAllocation);
}
void* operator new(size_t sz) {
if (sz == 0) ++sz;
- return RtAllocateProcessHeap(kApplicationObject, sz, kArrayAllocation);
+ return RtAllocateProcessPtr(sz, kArrayAllocation);
}
void operator delete[](void* ptr) {
if (ptr == nullptr) return;
- RtFreeProcessHeap(kApplicationObject, ptr);
+ RtFreeProcessPtr(ptr);
}
void operator delete(void* ptr) {
if (ptr == nullptr) return;
- RtFreeProcessHeap(kApplicationObject, ptr);
+ RtFreeProcessPtr(ptr);
}
void operator delete(void* ptr, size_t sz) {
if (ptr == nullptr) return;
+ CA_UNREFERENCED_PARAMETER(sz);
- (void)sz;
-
- RtFreeProcessHeap(kApplicationObject, ptr);
+ RtFreeProcessPtr(ptr);
}