X-Git-Url: https://git.distorted.org.uk/~mdw/sgt/putty/blobdiff_plain/e414a330d66b19abceb4c367dac70408b815b302..0bd57c0f66354345eac1d1654a56860919254b4c:/psftp.c diff --git a/psftp.c b/psftp.c index cb5add3f..63446d4d 100644 --- a/psftp.c +++ b/psftp.c @@ -707,7 +707,7 @@ int sftp_put_file(char *fname, char *outfname, int recurse, int restart) if (!xfer_done(xfer)) { pktin = sftp_recv(); ret = xfer_upload_gotpkt(xfer, pktin); - if (!ret) { + if (ret <= 0 && !err) { printf("error while writing: %s\n", fxp_error()); err = 1; }