mirror of
https://github.com/arduino/Arduino.git
synced 2025-01-29 18:52:13 +01:00
Fixes YunClient's connected() to behave like other Clients (WiFiClient, EthernetClient, etc)
This commit is contained in:
parent
c4de750253
commit
6f566776f9
@ -114,6 +114,10 @@ void YunClient::flush() {
|
||||
uint8_t YunClient::connected() {
|
||||
if (!opened)
|
||||
return false;
|
||||
// Client is "connected" if it has unread bytes
|
||||
if (available())
|
||||
return true;
|
||||
|
||||
uint8_t cmd[] = {'L', handle};
|
||||
uint8_t res[1];
|
||||
bridge.transfer(cmd, 2, res, 1);
|
||||
|
Loading…
x
Reference in New Issue
Block a user