remove redundant error-handling block
authorAndy Wingo <wingo@pobox.com>
Fri, 3 Dec 2010 15:41:46 +0000 (16:41 +0100)
committerAndy Wingo <wingo@pobox.com>
Fri, 3 Dec 2010 15:41:46 +0000 (16:41 +0100)
* module/web/server/http.scm (http-read): No need for a
  call-with-error-handling block here, as the read impl is itself within
  an error-handling block.

module/web/server/http.scm

index 7d63a70..5d03f76 100644 (file)
@@ -26,8 +26,7 @@
   #:use-module (web request)
   #:use-module (web response)
   #:use-module (web server)
-  #:use-module (ice-9 poll)
-  #:use-module (system repl error-handling))
+  #:use-module (ice-9 poll))
 
 
 (define (make-default-socket family addr port)
               ;; Otherwise, try to read a request from this port.
               ;; Record the next index.
               (set-http-poll-idx! server (1- idx))
-              (call-with-error-handling
-               (lambda ()
-                 (let ((req (read-request port)))
-                   ;; Block buffering for reading body and writing response.
-                   (setvbuf port _IOFBF)
-                   (values port
-                           req
-                           (read-request-body/latin-1 req))))
-               #:pass-keys '(quit interrupt)
-               #:on-error (if (batch-mode?) 'pass 'debug)
-               #:post-error
-               (lambda (k . args)
-                 (warn "Error while reading request" k args)
-                 (values #f #f #f))))))))))))
+              (let ((req (read-request port)))
+                ;; Block buffering for reading body and writing response.
+                (setvbuf port _IOFBF)
+                (values port
+                        req
+                        (read-request-body/latin-1 req))))))))))))
 
 (define (keep-alive? response)
   (let ((v (response-version response)))