1
0
mirror of https://github.com/MariaDB/server.git synced 2025-11-30 05:23:50 +03:00
Files
mariadb/cxx/db.cpp
Bradley C. Kuszmaul 89e92ad386 More fiddling around with c++. Addresses #197.
git-svn-id: file:///svn/tokudb@1179 c7de825b-a66e-492c-adef-691d508d4ae1
2007-12-18 01:52:52 +00:00

23 lines
437 B
C++

#include "db_cxx.h"
Db::~Db() {
if (!the_db) {
close(0); // the user should have called close, but we do it here if not done.
}
}
int Db::close (u_int32_t flags) {
if (!the_db) {
return EINVAL;
}
the_db->toku_internal = 0;
int ret = the_db->close(flags);
the_db = 0;
// Do we need to clean up "private environments"?
// What about cursors? They should be cleaned up already.
return ret;
}