Skip to content

Commit

Permalink
reorder checks
Browse files Browse the repository at this point in the history
  • Loading branch information
kaijchen committed Nov 27, 2024
1 parent 2e9c95a commit 8e58c4b
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions be/src/vec/sink/load_stream_stub.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -334,11 +334,11 @@ Status LoadStreamStub::wait_for_schema(int64_t partition_id, int64_t index_id, i

Status LoadStreamStub::close_wait(RuntimeState* state, int64_t timeout_ms) {
DBUG_EXECUTE_IF("LoadStreamStub::close_wait.long_wait", DBUG_BLOCK);
if (!_is_open.load()) {
// we don't need to close wait on non-open streams
return Status::OK();
}
if (!_is_closing.load()) {
if (!_is_open.load()) {
// we don't need to close wait on non-open streams
return Status::OK();
}
return _status;
}
if (_is_closed.load()) {
Expand Down

0 comments on commit 8e58c4b

Please sign in to comment.