mirror of https://github.com/wolfSSL/wolfssh.git
SFTP_SendReadPacket() can return a 0 in normal situations. SFTP_Get()
was treating it like an error and skipping the file close.pull/134/head
parent
c91dc02336
commit
9d589ea769
|
@ -5969,7 +5969,7 @@ int wolfSSH_SFTP_Get(WOLFSSH* ssh, char* from,
|
|||
state->handle, state->handleSz,
|
||||
state->gOfst, state->r,
|
||||
WOLFSSH_MAX_SFTP_RW);
|
||||
if (sz <= 0) {
|
||||
if (sz < 0) {
|
||||
if (ssh->error == WS_WANT_READ ||
|
||||
ssh->error == WS_WANT_WRITE) {
|
||||
return WS_FATAL_ERROR;
|
||||
|
|
Loading…
Reference in New Issue