X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=helm%2FDEVEL%2Focaml-http%2Fexamples%2Fclient_address.ml;h=79d4ff836420f5f69c91b302acd8330827cba274;hb=97c2d258a5c524eb5c4b85208899d80751a2c82f;hp=0f5c68d2c4ff87798cf7ac5469317290967b87e7;hpb=2228717a5f41aab3b157713e40753016ad46c2ae;p=helm.git diff --git a/helm/DEVEL/ocaml-http/examples/client_address.ml b/helm/DEVEL/ocaml-http/examples/client_address.ml index 0f5c68d2c..79d4ff836 100644 --- a/helm/DEVEL/ocaml-http/examples/client_address.ml +++ b/helm/DEVEL/ocaml-http/examples/client_address.ml @@ -19,7 +19,8 @@ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA *) -open Printf;; +open Printf +open Http_types let callback req outchan = let body = @@ -30,5 +31,12 @@ let callback req outchan = in let res = new Http_response.response ~body () in Http_daemon.respond_with res outchan -in -Http_daemon.start' ~port:9999 callback + +let spec = + { Http_daemon.default_spec with + callback = callback; + port = 9999 + } + +let _ = Http_daemon.main spec +