From 716edebbbdc22a01bede532e7df140eda904233c Mon Sep 17 00:00:00 2001 From: baohongde Date: Fri, 26 Feb 2021 14:44:57 +0800 Subject: [PATCH] components/bt: Fix assert without sw coexist enabled --- components/bt/bt.c | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/components/bt/bt.c b/components/bt/bt.c index b7b589373b..0a6be36ff3 100644 --- a/components/bt/bt.c +++ b/components/bt/bt.c @@ -1107,7 +1107,7 @@ static uint8_t coex_schm_curr_period_get_wrapper(void) #if CONFIG_SW_COEXIST_ENABLE return coex_schm_curr_period_get(); #else - return 0; + return 1; #endif } @@ -1125,13 +1125,7 @@ static int coex_wifi_channel_get_wrapper(uint8_t *primary, uint8_t *secondary) #if CONFIG_SW_COEXIST_ENABLE return coex_wifi_channel_get(primary, secondary); #else - if (primary == NULL || secondary == NULL) { - return -1; - } - - *primary = 0; - *secondary = 0; - return 0; + return -1; #endif } @@ -1140,7 +1134,7 @@ static int coex_register_wifi_channel_change_callback_wrapper(void *cb) #if CONFIG_SW_COEXIST_ENABLE return coex_register_wifi_channel_change_callback(cb); #else - return 0; + return -1; #endif }