From 0396d2dfffb9075404019fdf831b5e88b4e42558 Mon Sep 17 00:00:00 2001 From: levlam Date: Tue, 4 Aug 2020 02:21:20 +0300 Subject: [PATCH] Silence expected error logging. GitOrigin-RevId: 7d8e66bac8f5b2bb40aa50d7fd7f01f0ff1eeb35 --- td/telegram/net/DcAuthManager.cpp | 2 +- td/telegram/net/NetQueryCreator.cpp | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/td/telegram/net/DcAuthManager.cpp b/td/telegram/net/DcAuthManager.cpp index 8fa463eb9..c370fcf92 100644 --- a/td/telegram/net/DcAuthManager.cpp +++ b/td/telegram/net/DcAuthManager.cpp @@ -165,7 +165,7 @@ void DcAuthManager::dc_loop(DcInfo &dc) { switch (dc.state) { case DcInfo::State::Waiting: { // wait for timeout - // break; + // break; } case DcInfo::State::Export: { // send auth.exportAuthorization to auth_dc diff --git a/td/telegram/net/NetQueryCreator.cpp b/td/telegram/net/NetQueryCreator.cpp index 91d9ae6e6..8e9d4417f 100644 --- a/td/telegram/net/NetQueryCreator.cpp +++ b/td/telegram/net/NetQueryCreator.cpp @@ -62,7 +62,8 @@ NetQueryPtr NetQueryCreator::create(uint64 id, const telegram_api::Function &fun if (auth_manager != nullptr && auth_manager->is_bot()) { total_timeout_limit = 8; } - if ((auth_manager == nullptr || !auth_manager->was_authorized()) && auth_flag == NetQuery::AuthFlag::On) { + if ((auth_manager == nullptr || !auth_manager->was_authorized()) && auth_flag == NetQuery::AuthFlag::On && + tl_constructor != telegram_api::auth_exportAuthorization::ID) { LOG(ERROR) << "Send query before authorization: " << to_string(function); } }