The unified diff between revisions [c387cf9d..] and [cc1d98a9..] is displayed below. It can also be downloaded as a raw diff.
This diff has been restricted to the following files: 'common-channel.c'
#
#
# patch "common-channel.c"
# from [8fa86543a791c4d69addf71cdbbcb27fe90006bd]
# to [034d3663f78146ada8078687a0d347d992c5f028]
#
============================================================
--- common-channel.c 8fa86543a791c4d69addf71cdbbcb27fe90006bd
+++ common-channel.c 034d3663f78146ada8078687a0d347d992c5f028
@@ -313,6 +313,7 @@ static void check_close(struct Channel *
/* And if we can't receive any more data from them either, close up */
if (!channel->sent_close
&& channel->readfd == FD_CLOSED
+ && (ERRFD_IS_WRITE(channel) || channel->errfd == FD_CLOSED)
&& !write_pending(channel)) {
TRACE(("sending close, readfd is closed"))
send_msg_channel_close(channel);
@@ -624,8 +625,8 @@ static void send_msg_channel_data(struct
close_chan_fd(channel, fd, SHUT_RD);
}
ses.writepayload->len = ses.writepayload->pos = 0;
- TRACE(("leave send_msg_channel_data: len %d read err or EOF for fd %d",
- len, channel->index));
+ TRACE(("leave send_msg_channel_data: len %d read err %d or EOF for fd %d",
+ len, errno, fd))
return;
}
buf_incrwritepos(ses.writepayload, len);