Properly set up logging port.

This commit is contained in:
sperber 2002-02-21 15:09:26 +00:00
parent 0cbe13d177
commit 5e1193c60a
1 changed files with 7 additions and 1 deletions

View File

@ -49,8 +49,13 @@
(set! server/admin s))
(define *http-log?* #t)
(define *http-log-port* (current-error-port))
(define *http-log-port* #f)
(define (init-http-log!)
(set! *http-log-port* (current-error-port)))
(define (http-log fmt . args)
(if *http-log?*
(begin
@ -69,6 +74,7 @@
(define (httpd path-handler . args)
(let-optionals args ((port 80)
(root-dir "/usr/local/etc/httpd"))
(init-http-log!)
(with-cwd root-dir
(bind-listen-accept-loop protocol-family/internet