ESP8266WiFi write() return not consistent with Arduino Docs
Posted: Sun May 08, 2016 9:16 pm
Arduino WiFi doc show
write() returning
byte : the number of bytes written. It is not necessary to read this.
https://www.arduino.cc/en/Reference/WiFiClientWrite
however V2.2.0 ESP8266WiFi ClientContext.h write() returns
were as it should return
to be consistent with Arduino docs, and with usual C definition of write()
OR could return
since
is set a few lines above
write() returning
byte : the number of bytes written. It is not necessary to read this.
https://www.arduino.cc/en/Reference/WiFiClientWrite
however V2.2.0 ESP8266WiFi ClientContext.h write() returns
Code: Select all
return will_send - _size_sent;
were as it should return
Code: Select all
return size_sent;
to be consistent with Arduino docs, and with usual C definition of write()
OR could return
Code: Select all
return will_send;
since
Code: Select all
_size_sent = will_send;
is set a few lines above