Skip to content

Commit aca51a8

Browse files
committed
Don't check external messages if out of sync
1 parent 9d94e04 commit aca51a8

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

validator/manager.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -430,6 +430,10 @@ void ValidatorManagerImpl::add_external_message(td::Ref<ExtMessage> msg, int pri
430430
ext_messages_hashes_[id.hash] = {priority, id};
431431
}
432432
void ValidatorManagerImpl::check_external_message(td::BufferSlice data, td::Promise<td::Ref<ExtMessage>> promise) {
433+
if (!started_) {
434+
promise.set_error(td::Status::Error(ErrorCode::notready, "node not synced"));
435+
return;
436+
}
433437
auto state = do_get_last_liteserver_state();
434438
if (state.is_null()) {
435439
promise.set_error(td::Status::Error(ErrorCode::notready, "not ready"));

0 commit comments

Comments
 (0)