From 69e52df19b3290d6eb71087657a08a2d520e27e5 Mon Sep 17 00:00:00 2001 From: David Goulet Date: Fri, 5 Jul 2013 12:01:10 -0400 Subject: [PATCH] Fix: print errno message on connect() error Signed-off-by: David Goulet --- src/common/sessiond-comm/inet.c | 5 +---- src/common/sessiond-comm/inet6.c | 5 +---- 2 files changed, 2 insertions(+), 8 deletions(-) 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; } -- 2.34.1