tun2: close streams less aggressively

This commit is contained in:
Cadey Ratio 2017-10-01 08:42:44 -07:00
parent 9306ed4305
commit c1f8899806
No known key found for this signature in database
GPG Key ID: D607EE27C2E7F89A
1 changed files with 4 additions and 1 deletions

View File

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