mirror of
https://github.com/freebsd/freebsd-src.git
synced 2024-11-27 11:22:43 +00:00
MFC r300664
Fix Coverity CID 978183 Resource leak in rexec(). Close the socket if connect() fails to avoid leaking it. Reported by: Coverity CID: 978183
This commit is contained in:
parent
afaff5e72c
commit
15fe2c59b0
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/stable/10/; revision=301152
@ -330,6 +330,7 @@ retry:
|
||||
goto retry;
|
||||
}
|
||||
perror(hp->h_name);
|
||||
(void) close(s);
|
||||
return (-1);
|
||||
}
|
||||
if (fd2p == 0) {
|
||||
|
Loading…
Reference in New Issue
Block a user