mirror of
https://github.com/espressif/esp-nimble.git
synced 2026-08-18 15:59:59 +00:00
Added NULL peer addr check
This commit is contained in:
committed by
Abhinav Kudnar
parent
413587cb93
commit
41d6f74269
@@ -5727,6 +5727,11 @@ ble_gap_connect(uint8_t own_addr_type, const ble_addr_t *peer_addr,
|
||||
goto done;
|
||||
}
|
||||
|
||||
if (peer_addr == NULL) {
|
||||
rc = BLE_HS_EINVAL;
|
||||
goto done;
|
||||
}
|
||||
|
||||
if (peer_addr &&
|
||||
peer_addr->type != BLE_ADDR_PUBLIC &&
|
||||
peer_addr->type != BLE_ADDR_RANDOM &&
|
||||
|
||||
Reference in New Issue
Block a user