Skip to content

Commit 63a8448

Browse files
Earle F. Philhower, IIIEarle F. Philhower, III
Earle F. Philhower, III
authored and
Earle F. Philhower, III
committed
Actually let OS advance in ::flush
Replace esp_yield with delay(0) which calls both the yield and the scheduler. Supersedes PR esp8266#5254
1 parent e549355 commit 63a8448

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

libraries/ESP8266WiFi/src/include/ClientContext.h

+2-3
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@ class WiFiClient;
2626

2727
typedef void (*discard_cb_t)(void*, ClientContext*);
2828

29-
extern "C" void esp_yield();
3029
extern "C" void esp_schedule();
3130

3231
#include "DataSource.h"
@@ -333,7 +332,7 @@ class ClientContext
333332
last_sent = millis();
334333
}
335334

336-
esp_yield(); // from sys or os context
335+
delay(0); // from sys or os context
337336

338337
if ((state() != ESTABLISHED) || (sndbuf == TCP_SND_BUF)) {
339338
break;
@@ -456,7 +455,7 @@ class ClientContext
456455
}
457456

458457
++_send_waiting;
459-
esp_yield();
458+
delay(0);
460459
} while(true);
461460
_send_waiting = 0;
462461

0 commit comments

Comments
 (0)