diff mbox series

Bluetooth: btintel: check the correct variable in btintel_get_codec_config_data()

Message ID 20210909091511.GC26312@kili
State New
Headers show
Series Bluetooth: btintel: check the correct variable in btintel_get_codec_config_data() | expand

Commit Message

Dan Carpenter Sept. 9, 2021, 9:15 a.m. UTC
Check "*ven_data" instead of "ven_data" (without the asterisk).

Fixes: 70dd978952bc ("Bluetooth: btintel: Define a callback to fetch codec config data")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
---
 drivers/bluetooth/btintel.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/drivers/bluetooth/btintel.c b/drivers/bluetooth/btintel.c
index 115bb2d07a8d..9359bff47296 100644
--- a/drivers/bluetooth/btintel.c
+++ b/drivers/bluetooth/btintel.c
@@ -2176,7 +2176,7 @@  static int btintel_get_codec_config_data(struct hci_dev *hdev,
 	}
 
 	*ven_data = kmalloc(sizeof(__u8), GFP_KERNEL);
-	if (!ven_data) {
+	if (!*ven_data) {
 		err = -ENOMEM;
 		goto error;
 	}