[lttng-dev] [PATCH 2/2] liblttng-ust-comm/lttng-ust-com.c: remove unnecessary goto in ustcomm_accept_unix_sock()
Henrik Hautakoski
henrik at fiktivkod.org
Mon Jun 25 07:22:51 EDT 2012
Signed-off-by: Henrik Hautakoski <henrik at fiktivkod.org>
---
liblttng-ust-comm/lttng-ust-comm.c | 6 +-----
1 file changed, 1 insertion(+), 5 deletions(-)
diff --git a/liblttng-ust-comm/lttng-ust-comm.c b/liblttng-ust-comm/lttng-ust-comm.c
index 078b56a..1e2fd1a 100644
--- a/liblttng-ust-comm/lttng-ust-comm.c
+++ b/liblttng-ust-comm/lttng-ust-comm.c
@@ -172,13 +172,9 @@ int ustcomm_accept_unix_sock(int sock)
new_fd = accept(sock, (struct sockaddr *) &sun, &len);
if (new_fd < 0) {
perror("accept");
- goto error;
+ return -1;
}
-
return new_fd;
-
-error:
- return -1;
}
/*
--
1.7.9.5
More information about the lttng-dev
mailing list