OpenSSH
[Top] [All Lists]

Re: 4.6p1 chan_read_failed error

To: Jim Stosick <jws@lindy.stanford.edu>
Subject: Re: 4.6p1 chan_read_failed error
From: Damien Miller <djm@mindrot.org>
Date: Wed, 4 Apr 2007 14:00:57 +1000 (EST)
Cc: openssh-unix-dev@mindrot.org
Delivered-to: sp-com-lists@consult.net
Delivered-to: openssh-unix-dev-list1@securepoint.com
Delivered-to: openssh-unix-dev-tmda@mindrot.org
Delivered-to: openssh-unix-dev@mindrot.org
In-reply-to: <46084BAF.2070601@lindy.stanford.edu>
List-archive: <http://lists.mindrot.org/pipermail/openssh-unix-dev>
List-help: <mailto:openssh-unix-dev-request@mindrot.org?subject=help>
List-id: Development of portable OpenSSH <openssh-unix-dev.mindrot.org>
List-post: <mailto:openssh-unix-dev@mindrot.org>
List-subscribe: <http://lists.mindrot.org/mailman/listinfo/openssh-unix-dev>, <mailto:openssh-unix-dev-request@mindrot.org?subject=subscribe>
List-unsubscribe: <http://lists.mindrot.org/mailman/listinfo/openssh-unix-dev>, <mailto:openssh-unix-dev-request@mindrot.org?subject=unsubscribe>
References: <46045AB6.6050903@lindy.stanford.edu> <20070324114902.GA8307@gate.dtucker.net> <46084BAF.2070601@lindy.stanford.edu>
Sender: openssh-unix-dev-bounces+openssh-unix-dev-list1=securepoint.com@mindrot.org
On Mon, 26 Mar 2007, Jim Stosick wrote:

> On 3/24/2007 4:49 AM, Darren Tucker wrote:
> 
> > On Fri, Mar 23, 2007 at 03:54:46PM -0700, Jim Stosick wrote:
> >> The 4.6p1 sshd is logging this error during remote commands or file 
> >> transfers:
> >>
> >>    error: channel 0: chan_read_failed for istate 3
> >>
> >> Platform is Solaris 8, 4.6p1 + OpenSSL 0.9.8d.
> 
> > I suspect this is related to the change for bug #52.  You could try
> > reverting the following patch ("patch -p1 -R") and see if the error
> > messages stop.
> 
> Yes, that eliminates the chan_read_failed error messages.

Well, it also undoes the fix for bug #52. I think it is safe to simply hush
the error message:

Index: nchan.c
===================================================================
RCS file: /var/cvs/openssh/nchan.c,v
retrieving revision 1.56
diff -u -p -r1.56 nchan.c
--- nchan.c     5 Aug 2006 02:39:40 -0000       1.56
+++ nchan.c     4 Apr 2007 03:56:11 -0000
@@ -135,15 +135,16 @@ chan_rcvd_oclose1(Channel *c)
 void
 chan_read_failed(Channel *c)
 {
-       debug2("channel %d: read failed", c->self);
+       debug2("channel %d: read failed, istate %d", c->self, c->istate);
        switch (c->istate) {
        case CHAN_INPUT_OPEN:
                chan_shutdown_read(c);
                chan_set_istate(c, CHAN_INPUT_WAIT_DRAIN);
                break;
        default:
-               error("channel %d: chan_read_failed for istate %d",
-                   c->self, c->istate);
+               if (!c->isatty || !c->detach_close)
+                       error("channel %d: chan_read_failed for istate %d",
+                           c->self, c->istate);
                break;
        }
 }
_______________________________________________
openssh-unix-dev mailing list
openssh-unix-dev@mindrot.org
http://lists.mindrot.org/mailman/listinfo/openssh-unix-dev

<Prev in Thread] Current Thread [Next in Thread>