allocPool: Add destructor which cleans up.
This commit is contained in:
parent
6cd26d5ee9
commit
9f68be78db
@ -24,6 +24,11 @@ public:
|
||||
initArray(defaultAllocNumbers);
|
||||
}
|
||||
|
||||
~allocPool() {
|
||||
for (auto i: vec)
|
||||
delete i;
|
||||
}
|
||||
|
||||
T *getPtr() {
|
||||
if (pivot == 0)
|
||||
resizeVec();
|
||||
|
Loading…
Reference in New Issue
Block a user