Skip to content

Commit a25986e

Browse files
committed
to_be_investigated: rate limit Client.available()
1 parent f26e6a9 commit a25986e

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

libraries/SocketWrapper/SocketWrapper.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,9 @@ class ZephyrSocketWrapper {
8080
int available() {
8181
int count = 0;
8282
zsock_ioctl(sock_fd, ZFD_IOCTL_FIONREAD, &count);
83+
if (count == 0) {
84+
delay(1);
85+
}
8386
return count;
8487
}
8588

0 commit comments

Comments
 (0)