From 5152b3338590b10c2464eecb65ba5d67ccbdc0a4 Mon Sep 17 00:00:00 2001 From: xiongweichao Date: Wed, 17 Nov 2021 11:02:03 +0800 Subject: [PATCH] Dereference null return value --- components/bt/host/bluedroid/stack/btm/btm_pm.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/components/bt/host/bluedroid/stack/btm/btm_pm.c b/components/bt/host/bluedroid/stack/btm/btm_pm.c index 7f7cc14ebd..77d662c442 100644 --- a/components/bt/host/bluedroid/stack/btm/btm_pm.c +++ b/components/bt/host/bluedroid/stack/btm/btm_pm.c @@ -709,6 +709,9 @@ void btm_pm_proc_cmd_status(UINT8 status) p_acl_cb = btm_handle_to_acl(btm_cb.pm_pend_link_hdl); + if (p_acl_cb == NULL) { + return; + } p_cb = p_acl_cb->p_pm_mode_db; if (status == HCI_SUCCESS) {