From 642748964796a4d0432aaaf5b2e1ba6a2eafcf7d Mon Sep 17 00:00:00 2001 From: luoxu Date: Mon, 11 Aug 2025 15:17:55 +0800 Subject: [PATCH] fix(bt): Fixed the issue of duplicate MAX macro definitions --- components/bt/common/include/bt_common.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/components/bt/common/include/bt_common.h b/components/bt/common/include/bt_common.h index dd57f6f957e..098082f647c 100644 --- a/components/bt/common/include/bt_common.h +++ b/components/bt/common/include/bt_common.h @@ -151,7 +151,9 @@ #define LOG_LOCAL_LEVEL_MAPPING LOG_LOCAL_LEVEL #endif +#ifndef MAX #define MAX(a, b) ((a) > (b) ? (a) : (b)) +#endif #define BT_LOG_LEVEL_CHECK(LAYER, LEVEL) (MAX(LAYER##_INITIAL_TRACE_LEVEL, LOG_LOCAL_LEVEL_MAPPING) >= BT_TRACE_LEVEL_##LEVEL)