From: David Goulet Date: Fri, 5 Jul 2013 16:01:10 +0000 (-0400) Subject: Fix: print errno message on connect() error X-Git-Tag: v2.3.0-rc1~73 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=82c05d47612bcecbf55b348a5a2b5f249db8a9f2;p=lttng-tools.git Fix: print errno message on connect() error Signed-off-by: David Goulet --- diff --git a/src/common/sessiond-comm/inet.c b/src/common/sessiond-comm/inet.c index f55482e42..b2bd65d90 100644 --- a/src/common/sessiond-comm/inet.c +++ b/src/common/sessiond-comm/inet.c @@ -102,10 +102,7 @@ int lttcomm_connect_inet_sock(struct lttcomm_sock *sock) ret = connect(sock->fd, (struct sockaddr *) &sock->sockaddr.addr.sin, sizeof(sock->sockaddr.addr.sin)); if (ret < 0) { - /* - * Don't print message on connect error, because connect is used in - * normal execution to detect if sessiond is alive. - */ + PERROR("connect"); goto error_connect; } diff --git a/src/common/sessiond-comm/inet6.c b/src/common/sessiond-comm/inet6.c index e9558d948..8d8837404 100644 --- a/src/common/sessiond-comm/inet6.c +++ b/src/common/sessiond-comm/inet6.c @@ -102,10 +102,7 @@ int lttcomm_connect_inet6_sock(struct lttcomm_sock *sock) ret = connect(sock->fd, (struct sockaddr *) &sock->sockaddr.addr.sin6, sizeof(sock->sockaddr.addr.sin6)); if (ret < 0) { - /* - * Don't print message on connect error, because connect is used in - * normal execution to detect if sessiond is alive. - */ + PERROR("connect inet6"); goto error_connect; }