Use sqlite_errstr instead of sqlite3_errmsg

mpSQLite is free'd with sqlite3_close. It's no more accesible.
Fixes: #48
This commit is contained in:
Onur Aslan 2015-05-06 00:22:43 +03:00
parent 4f4c9aa918
commit e55fffefd7

View File

@ -74,7 +74,7 @@ Database::~Database() noexcept // nothrow
{ {
const int ret = sqlite3_close(mpSQLite); const int ret = sqlite3_close(mpSQLite);
// Never throw an exception in a destructor // Never throw an exception in a destructor
SQLITECPP_ASSERT(SQLITE_OK == ret, sqlite3_errmsg(mpSQLite)); // See SQLITECPP_ENABLE_ASSERT_HANDLER SQLITECPP_ASSERT(SQLITE_OK == ret, sqlite3_errstr(ret)); // See SQLITECPP_ENABLE_ASSERT_HANDLER
} }
/** /**