Skip to content

Commit 1422697

Browse files
add check for want write in example echoserver to handle new test case
1 parent 71cda6d commit 1422697

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

examples/echoserver/echoserver.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1308,7 +1308,7 @@ static int sftp_worker(thread_ctx_t* threadCtx)
13081308
s = (WS_SOCKET_T)wolfSSH_get_fd(ssh);
13091309

13101310
do {
1311-
if (wolfSSH_SFTP_PendingSend(ssh)) {
1311+
if (ret == WS_WANT_WRITE || wolfSSH_SFTP_PendingSend(ssh)) {
13121312
/* Yes, process the SFTP data. */
13131313
ret = wolfSSH_SFTP_read(ssh);
13141314
error = wolfSSH_get_error(ssh);

0 commit comments

Comments
 (0)