1
0
forked from bip/bip

Remove useless null check. Cycle server on early connection problem.

This commit is contained in:
Arnaud Cornet 2008-12-30 11:12:52 +01:00
parent 0ecb77617c
commit 2ef3506a22
2 changed files with 1 additions and 2 deletions

View File

@ -897,8 +897,6 @@ static void create_socket(char *dsthostname, char *dstport, char *srchostname,
cn->connected = CONN_ERROR;
cdata = (struct connecting_data *)
bip_malloc(sizeof(struct connecting_data));
if (!cdata)
fatal("Out of memory.");
cdata->dst = cdata->src = cdata->cur = NULL;
err = getaddrinfo(dsthostname, dstport, &hint, &cdata->dst);

View File

@ -2127,6 +2127,7 @@ connection_t *irc_server_connect(struct link *link)
if (conn->handle == -1) {
mylog(LOG_INFO, "Cannot connect.");
connection_free(conn);
server_next(link);
return NULL;
}