diff --git a/td/telegram/Logging.cpp b/td/telegram/Logging.cpp index 73e4bab30..da3e03e1d 100644 --- a/td/telegram/Logging.cpp +++ b/td/telegram/Logging.cpp @@ -56,7 +56,7 @@ static const std::map log_tags{ ADD_TAG(file_loader), ADD_TAG(mtproto), ADD_TAG(raw_mtproto), ADD_TAG(fd), ADD_TAG(actor), ADD_TAG(sqlite), ADD_TAG(notifications), ADD_TAG(get_difference), ADD_TAG(file_gc), ADD_TAG(config_recoverer), ADD_TAG(dns_resolver), ADD_TAG(file_references), - ADD_TAG(messages)}; + ADD_TAG(messages), ADD_TAG(postponed_pts_update)}; #undef ADD_TAG Status Logging::set_current_stream(td_api::object_ptr stream) { diff --git a/td/telegram/MessagesManager.cpp b/td/telegram/MessagesManager.cpp index 3a9b8d2e0..aea5d26af 100644 --- a/td/telegram/MessagesManager.cpp +++ b/td/telegram/MessagesManager.cpp @@ -52,7 +52,7 @@ #include "td/telegram/UpdatesManager.h" #include "td/telegram/Version.h" #include "td/telegram/WebPageId.h" -#include "td/telegram/Td.h" // for VERBOSITY_NAME(messages) +#include "td/telegram/Td.h" // for VERBOSITY_NAME(messages) and VERBOSITY_NAME(postponed_pts_update) #include "td/actor/PromiseFuture.h" #include "td/actor/SleepActor.h" @@ -7547,6 +7547,7 @@ void MessagesManager::drop_pending_updates() { void MessagesManager::postpone_pts_update(tl_object_ptr &&update, int32 pts, int32 pts_count, Promise &&promise) { + VLOG(postponed_pts_update) << "Postponed pts size: " << postponed_pts_updates_.size(); postponed_pts_updates_.emplace(pts, PendingPtsUpdate(std::move(update), pts, pts_count, std::move(promise))); } diff --git a/td/telegram/Td.cpp b/td/telegram/Td.cpp index aa30f1aae..9d3a2a151 100644 --- a/td/telegram/Td.cpp +++ b/td/telegram/Td.cpp @@ -145,6 +145,7 @@ namespace td { int VERBOSITY_NAME(td_init) = VERBOSITY_NAME(DEBUG) + 3; int VERBOSITY_NAME(td_requests) = VERBOSITY_NAME(INFO); int VERBOSITY_NAME(messages) = VERBOSITY_NAME(INFO); +int VERBOSITY_NAME(postponed_pts_update) = VERBOSITY_NAME(DEBUG); void Td::ResultHandler::set_td(Td *new_td) { CHECK(td == nullptr); diff --git a/td/telegram/Td.h b/td/telegram/Td.h index 9c8def7d5..c6a30f27c 100644 --- a/td/telegram/Td.h +++ b/td/telegram/Td.h @@ -87,6 +87,7 @@ namespace td { extern int VERBOSITY_NAME(td_init); extern int VERBOSITY_NAME(td_requests); extern int VERBOSITY_NAME(messages); +extern int VERBOSITY_NAME(postponed_pts_update); // Td may start closing after explicit "close" or "destroy" query. // Or it may start closing by itself, because authorization is lost.