filter out sqlite3 error about already created buddies table. do not log XML by default
This commit is contained in:
parent
ae29c8c902
commit
fcd00635e9
2 changed files with 4 additions and 1 deletions
|
@ -9,3 +9,6 @@ log4j.appender.R.MaxBackupIndex=1
|
|||
|
||||
log4j.appender.R.layout=org.apache.log4j.PatternLayout
|
||||
log4j.appender.R.layout.ConversionPattern=%d %-5p %c: %m%n
|
||||
|
||||
# Disable XML category
|
||||
log4j.category.Component.XML = OFF
|
||||
|
|
|
@ -208,7 +208,7 @@ bool SQLite3Backend::exec(const std::string &query) {
|
|||
if (rc != SQLITE_OK) {
|
||||
// This error is OK, because we try to create buddies table every time
|
||||
// to detect if DB is created properly.
|
||||
if (errMsg != "table buddies already exists") {
|
||||
if (errMsg && std::string(errMsg).find("table buddies already exists") == std::string::npos) {
|
||||
LOG4CXX_ERROR(logger, errMsg << " during statement " << query);
|
||||
}
|
||||
sqlite3_free(errMsg);
|
||||
|
|
Loading…
Add table
Reference in a new issue