Commit ab1ee8d7 authored by Sébastien Blin's avatar Sébastien Blin

archive_account_manager: protect dhtContext in search lambda

Change-Id: I2ab6818918fee8560b73967f3b224eebb92114e2
Gitlab: #147
parent e1a33525
......@@ -209,6 +209,9 @@ ArchiveAccountManager::loadFromDHT(const std::shared_ptr<AuthContext>& ctx)
try {
std::tie(key, loc) = computeKeys(ctx->credentials->password, ctx->credentials->uri, previous);
JAMI_DBG("[Auth] trying to load account from DHT with %s at %s", /**/ctx->credentials->uri.c_str(), loc.toString().c_str());
if (not ctx->dhtContext or ctx->dhtContext->found) {
ctx->dhtContext->dht.get(loc, [ctx, key=std::move(key), onAsync](const std::shared_ptr<dht::Value>& val) {
std::vector<uint8_t> decrypted;
try {
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment