tun2: close streams less aggressively
This commit is contained in:
parent
9306ed4305
commit
c1f8899806
|
@ -125,7 +125,10 @@ 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()
|
defer func() {
|
||||||
|
time.Sleep(5 * time.Minute)
|
||||||
|
stream.Close()
|
||||||
|
}()
|
||||||
|
|
||||||
err = req.Write(stream)
|
err = req.Write(stream)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
|
Loading…
Reference in New Issue