From 83f6d7d81b80809de0bc850a0b445bc035098dba Mon Sep 17 00:00:00 2001 From: JF Date: Mon, 17 Aug 2020 16:31:00 +0200 Subject: Fix most of the warnings. Remaining warnings come from nimble source code. --- src/Components/Ble/NimbleController.cpp | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'src/Components/Ble/NimbleController.cpp') diff --git a/src/Components/Ble/NimbleController.cpp b/src/Components/Ble/NimbleController.cpp index d7bbd8be..a865a824 100644 --- a/src/Components/Ble/NimbleController.cpp +++ b/src/Components/Ble/NimbleController.cpp @@ -139,14 +139,13 @@ void NimbleController::StartAdvertising() { rsp_fields.name_len = strlen("Pinetime-JF"); rsp_fields.name_is_complete = 1; - int res; - res = ble_gap_adv_set_fields(&fields); + ble_gap_adv_set_fields(&fields); // ASSERT(res == 0); // TODO this one sometimes fails with error 22 (notsync) - res = ble_gap_adv_rsp_set_fields(&rsp_fields); + ble_gap_adv_rsp_set_fields(&rsp_fields); // ASSERT(res == 0); - res = ble_gap_adv_start(addrType, NULL, 180000, + ble_gap_adv_start(addrType, NULL, 180000, &adv_params, GAPEventCallback, this); // ASSERT(res == 0);// TODO I've disabled these ASSERT as they sometime asserts and reset the mcu. // For now, the advertising is restarted as soon as it ends. There may be a race condition -- cgit v1.2.3-70-g09d2