mirror of
https://github.com/c-cube/tiny_httpd.git
synced 2025-12-06 03:05:29 -05:00
fix warnings
This commit is contained in:
parent
e177153f10
commit
75d90559bd
1 changed files with 6 additions and 8 deletions
|
|
@ -1,7 +1,5 @@
|
|||
module S = Tiny_httpd
|
||||
module U = Tiny_httpd.Util
|
||||
module D = Tiny_httpd.Dir
|
||||
module Pf = Printf
|
||||
module Log = Tiny_httpd.Log
|
||||
|
||||
let serve ~config ~timeout (dir : string) addr port j : _ result =
|
||||
|
|
@ -9,9 +7,9 @@ let serve ~config ~timeout (dir : string) addr port j : _ result =
|
|||
let after_init () =
|
||||
Printf.printf "serve directory %s on http://%(%s%):%d\n%!" dir
|
||||
(if S.is_ipv6 server then
|
||||
"[%s]"
|
||||
else
|
||||
"%s")
|
||||
"[%s]"
|
||||
else
|
||||
"%s")
|
||||
addr (S.port server)
|
||||
in
|
||||
|
||||
|
|
@ -63,9 +61,9 @@ let main () =
|
|||
(fun b ->
|
||||
config.dir_behavior <-
|
||||
(if b then
|
||||
Index_or_lists
|
||||
else
|
||||
Lists)),
|
||||
Index_or_lists
|
||||
else
|
||||
Lists)),
|
||||
" <bool> automatically redirect to index.html if present" );
|
||||
( "--delete",
|
||||
Unit (fun () -> config.delete <- true),
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue