summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authorCH Chethan Reddy <40890937+Chethan2k1@users.noreply.github.com>2020-05-15 16:33:51 +0530
committerChethan2k1 <40890937+Chethan2k1@users.noreply.github.com>2020-05-15 17:48:27 +0530
commite4a7e859354653d4ddd60dc9e2b83132feffaceb (patch)
tree32c1e5ae4abab29a4b626446a1bfcceb19d67259 /src
parentminor fixes (diff)
downloadnheko-e4a7e859354653d4ddd60dc9e2b83132feffaceb.tar.xz
Change the commit hash for mtxclient
Diffstat (limited to 'src')
-rw-r--r--src/ChatPage.cpp2
-rw-r--r--src/Olm.cpp13
2 files changed, 9 insertions, 6 deletions
diff --git a/src/ChatPage.cpp b/src/ChatPage.cpp

index 5450cdfa..d0ca4670 100644 --- a/src/ChatPage.cpp +++ b/src/ChatPage.cpp
@@ -1010,7 +1010,7 @@ ChatPage::trySync() // TODO: fine grained error handling try { - cache::saveState(res); + cache::saveState(res); olm::handle_to_device_messages(res.to_device.events); auto updates = cache::roomUpdates(res); diff --git a/src/Olm.cpp b/src/Olm.cpp
index 1f87b3f9..2c4f6186 100644 --- a/src/Olm.cpp +++ b/src/Olm.cpp
@@ -32,7 +32,7 @@ handle_to_device_messages(const std::vector<mtx::events::collections::DeviceEven nlohmann::json j_msg; for (const auto &msg : msgs) { - j_msg = std::visit([](auto &e){ return json(e); },std::move(msg)); + j_msg = std::visit([](auto &e) { return json(e); }, std::move(msg)); if (j_msg.count("type") == 0) { nhlog::crypto()->warn("received message with no type field: {}", j_msg.dump(2)); @@ -49,8 +49,9 @@ handle_to_device_messages(const std::vector<mtx::events::collections::DeviceEven nhlog::crypto()->warn( "parsing error for olm message: {} {}", e.what(), j_msg.dump(2)); } catch (const std::invalid_argument &e) { - nhlog::crypto()->warn( - "validation error for olm message: {} {}", e.what(), j_msg.dump(2)); + nhlog::crypto()->warn("validation error for olm message: {} {}", + e.what(), + j_msg.dump(2)); } } else if (msg_type == to_string(mtx::events::EventType::RoomKeyRequest)) { @@ -364,7 +365,8 @@ handle_key_request_message(const mtx::events::DeviceEvent<mtx::events::msg::KeyR // Check if we have the keys for the requested session. if (!cache::outboundMegolmSessionExists(req.content.room_id)) { - nhlog::crypto()->warn("requested session not found in room: {}", req.content.room_id); + nhlog::crypto()->warn("requested session not found in room: {}", + req.content.room_id); return; } @@ -387,7 +389,8 @@ handle_key_request_message(const mtx::events::DeviceEvent<mtx::events::msg::KeyR } if (!utils::respondsToKeyRequests(req.content.room_id)) { - nhlog::crypto()->debug("ignoring all key requests for room {}", req.content.room_id); + nhlog::crypto()->debug("ignoring all key requests for room {}", + req.content.room_id); return; }