Bugzilla – Attachment 1259 Details for
Bug 1306
Spurious : "chan_read_failed for istate 3" errors from sshd
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Damien's patch from http://marc.info/?l=openssh-unix-dev&m=117607220603593
djm-chan_read_failed.patch (text/plain), 2.78 KB, created by
Darren Tucker
on 2007-04-10 12:48:38 AEST
(
hide
)
Description:
Damien's patch from http://marc.info/?l=openssh-unix-dev&m=117607220603593
Filename:
MIME Type:
Creator:
Darren Tucker
Created:
2007-04-10 12:48:38 AEST
Size:
2.78 KB
patch
obsolete
>Index: channels.c >=================================================================== >RCS file: /var/cvs/openssh/channels.c,v >retrieving revision 1.251 >diff -u -p -r1.251 channels.c >--- channels.c 28 Jan 2007 23:16:28 -0000 1.251 >+++ channels.c 8 Apr 2007 22:43:25 -0000 >@@ -932,7 +932,7 @@ channel_pre_x11_open(Channel *c, fd_set > } else if (ret == -1) { > logit("X11 connection rejected because of wrong authentication."); > debug2("X11 rejected %d i%d/o%d", c->self, c->istate, c->ostate); >- chan_read_failed(c); >+ chan_read_failed(c, 0); > buffer_clear(&c->input); > chan_ibuf_empty(c); > buffer_clear(&c->output); >@@ -1472,14 +1472,15 @@ channel_handle_rfd(Channel *c, fd_set *r > c->type = SSH_CHANNEL_INPUT_DRAINING; > debug2("channel %d: input draining.", c->self); > } else { >- chan_read_failed(c); >+ chan_read_failed(c, (errno == EAGAIN && >+ !(c->isatty && c->detach_close))); > } > return -1; > } > if (c->input_filter != NULL) { > if (c->input_filter(c, buf, len) == -1) { > debug2("channel %d: filter stops", c->self); >- chan_read_failed(c); >+ chan_read_failed(c, 0); > } > } else if (c->datagram) { > buffer_put_string(&c->input, buf, len); >@@ -1643,7 +1644,7 @@ channel_handle_ctl(Channel *c, fd_set *r > chan_mark_dead(c); > return -1; > } else { >- chan_read_failed(c); >+ chan_read_failed(c, 0); > chan_write_failed(c); > } > return -1; >Index: channels.h >=================================================================== >RCS file: /var/cvs/openssh/channels.h,v >retrieving revision 1.81 >diff -u -p -r1.81 channels.h >--- channels.h 5 Aug 2006 02:39:39 -0000 1.81 >+++ channels.h 8 Apr 2007 22:43:41 -0000 >@@ -240,7 +240,7 @@ void chan_mark_dead(Channel *); > /* channel events */ > > void chan_rcvd_oclose(Channel *); >-void chan_read_failed(Channel *); >+void chan_read_failed(Channel *, int); > void chan_ibuf_empty(Channel *); > > void chan_rcvd_ieof(Channel *); >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 8 Apr 2007 22:41:36 -0000 >@@ -133,17 +133,19 @@ chan_rcvd_oclose1(Channel *c) > } > } > void >-chan_read_failed(Channel *c) >+chan_read_failed(Channel *c, int simulated) > { >- debug2("channel %d: read failed", c->self); >+ debug2("channel %d: read failed%s, istate %d", c->self, >+ simulated ? " (simulated)" : "", 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 (!simulated) >+ error("channel %d: chan_read_failed for istate %d", >+ c->self, c->istate); > break; > } > } >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 1306
:
1259
|
1260
|
1261
|
1262
|
1281