diff options
author | Konstantinos Sideris <sideris.konstantin@gmail.com> | 2018-07-08 21:24:44 +0300 |
---|---|---|
committer | Konstantinos Sideris <sideris.konstantin@gmail.com> | 2018-07-08 21:24:44 +0300 |
commit | 6d474b77f15eb3040d59580ebd70e52f297fd34a (patch) | |
tree | 89a665d607012faf37c44f5fd1b0fe234195174e /src | |
parent | 278eccc04086f3033c71a753f0fc0ab35a3cbb66 (diff) |
Fix variable shadowing that caused the key response to be null
Diffstat (limited to 'src')
-rw-r--r-- | src/Olm.cpp | 5 | ||||
-rw-r--r-- | src/timeline/TimelineView.cc | 2 |
2 files changed, 5 insertions, 2 deletions
diff --git a/src/Olm.cpp b/src/Olm.cpp index 67e375b5..cf54f4d4 100644 --- a/src/Olm.cpp +++ b/src/Olm.cpp @@ -494,7 +494,7 @@ send_megolm_key_to_device(const std::string &user_id, auto olm_session = olm::client()->create_outbound_session( pks.curve25519, device.begin()->at("key")); - auto device_msg = olm::client()->create_olm_encrypted_content( + device_msg = olm::client()->create_olm_encrypted_content( olm_session.get(), room_key, pks.curve25519); cache::client()->saveOlmSession(pks.curve25519, @@ -511,7 +511,8 @@ send_megolm_key_to_device(const std::string &user_id, body["messages"][user_id][device_id] = device_msg; - nhlog::net()->info("send_to_device: {}", user_id); + nhlog::net()->info( + "sending m.room_key event to {}:{}", user_id, device_id); http::v2::client()->send_to_device( "m.room.encrypted", body, [user_id](mtx::http::RequestErr err) { if (err) { diff --git a/src/timeline/TimelineView.cc b/src/timeline/TimelineView.cc index ee7b9a86..b156b732 100644 --- a/src/timeline/TimelineView.cc +++ b/src/timeline/TimelineView.cc @@ -1450,5 +1450,7 @@ TimelineView::handleClaimedKeys(std::shared_ptr<StateKeeper> keeper, "message: {}", err->matrix_error.error); } + + (void)keeper; }); } |