github-actions[bot] commented on code in PR #18051: URL: https://github.com/apache/doris/pull/18051#discussion_r1145813694
########## be/src/vec/core/block_spill_writer.cpp: ########## @@ -107,33 +104,48 @@ Status BlockSpillWriter::_write_internal(const Block& block) { Status status; std::string buff; - PBlock pblock; - { - SCOPED_TIMER(serialize_timer_); - status = block.serialize(BeExecVersionManager::get_newest_version(), &pblock, - &uncompressed_bytes, &compressed_bytes, - segment_v2::CompressionTypePB::LZ4); + if (block.rows() > 0) { + PBlock pblock; + { + SCOPED_TIMER(serialize_timer_); + status = block.serialize(BeExecVersionManager::get_newest_version(), &pblock, + &uncompressed_bytes, &compressed_bytes, + segment_v2::CompressionTypePB::LZ4); + if (!status.ok()) { + unlink(file_path_.c_str()); + return status; + } + pblock.SerializeToString(&buff); + } + + { + SCOPED_TIMER(write_timer_); + status = file_writer_->write((const uint8_t*)buff.data(), buff.size(), &written_bytes); Review Comment: warning: no member named 'write' in 'doris::io::FileWriter' [clang-diagnostic-error] ```cpp status = file_writer_->write((const uint8_t*)buff.data(), buff.size(), &written_bytes); ^ ``` -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For additional commands, e-mail: commits-h...@doris.apache.org