File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed
libraries/ESP8266WiFi/src/include Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -437,7 +437,7 @@ class ClientContext
437437 size_t _write_from_source (DataSource* ds)
438438 {
439439 assert (_datasource == nullptr );
440- assert (_send_waiting == 0 );
440+ assert (! _send_waiting);
441441 _datasource = ds;
442442 _written = 0 ;
443443 _op_start_time = millis ();
@@ -455,10 +455,10 @@ class ClientContext
455455 break ;
456456 }
457457
458- ++ _send_waiting;
458+ _send_waiting = true ;
459459 esp_yield ();
460460 } while (true );
461- _send_waiting = 0 ;
461+ _send_waiting = false ;
462462
463463 if (_sync)
464464 wait_until_sent ();
@@ -525,8 +525,8 @@ class ClientContext
525525
526526 void _write_some_from_cb ()
527527 {
528- if (_send_waiting == 1 ) {
529- _send_waiting-- ;
528+ if (_send_waiting) {
529+ _send_waiting = false ;
530530 esp_schedule ();
531531 }
532532 }
@@ -650,7 +650,7 @@ class ClientContext
650650 size_t _written = 0 ;
651651 uint32_t _timeout_ms = 5000 ;
652652 uint32_t _op_start_time = 0 ;
653- uint8_t _send_waiting = 0 ;
653+ bool _send_waiting = false ;
654654 uint8_t _connect_pending = 0 ;
655655
656656 int8_t _refcnt;
You can’t perform that action at this time.
0 commit comments