X-Git-Url: https://git.llucax.com/z.facultad/75.52/treemulator.git/blobdiff_plain/6a4238b2894a1cf20a5b8ccb0575f018ae25a5b3..aaa9a007ee4af6b40d2eefef15bccc51f92e17d9:/src/btree.cpp diff --git a/src/btree.cpp b/src/btree.cpp index adb0ae7..ae98139 100644 --- a/src/btree.cpp +++ b/src/btree.cpp @@ -52,7 +52,7 @@ void BTree::WriteBlock (uchar *block, uint num) void BTree::AddKey (const Clave &k) { uint left, right; - Clave *kout = AddKeyR (&k, 0, left, right); + Clave *kout = AddKeyR (k.Clone (), 0, left, right); if (kout) { unsigned short level; @@ -91,8 +91,6 @@ void BTree::AddKey (const Clave &k) delete [] node; DeleteKeys (node_keys); PrintNode (0); - - delete kout; } }