Fix #123: accept() fails if IP is banned.

This commit is contained in:
Jan Vidar Krey 2010-04-05 13:44:17 +02:00
parent e220357176
commit 8e579f4601
1 changed files with 2 additions and 2 deletions

View File

@ -203,7 +203,7 @@ void net_on_accept(struct net_connection* con, int event, void *arg)
if (acl_is_ip_banned(hub->acl, addr))
{
LOG_INFO("Denied [%s] (IP banned)", addr);
net_con_close(con);
net_close(fd);
continue;
}
@ -211,7 +211,7 @@ void net_on_accept(struct net_connection* con, int event, void *arg)
if (!probe)
{
LOG_ERROR("Unable to create probe after socket accepted. Out of memory?");
net_con_close(con);
net_close(fd);
break;
}
}