Mercurial > hg > orthanc
comparison Core/SQLite/StatementReference.cpp @ 3699:efa815dd2c20
additional logging
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Wed, 26 Feb 2020 12:19:34 +0100 |
parents | fa5ad4368fe3 |
children |
comparison
equal
deleted
inserted
replaced
3698:356ebef2cd95 | 3699:efa815dd2c20 |
---|---|
80 | 80 |
81 int error = sqlite3_prepare_v2(database, sql, -1, &statement_, NULL); | 81 int error = sqlite3_prepare_v2(database, sql, -1, &statement_, NULL); |
82 if (error != SQLITE_OK) | 82 if (error != SQLITE_OK) |
83 { | 83 { |
84 #if ORTHANC_SQLITE_STANDALONE != 1 | 84 #if ORTHANC_SQLITE_STANDALONE != 1 |
85 LOG(ERROR) << "SQLite: " << sqlite3_errmsg(database) | 85 int extended = sqlite3_extended_errcode(database); |
86 << " (" << sqlite3_extended_errcode(database) << ")"; | 86 LOG(ERROR) << "SQLite: " << sqlite3_errmsg(database) << " (" << extended << ")"; |
87 if (extended == SQLITE_IOERR_SHMSIZE /* 4874 */) | |
88 { | |
89 LOG(ERROR) << " This probably indicates that your filesystem is full"; | |
90 } | |
87 #endif | 91 #endif |
88 | 92 |
89 throw OrthancSQLiteException(ErrorCode_SQLitePrepareStatement); | 93 throw OrthancSQLiteException(ErrorCode_SQLitePrepareStatement); |
90 } | 94 } |
91 | 95 |