mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-05-03 20:46:28 +00:00
Fix invalid cast when using MySQL as database backend.
This commit is contained in:
parent
25d05ede90
commit
87921f7376
1 changed files with 1 additions and 4 deletions
|
|
@ -2466,10 +2466,7 @@ list<shared_ptr<AbstractChatRoom>> MainDb::getChatRooms () const {
|
|||
soci::rowset<soci::row> rows = (session->prepare << query, soci::use(participantId));
|
||||
for (const auto &row : rows) {
|
||||
shared_ptr<ParticipantDevice> device = dParticipant->addDevice(IdentityAddress(row.get<string>(0)));
|
||||
device->setState(ParticipantDevice::State(getBackend() == Backend::Mysql
|
||||
? row.get<unsigned int>(1, 0)
|
||||
: static_cast<unsigned int>(row.get<int>(1, 0))
|
||||
));
|
||||
device->setState(ParticipantDevice::State(static_cast<unsigned int>(row.get<int>(1, 0))));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue