From fc0be5f38c9c287f2eb4785f2143cf9253871dc7 Mon Sep 17 00:00:00 2001 From: xufei Date: Wed, 12 Apr 2023 17:36:10 +0800 Subject: [PATCH] fix build Signed-off-by: xufei --- dbms/src/Interpreters/Join.cpp | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/dbms/src/Interpreters/Join.cpp b/dbms/src/Interpreters/Join.cpp index c857ea02cf6..b27c9d7e272 100644 --- a/dbms/src/Interpreters/Join.cpp +++ b/dbms/src/Interpreters/Join.cpp @@ -975,21 +975,18 @@ Block Join::joinBlockHash(ProbeProcessInfo & probe_process_info) const while (true) { auto block = doJoinBlockHash(probe_process_info); + assert(block); result_rows += block.rows(); + result_blocks.push_back(std::move(block)); /// exit the while loop if /// 1. probe_process_info.all_rows_joined_finish is true, which means all the rows in current block is processed /// 2. result_rows exceeds the min_result_block_size if (probe_process_info.all_rows_joined_finish || result_rows >= probe_process_info.min_result_block_size) - { - if (result_blocks.empty()) - return block; - result_blocks.push_back(std::move(block)); break; - } - result_blocks.push_back(std::move(block)); } assert(!result_blocks.empty()); - vstackBlocks(std::move(result_blocks)); + return vstackBlocks(std::move(result_blocks)); +} namespace {