]> git.ipfire.org Git - thirdparty/openssh-portable.git/commitdiff
upstream commit
authordjm@openbsd.org <djm@openbsd.org>
Fri, 11 Aug 2017 04:41:08 +0000 (04:41 +0000)
committerDamien Miller <djm@mindrot.org>
Sat, 12 Aug 2017 06:47:10 +0000 (16:47 +1000)
don't print verbose error message when ssh disconnects
under sftp; bz#2750; ok dtucker@

Upstream-ID: 6d83708aed77b933c47cf155a87dc753ec01f370

sftp-client.c

index a6e832270410161a6f9dd9f23f29024ca439ddc7..626330262264a1b8adfef0cff301d4d8e447976e 100644 (file)
@@ -1,4 +1,4 @@
-/* $OpenBSD: sftp-client.c,v 1.126 2017/01/03 05:46:51 djm Exp $ */
+/* $OpenBSD: sftp-client.c,v 1.127 2017/08/11 04:41:08 djm Exp $ */
 /*
  * Copyright (c) 2001-2004 Damien Miller <djm@openbsd.org>
  *
@@ -140,7 +140,7 @@ get_msg(struct sftp_conn *conn, struct sshbuf *m)
                fatal("%s: buffer error: %s", __func__, ssh_err(r));
        if (atomicio6(read, conn->fd_in, p, 4,
            conn->limit_kbps > 0 ? sftpio : NULL, &conn->bwlimit_in) != 4) {
-               if (errno == EPIPE)
+               if (errno == EPIPE || errno == ECONNRESET)
                        fatal("Connection closed");
                else
                        fatal("Couldn't read packet: %s", strerror(errno));