mirror of
https://github.com/XTLS/Xray-core.git
synced 2024-11-25 10:01:28 +00:00
fix: close resp body
This commit is contained in:
parent
befa7b8138
commit
12f5b05aca
|
@ -222,6 +222,7 @@ func UClient(c net.Conn, config *Config, ctx context.Context, dest net.Destinati
|
|||
if resp, err = client.Do(req); err != nil {
|
||||
break
|
||||
}
|
||||
defer resp.Body.Close()
|
||||
req.Header.Set("Referer", req.URL.String())
|
||||
if body, err = io.ReadAll(resp.Body); err != nil {
|
||||
break
|
||||
|
|
Loading…
Reference in a new issue