dataroaring commented on code in PR #14218: URL: https://github.com/apache/doris/pull/14218#discussion_r1020743415
########## be/src/olap/delta_writer.cpp: ########## @@ -410,9 +417,14 @@ Status DeltaWriter::cancel() { _flush_token->cancel(); } _is_cancelled = true; + _cancel_status = st; return Status::OK(); } +Status DeltaWriter::cancel() { + return cancel_with_status(Status::OK()); Review Comment: Here, cancel_with_status(Status::OLAPInternalError(OLAP_ERR_ALREADY_CANCELLED)); Then c if (_is_cancelled) { RETURN_NOT_OK(_cancel_status); return Status::OLAPInternalError(OLAP_ERR_ALREADY_CANCELLED); } can be written like below: if (_is_cancelled) { return _cancel_status; }. -- 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