internal/tun2: think smarter not harder

This commit is contained in:
Cadey Ratio 2017-12-12 10:18:26 -08:00
parent 9bb2d4f436
commit ae2f5ca097
1 changed files with 5 additions and 1 deletions

View File

@ -128,7 +128,11 @@ func (c *Connection) RoundTrip(req *http.Request) (*http.Response, error) {
if err != nil { if err != nil {
return nil, errors.Wrap(err, ErrCantOpenSessionStream.Error()) return nil, errors.Wrap(err, ErrCantOpenSessionStream.Error())
} }
defer stream.Close()
go func() {
time.Sleep(30 * time.Minute)
stream.Close()
}()
err = req.Write(stream) err = req.Write(stream)
if err != nil { if err != nil {