Fix a file descriptor leak when connect() fails during a SOCKS4 proxy
connection attempt. git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@242 13b04d17-f746-0410-82c6-800466cd88b0
This commit is contained in:
@@ -1,5 +1,8 @@
|
||||
[Changes 1.2c01]
|
||||
|
||||
* Fix file descriptor leak on SOCKS4 connection failure found by
|
||||
Coverity. (caf)
|
||||
|
||||
* Fix out-of-bounds error in cryptit() found by Coverity. (flashback)
|
||||
|
||||
* Cleanup save_formats(). (caf)
|
||||
|
||||
@@ -343,6 +343,7 @@ int handle_socks(int fd, struct sockaddr_in addr, char *host, int portnum)
|
||||
{
|
||||
alarm(0);
|
||||
bitchsay("Unable to connect to SOCKS4 proxy: %s", strerror(errno));
|
||||
close(fd);
|
||||
return -1;
|
||||
}
|
||||
alarm(0);
|
||||
|
||||
Reference in New Issue
Block a user