mirror of
https://github.com/telegramdesktop/tdesktop
synced 2025-02-25 01:50:36 +00:00
Fix state assertion in reading requets.
This commit is contained in:
parent
f1c2d4fe3d
commit
91a6632a1b
@ -423,7 +423,6 @@ void Histories::sendReadRequest(not_null<History*> history, State &state) {
|
||||
const auto finished = [=] {
|
||||
const auto state = lookup(history);
|
||||
Assert(state != nullptr);
|
||||
Assert(state->sentReadTill >= tillId);
|
||||
|
||||
if (state->sentReadTill == tillId) {
|
||||
state->sentReadDone = true;
|
||||
@ -432,6 +431,8 @@ void Histories::sendReadRequest(not_null<History*> history, State &state) {
|
||||
} else {
|
||||
state->sentReadTill = 0;
|
||||
}
|
||||
} else {
|
||||
Assert(!state->sentReadTill || state->sentReadTill > tillId);
|
||||
}
|
||||
sendReadRequests();
|
||||
finish();
|
||||
|
Loading…
Reference in New Issue
Block a user