diff --git a/diskTreeComponent.cpp b/diskTreeComponent.cpp index 09c34a2..90539a5 100644 --- a/diskTreeComponent.cpp +++ b/diskTreeComponent.cpp @@ -357,6 +357,10 @@ diskTreeComponent::internalNodes::internalNodes(int xid, recordid root, recordid datapage_alloc(new RegionAllocator(xid, datapage_state)) { } +diskTreeComponent::internalNodes::~internalNodes() { + delete internal_node_alloc; + delete datapage_alloc; +} /* adding pages: diff --git a/diskTreeComponent.h b/diskTreeComponent.h index 54c16a6..df237e7 100644 --- a/diskTreeComponent.h +++ b/diskTreeComponent.h @@ -81,7 +81,7 @@ class diskTreeComponent { internalNodes(int xid, pageid_t internal_region_size, pageid_t datapage_region_size, pageid_t datapage_size); internalNodes(int xid, recordid root, recordid internal_node_state, recordid datapage_state); - + ~internalNodes(); void print_tree(int xid); //returns the id of the data page that could contain the given key