Skip to content

Commit

Permalink
fix a panic issue in parallel agg when exception is thrown (#5433) (#…
Browse files Browse the repository at this point in the history
…5441)

close #5356
  • Loading branch information
ti-chi-bot committed Jul 21, 2022
1 parent dbffeba commit 22ab5ec
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions dbms/src/DataStreams/ParallelAggregatingBlockInputStream.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -156,9 +156,8 @@ void ParallelAggregatingBlockInputStream::Handler::onFinish()
void ParallelAggregatingBlockInputStream::Handler::onException(std::exception_ptr & exception, size_t thread_num)
{
parent.exceptions[thread_num] = exception;
/// can not cancel parent inputStream or the exception might be lost
if (!parent.executed)
parent.processor.cancel(false);
parent.cancel(false);
}


Expand Down

0 comments on commit 22ab5ec

Please sign in to comment.