From 91e87c5f0501e37f9513b8391bffc91ac7da93d0 Mon Sep 17 00:00:00 2001 From: Cedric BAIL Date: Tue, 18 Apr 2017 16:57:36 -0700 Subject: [PATCH] ecore: use new API eina_file_close_on_exec in example too. --- src/examples/ecore/ecore_fd_handler_gnutls_example.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/examples/ecore/ecore_fd_handler_gnutls_example.c b/src/examples/ecore/ecore_fd_handler_gnutls_example.c index aa8ff3a..d1d58d9 100644 --- a/src/examples/ecore/ecore_fd_handler_gnutls_example.c +++ b/src/examples/ecore/ecore_fd_handler_gnutls_example.c @@ -94,7 +94,7 @@ tcp_connect(void) /* sets some fd options such as nonblock */ sd = socket(AF_INET, SOCK_STREAM, 0); fcntl(sd, F_SETFL, O_NONBLOCK); - fcntl(sd, F_SETFD, FD_CLOEXEC); + eina_file_close_on_exec(sd, EINA_TRUE); setsockopt(sd, SOL_SOCKET, SO_REUSEADDR, (const void *)&curstate, sizeof(curstate)); setsockopt(sd, IPPROTO_TCP, TCP_NODELAY, (char *)&flag, sizeof(int)); -- 2.7.4