From: Pierre Habouzit Date: Thu, 29 Nov 2007 10:19:31 +0000 (+0100) Subject: simplifications X-Git-Url: http://git.madism.org/?a=commitdiff_plain;h=a194fbf7f797ef3f5fea492687970f445a17c58f;p=apps%2Fpfixtools.git simplifications Signed-off-by: Pierre Habouzit --- diff --git a/main-srsd.c b/main-srsd.c index 8d703af..bcf9fea 100644 --- a/main-srsd.c +++ b/main-srsd.c @@ -228,8 +228,6 @@ void usage(void) int main_loop(srs_t *srs, const char *domain, int port_enc, int port_dec) { - int exitcode = EXIT_SUCCESS; - if (start_listener(port_enc, false) < 0) return EXIT_FAILURE; if (start_listener(port_dec, true) < 0) @@ -243,8 +241,7 @@ int main_loop(srs_t *srs, const char *domain, int port_enc, int port_dec) if (n < 0) { if (errno != EAGAIN && errno != EINTR) { UNIXERR("epoll_wait"); - exitcode = EXIT_FAILURE; - break; + return EXIT_FAILURE; } continue; } @@ -318,7 +315,7 @@ int main_loop(srs_t *srs, const char *domain, int port_enc, int port_dec) } } - return exitcode; + return EXIT_SUCCESS; } static srs_t *srs_read_secrets(const char *sfile)