mirror of
https://github.com/espressif/esp-idf.git
synced 2026-10-02 03:00:34 +03:00
fix(ble_mesh): Miscellaneous bugfixes according to our internal bug report (v2)
This commit is contained in:
@@ -1,14 +1,18 @@
|
||||
/*
|
||||
* SPDX-FileCopyrightText: 2016 Intel Corporation
|
||||
* SPDX-FileCopyrightText: 2016 Wind River Systems, Inc.
|
||||
* SPDX-FileContributor: 2020-2021 Espressif Systems (Shanghai) CO LTD
|
||||
* SPDX-FileContributor: 2020-2026 Espressif Systems (Shanghai) CO LTD
|
||||
*
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
#include "mesh/timer.h"
|
||||
#include "mesh/kernel.h"
|
||||
|
||||
void k_sleep(int32_t duration)
|
||||
{
|
||||
vTaskDelay(duration / portTICK_PERIOD_MS);
|
||||
if (duration < 0 && duration != K_FOREVER) {
|
||||
duration = 0;
|
||||
}
|
||||
vTaskDelay((duration == K_FOREVER) ? portMAX_DELAY : (duration / portTICK_PERIOD_MS));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user