1
0
mirror of https://github.com/qTox/qTox.git synced 2024-03-22 14:00:36 +08:00

refactor: Comply with Wmissing-field-initializers

Add explicit missing initializers.
This commit is contained in:
Anthony Bilinski 2022-03-10 23:57:45 -08:00
parent 809c695718
commit 02d5270dcc
No known key found for this signature in database
GPG Key ID: 2AA8E0DA1B31FB3C
2 changed files with 3 additions and 3 deletions

View File

@ -382,7 +382,7 @@ void ChatHistory::loadHistoryIntoSessionChatLog(ChatLogIdx start) const
// we hit IMessageDispatcher's signals which history listens for.
// Items added to history have already been sent so we know they already
// reflect what was sent/received.
auto processedMessage = Message{isAction, messageContent, message.timestamp};
auto processedMessage = Message{isAction, messageContent, message.timestamp, {}, {}};
auto dispatchedMessageIt =
std::find_if(dispatchedMessageRowIdMap.begin(), dispatchedMessageRowIdMap.end(),

View File

@ -43,7 +43,7 @@ void TestOfflineMsgEngine::testReceiptBeforeMessage()
{
OfflineMsgEngine offlineMsgEngine;
Message msg{false, QString(), QDateTime()};
Message msg{false, QString(), QDateTime(), {}, {}};
auto const receipt = ReceiptNum(0);
offlineMsgEngine.onReceiptReceived(receipt);
@ -140,7 +140,7 @@ void TestOfflineMsgEngine::testCallback()
size_t numCallbacks = 0;
auto callback = [&numCallbacks] (bool) { numCallbacks++; };
Message msg{false, QString(), QDateTime()};
Message msg{false, QString(), QDateTime(), {}, {}};
ReceiptNum receipt;
offlineMsgEngine.addSentCoreMessage(ReceiptNum(1), Message(), callback);