Skip to content

Commit d6d0e6b

Browse files
committed
Fixed possible crash when commited to recreated topic reader (#18978)
1 parent 54d0643 commit d6d0e6b

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

ydb/core/tx/replication/service/topic_reader.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -84,8 +84,9 @@ class TRemoteTopicReader: public TActor<TRemoteTopicReader> {
8484
void Handle(TEvWorker::TEvCommit::TPtr& ev) {
8585
LOG_D("Handle " << ev->Get()->ToString());
8686

87-
Y_ABORT_UNLESS(YdbProxy);
88-
Y_ABORT_UNLESS(ReadSessionId);
87+
if (!YdbProxy || !ReadSessionId) {
88+
return Leave(TEvWorker::TEvGone::UNAVAILABLE);
89+
}
8990

9091
auto settings = NYdb::NTopic::TCommitOffsetSettings()
9192
.ReadSessionId(ReadSessionId);

0 commit comments

Comments
 (0)