use log-line for connection errors, announce shutting down and kill web-server when it happens

svn: r17433
This commit is contained in:
Eli Barzilay 2009-12-30 11:01:36 +00:00
parent 1f4184206a
commit 66aa708427

View File

@ -693,11 +693,15 @@
(close-output-port w)))))))
#f ; `with-watcher' handles our timeouts
(lambda (exn)
(printf "~a\n" (if (exn? exn) (exn-message exn) exn)))
(log-line "ERROR: ~a" (if (exn? exn) (exn-message exn) exn)))
(lambda (port-k cnt reuse?)
(let ([l (ssl-listen port-k cnt #t)])
(ssl-load-certificate-chain! l "server-cert.pem")
(ssl-load-private-key! l "private-key.pem")
(start-notify)
l))
ssl-close ssl-accept ssl-accept/enable-break))
(lambda (l)
(log-line "shutting down")
(stop-status)
(ssl-close l))
ssl-accept ssl-accept/enable-break))