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:
@@ -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