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.
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,
close(listen);
tids_handle_connection(tids, conn);
close(conn);
- return 0;
+ exit(0); /* exit to kill forked child process */
} else {
close(conn);
}