From: Willy Tarreau Date: Sat, 12 Jan 2008 21:22:34 +0000 (+0100) Subject: [BUG] connect_server: server might not exist when sending error report X-Git-Tag: v1.3.15~68 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=fe10a0619ddfe58d9dfbf9029a73651130843023;p=thirdparty%2Fhaproxy.git [BUG] connect_server: server might not exist when sending error report In connect_server(), we may send an alert with the server name while the server might not exist, eg in dispatch mode. --- diff --git a/src/backend.c b/src/backend.c index 5a6847fc81..039d51861c 100644 --- a/src/backend.c +++ b/src/backend.c @@ -1242,8 +1242,8 @@ int connect_server(struct session *s) Alert("Cannot bind to source address before connect() for proxy %s. Aborting.\n", s->be->id); close(fd); send_log(s->be, LOG_EMERG, - "Cannot bind to source address before connect() for server %s/%s.\n", - s->be->id, s->srv->id); + "Cannot bind to source address before connect() for proxy %s.\n", + s->be->id); return SN_ERR_RESOURCE; } #ifdef CONFIG_HAP_CTTPROXY @@ -1276,8 +1276,8 @@ int connect_server(struct session *s) s->be->id); close(fd); send_log(s->be, LOG_EMERG, - "Cannot bind to tproxy source address before connect() for server %s/%s.\n", - s->be->id, s->srv->id); + "Cannot bind to tproxy source address before connect() for proxy %s.\n", + s->be->id); return SN_ERR_RESOURCE; } }