mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-01-21 04:58:14 +00:00
fix(main-db): add logs
This commit is contained in:
parent
c5ad52bd42
commit
42e2f7f6ef
2 changed files with 6 additions and 2 deletions
|
|
@ -1061,7 +1061,7 @@ MainDb::MainDb (Core *core) : AbstractDb(*new MainDbPrivate) {
|
|||
d->insertChatRoom(d->insertSipAddress(peerAddress), capabilities, Utils::getLongAsTm(0));
|
||||
}
|
||||
|
||||
void MainDb::deleteChatRoom (const std::string &peerAddress) {
|
||||
void MainDb::deleteChatRoom (const string &peerAddress) {
|
||||
L_D();
|
||||
|
||||
L_BEGIN_LOG_EXCEPTION
|
||||
|
|
|
|||
|
|
@ -22,6 +22,7 @@
|
|||
#endif // ifdef SOCI_ENABLED
|
||||
|
||||
#include "db-session-p.h"
|
||||
#include "logger/logger.h"
|
||||
#include "object/object-p.h"
|
||||
|
||||
#include "db-session-provider.h"
|
||||
|
|
@ -59,9 +60,12 @@ DbSession DbSessionProvider::getSession (const string &uri) {
|
|||
d->sessions[uri] = make_pair(backendSession, p);
|
||||
} else // Share session.
|
||||
session.setRef(*d->sessions[uri].second);
|
||||
} catch (const exception &) {}
|
||||
} catch (const exception &e) {
|
||||
lWarning() << "Unable to get db session: " << e.what();
|
||||
}
|
||||
#else
|
||||
DbSession session(DbSession::None);
|
||||
lWarning() << "Unable to get db session: soci not enabled.";
|
||||
#endif // ifdef SOCI_ENABLED
|
||||
|
||||
// Remove invalid weak ptrs.
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue