From f5dccc2e8e0cfbfce5cc0e08e8b16a43704484a3 Mon Sep 17 00:00:00 2001 From: Laurent Bercot Date: Tue, 22 Aug 2017 10:29:04 +0000 Subject: No need to save errno around fd_close --- src/libwpactrl/wpactrl_start.c | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) (limited to 'src/libwpactrl') diff --git a/src/libwpactrl/wpactrl_start.c b/src/libwpactrl/wpactrl_start.c index 80018d5..ac77870 100644 --- a/src/libwpactrl/wpactrl_start.c +++ b/src/libwpactrl/wpactrl_start.c @@ -34,17 +34,9 @@ int wpactrl_start (wpactrl_t *a, char const *path, unsigned int timeout, tain_t return 1 ; erra: - { - int e = errno ; - fd_close(fda) ; - errno = e ; - } + fd_close(fda) ; errs: - { - int e = errno ; - fd_close(fds) ; - errno = e ; - } + fd_close(fds) ; err: return 0 ; } -- cgit v1.2.3