summaryrefslogtreecommitdiff
path: root/src/Lists.cpp
diff options
context:
space:
mode:
authoraap <aap@papnet.eu>2019-05-15 16:52:37 +0200
committeraap <aap@papnet.eu>2019-05-15 16:52:37 +0200
commit600bf0351476a5a21aabb5429132ddf7f52ac0b9 (patch)
treed8e48b3a581679e33830fb7c98ed69e1e242e2c2 /src/Lists.cpp
first commit
Diffstat (limited to 'src/Lists.cpp')
-rw-r--r--src/Lists.cpp26
1 files changed, 26 insertions, 0 deletions
diff --git a/src/Lists.cpp b/src/Lists.cpp
new file mode 100644
index 00000000..448a0ff1
--- /dev/null
+++ b/src/Lists.cpp
@@ -0,0 +1,26 @@
+#include "common.h"
+#include "Pools.h"
+#include "Lists.h"
+
+void*
+CPtrNode::operator new(size_t){
+ CPtrNode *node = CPools::GetPtrNodePool()->New();
+ assert(node);
+ return node;
+}
+
+void
+CPtrNode::operator delete(void *p, size_t){
+ CPools::GetPtrNodePool()->Delete((CPtrNode*)p);
+}
+
+void*
+CEntryInfoNode::operator new(size_t){
+ CEntryInfoNode *node = CPools::GetEntryInfoNodePool()->New();
+ assert(node);
+ return node;
+}
+void
+CEntryInfoNode::operator delete(void *p, size_t){
+ CPools::GetEntryInfoNodePool()->Delete((CEntryInfoNode*)p);
+}