mirror of
https://github.com/XTLS/Xray-core.git
synced 2024-12-22 19:33:32 +02:00
fix: close resp body
This commit is contained in:
parent
befa7b8138
commit
12f5b05aca
1 changed files with 1 additions and 0 deletions
|
@ -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