Bugfix
This commit is contained in:
parent
28a655151a
commit
a21920a7bd
@ -35800,8 +35800,8 @@ void MessagesManager::get_channel_difference_delayed(DialogId dialog_id, int32 p
|
||||
get_channel_difference(dialog_id,pts, force, "on_get_channel_difference");
|
||||
} else {
|
||||
auto channel_difference_id = ++last_pending_channel_difference_;
|
||||
pending_channel_difference_
|
||||
.emplace(channel_difference_id, td::make_unique<PendingChannelDifference>(dialog_id, pts, force));
|
||||
PendingChannelDifference pendingChannelDifference = {dialog_id, pts, force};
|
||||
pending_channel_difference_.emplace(channel_difference_id, pendingChannelDifference);
|
||||
send_closure(G()->td(), &Td::send_update,
|
||||
make_tl_object<td_api::updateNewChannelDifferencePart>(channel_difference_id));
|
||||
}
|
||||
@ -35809,14 +35809,13 @@ void MessagesManager::get_channel_difference_delayed(DialogId dialog_id, int32 p
|
||||
|
||||
bool MessagesManager::run_get_channel_difference_request(long id) {
|
||||
auto pending_channel_difference_entry = pending_channel_difference_.find(id);
|
||||
if (pending_channel_difference_entry == pending_channel_difference_.end() ||
|
||||
pending_channel_difference_entry->second == nullptr) {
|
||||
if (pending_channel_difference_entry == pending_channel_difference_.end()) {
|
||||
return false;
|
||||
}
|
||||
pending_channel_difference_.erase(pending_channel_difference_entry);
|
||||
// Run get_channel_difference
|
||||
get_channel_difference(pending_channel_difference_entry->second->dialog_id,
|
||||
pending_channel_difference_entry->second->pts, pending_channel_difference_entry->second->force,
|
||||
get_channel_difference(pending_channel_difference_entry->second.dialog_id,
|
||||
pending_channel_difference_entry->second.pts, pending_channel_difference_entry->second.force,
|
||||
"on_get_channel_difference");
|
||||
return true;
|
||||
}
|
||||
|
@ -3143,7 +3143,7 @@ class MessagesManager : public Actor {
|
||||
|
||||
}
|
||||
};
|
||||
std::unordered_map<int64, unique_ptr<PendingChannelDifference>> pending_channel_difference_;
|
||||
std::unordered_map<int64, PendingChannelDifference> pending_channel_difference_;
|
||||
int64 last_pending_channel_difference_ = 0;
|
||||
|
||||
struct PendingMessageGroupSend {
|
||||
|
Loading…
x
Reference in New Issue
Block a user