]> matita.cs.unibo.it Git - helm.git/blobdiff - helm/DEVEL/ocaml-http/http_daemon.ml
debian version 0.6.3-2
[helm.git] / helm / DEVEL / ocaml-http / http_daemon.ml
index d089ce79cc3d7de55061bb761d70752935a4477b..f29b4c1d16390084af88c6268611e10a13ee7610 100644 (file)
@@ -2,7 +2,7 @@
 (*
   OCaml HTTP - do it yourself (fully OCaml) HTTP daemon
 
-  Copyright (C) <2002> Stefano Zacchiroli <zack@cs.unibo.it>
+  Copyright (C) <2002-2004> Stefano Zacchiroli <zack@cs.unibo.it>
 
   This program is free software; you can redistribute it and/or modify
   it under the terms of the GNU General Public License as published by
@@ -84,7 +84,7 @@ let foo_body code body =
 let send_foo_body code body = send_raw ~data:(foo_body code body)
 
   (* Warning: keep default values in sync with Http_response.response class *)
-let respond ?(body = "") ?(headers = []) ?version ~code outchan =
+let respond ?(body = "") ?(headers = []) ?version ?(code = `Code 200) outchan =
   send_basic_headers ?version ~code outchan;
   send_headers ~headers outchan;
   send_header "Content-Length" (string_of_int (String.length body)) outchan;