From 21bd1222b563f4647b6d51929524484853bdeebe Mon Sep 17 00:00:00 2001 From: zhiqiang-hhhh Date: Tue, 6 Aug 2024 22:58:40 +0800 Subject: [PATCH 1/2] FIX --- be/src/runtime/runtime_state.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/be/src/runtime/runtime_state.h b/be/src/runtime/runtime_state.h index d0c2f93103e8b5..1c89d551efa850 100644 --- a/be/src/runtime/runtime_state.h +++ b/be/src/runtime/runtime_state.h @@ -729,9 +729,11 @@ class RuntimeState { std::string _s3_error_log_file_path; }; -#define RETURN_IF_CANCELLED(state) \ +#define RETURN_IF_CANCELLED(state) \ do { \ - if (UNLIKELY((state)->is_cancelled())) return Status::Cancelled("Cancelled"); \ + if (UNLIKELY((state)->is_cancelled())) { \ + return (state)->cancel_reason(); \ + } \ } while (false) } // namespace doris From d3498dfcf6883f159e33a1bd7b1d8124843f95a0 Mon Sep 17 00:00:00 2001 From: zhiqiang-hhhh Date: Tue, 6 Aug 2024 23:01:36 +0800 Subject: [PATCH 2/2] FORMT --- be/src/runtime/runtime_state.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/be/src/runtime/runtime_state.h b/be/src/runtime/runtime_state.h index 1c89d551efa850..cae6c4e6403ea9 100644 --- a/be/src/runtime/runtime_state.h +++ b/be/src/runtime/runtime_state.h @@ -729,11 +729,11 @@ class RuntimeState { std::string _s3_error_log_file_path; }; -#define RETURN_IF_CANCELLED(state) \ - do { \ - if (UNLIKELY((state)->is_cancelled())) { \ - return (state)->cancel_reason(); \ - } \ +#define RETURN_IF_CANCELLED(state) \ + do { \ + if (UNLIKELY((state)->is_cancelled())) { \ + return (state)->cancel_reason(); \ + } \ } while (false) } // namespace doris