From 2eff3872d9e65ffe12f654aa1feff78ccb2953c6 Mon Sep 17 00:00:00 2001 From: Stefano Zacchiroli Date: Wed, 12 Mar 2003 17:24:01 +0000 Subject: [PATCH] removed an ancient debugging message --- helm/uwobo/src/ocaml/uwobo.ml | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/helm/uwobo/src/ocaml/uwobo.ml b/helm/uwobo/src/ocaml/uwobo.ml index bea96a2a0..741b8d20f 100644 --- a/helm/uwobo/src/ocaml/uwobo.ml +++ b/helm/uwobo/src/ocaml/uwobo.ml @@ -131,7 +131,7 @@ let (add_cmd_RE, remove_cmd_RE, reload_cmd_RE) = exception Restart_HTTP_daemon;; - (* thread action + (* reuquest handler action @param syslogger Uwobo_logger.sysLogger instance used for logginf @param styles Uwobo_styles.styles instance which keeps the stylesheets list @param cmd_pipe output _channel_ used to _write_ update messages @@ -199,12 +199,7 @@ let callback return_error (sprintf "Stylesheet chain application failed: %s" errmsg) outchan) - | "/help" -> - output_string cmd_pipe "test\n"; - flush cmd_pipe; - debug_print - (sprintf "Grandchild: grandparent said '%s'" (input_line res_pipe)); - Http_daemon.respond ~body:usage_string outchan + | "/help" -> Http_daemon.respond ~body:usage_string outchan | invalid_request -> Http_daemon.respond_error ~status:(`Client_error `Bad_request) outchan); syslogger#log `Debug (sprintf "%s done!" req#path); @@ -332,6 +327,8 @@ let main () = let cmd_pipe = Unix.out_channel_of_descr cmd_pipe_entrance in let res_pipe = Unix.in_channel_of_descr res_pipe_exit in debug_print "Starting HTTP daemon ..."; + (* next invocation doesn't return, process will keep on serving HTTP + requests until it will get killed by father *) Http_daemon.start'~port ~mode:`Fork (callback ~syslogger ~styles ~cmd_pipe ~res_pipe ()) | _ (* < 0 *) -> (* fork failed :-((( *) @@ -345,4 +342,3 @@ try main () with Sys.Break -> () (* 'die_nice' registered with at_exit *) - -- 2.39.2