From 7f85143212b8e2e5b11055c97b083119a756a812 Mon Sep 17 00:00:00 2001 From: Jennifer Richards Date: Tue, 17 May 2016 15:53:20 -0400 Subject: [PATCH] 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. --- tid/tids.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) 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); } -- 2.1.4