From 5c2cc6089ffdf5024d9addab65ddda21755ac972 Mon Sep 17 00:00:00 2001 From: Juan Batiz-Benet Date: Sun, 28 Dec 2014 03:59:40 -0800 Subject: [PATCH] updated go-peerstream (close fix) --- Godeps/Godeps.json | 2 +- .../_workspace/src/github.com/jbenet/go-peerstream/conn.go | 7 ++++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/Godeps/Godeps.json b/Godeps/Godeps.json index 666d918e0..87de42e01 100644 --- a/Godeps/Godeps.json +++ b/Godeps/Godeps.json @@ -141,7 +141,7 @@ }, { "ImportPath": "github.com/jbenet/go-peerstream", - "Rev": "1c71a3e04eeef9297a12ecdff75a0b28ffa8bf90" + "Rev": "fc6b2a964210945ae2325e6678898d2222526f00" }, { "ImportPath": "github.com/jbenet/go-random", diff --git a/Godeps/_workspace/src/github.com/jbenet/go-peerstream/conn.go b/Godeps/_workspace/src/github.com/jbenet/go-peerstream/conn.go index e5325e331..7481c8015 100644 --- a/Godeps/_workspace/src/github.com/jbenet/go-peerstream/conn.go +++ b/Godeps/_workspace/src/github.com/jbenet/go-peerstream/conn.go @@ -235,7 +235,12 @@ func (s *Swarm) removeStream(stream *Stream) error { s.streamLock.Unlock() stream.conn.streamLock.Unlock() - return stream.ssStream.Close() + // Reset is spdystream's full bidirectional close. + // We expose bidirectional close as our `Close`. + // To close only half of the connection, and use other + // spdystream options, just get the stream with: + // stream.SPDYStream() + return stream.ssStream.Reset() } func (s *Swarm) removeConn(conn *Conn) error {