From: Jennifer Richards Date: Tue, 17 May 2016 19:53:20 +0000 (-0400) Subject: Avoid error message after handling TID req. X-Git-Tag: v1.5.2~3 X-Git-Url: http://www.project-moonshot.org/gitweb/?p=trust_router.git;a=commitdiff_plain;h=7f85143212b8e2e5b11055c97b083119a756a812 Avoid error message after handling TID req. Replace the return 0 with an exit(0) after a forked subprocess finishes handling a request. This prevents an erroneous error message from indicating that the tids server has unexpectedly exited. --- diff --git a/tid/tids.c b/tid/tids.c index b9e2430..eb081dd 100644 --- a/tid/tids.c +++ b/tid/tids.c @@ -372,6 +372,7 @@ TIDS_INSTANCE *tids_create (void) return tids; } +/* Process tids requests forever. Should not return except on error. */ int tids_start (TIDS_INSTANCE *tids, TIDS_REQ_FUNC *req_handler, tids_auth_func *auth_handler, @@ -411,7 +412,7 @@ int tids_start (TIDS_INSTANCE *tids, close(listen); tids_handle_connection(tids, conn); close(conn); - return 0; + exit(0); /* exit to kill forked child process */ } else { close(conn); }