X-Git-Url: https://git.distorted.org.uk/u/mdw/putty/blobdiff_plain/0ac1920cf35f15c8fd8dbfedb332bd79e5ecdd33..0edafb21b50772bc9e245b7d140aba43875c443d:/pscp.c?ds=sidebyside diff --git a/pscp.c b/pscp.c index a906303b..5f22828a 100644 --- a/pscp.c +++ b/pscp.c @@ -245,7 +245,7 @@ static int ssh_scp_recv(unsigned char *buf, int len) } while (outlen > 0) { - if (ssh_sftp_loop_iteration() < 0) + if (back->exitcode(backhandle) >= 0 || ssh_sftp_loop_iteration() < 0) return 0; /* doom */ }