Skip to content

Instantly share code, notes, and snippets.

@jonasschneider
Created February 17, 2013 12:03
Show Gist options
  • Save jonasschneider/4971224 to your computer and use it in GitHub Desktop.
Save jonasschneider/4971224 to your computer and use it in GitHub Desktop.
--- ssh/channel.go 2013-02-17 13:00:21.000000000 +0100
+++ /usr/local/Cellar/go/1.0.3/src/pkg/code.google.com/p/go.crypto/ssh/channel.go 2013-02-16 21:25:52.000000000 +0100
@@ -303,7 +303,7 @@ func (c *serverChan) read(data []byte) (
}
for {
- if c.dead() {
+ if c.theySentEOF || c.theyClosed || c.dead() {
return 0, io.EOF, 0
}
@@ -336,8 +336,6 @@ func (c *serverChan) read(data []byte) (
c.myWindow += windowAdjustment
return
- } else if c.theySentEOF || c.theyClosed {
- return 0, io.EOF, 0
}
c.cond.Wait()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment