1
0
mirror of https://github.com/esp8266/Arduino.git synced 2025-06-06 05:21:22 +03:00

host build: optimistic_yield() wrongly delays() instead of avoiding excessive yields (#6802)

* optimistic_yield is a yield, not a delay, and avoids yielding if last yield has occurred recently enough.

* Suppress an unused argument warning.

Co-authored-by: Earle F. Philhower, III <earlephilhower@yahoo.com>
This commit is contained in:
Dirk O. Kaar 2020-01-28 01:47:39 +01:00 committed by Earle F. Philhower, III
parent 7b0fa3554c
commit bb696dd204

View File

@ -44,7 +44,7 @@ extern "C" bool can_yield()
extern "C" void optimistic_yield (uint32_t interval_us)
{
usleep(interval_us);
(void)interval_us;
}
extern "C" void esp_yield()