diff options
Diffstat (limited to 'src/crepe/DB.cpp')
-rw-r--r-- | src/crepe/DB.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/crepe/DB.cpp b/src/crepe/DB.cpp index b8448a7..b188637 100644 --- a/src/crepe/DB.cpp +++ b/src/crepe/DB.cpp @@ -7,7 +7,7 @@ using namespace std; using namespace crepe; -DB::DB(const char * path) { +DB::DB(const string & path) { dbg_trace(); int ret; @@ -18,7 +18,7 @@ DB::DB(const char * path) { this->db = { db, [] (libdb::DB * db) { db->close(db, 0); } }; // load or create database file - if ((ret = this->db->open(this->db.get(), NULL, path, NULL, libdb::DB_BTREE, DB_CREATE, 0)) != 0) { + if ((ret = this->db->open(this->db.get(), NULL, path.c_str(), NULL, libdb::DB_BTREE, DB_CREATE, 0)) != 0) { throw nullptr; } |