diff --git a/src/handler/fcgi.lisp b/src/handler/fcgi.lisp index f08892eb..c0bde46c 100644 --- a/src/handler/fcgi.lisp +++ b/src/handler/fcgi.lisp @@ -48,7 +48,10 @@ (flet ((main-loop (req) (let* ((env (handle-request req)) (res (if debug - (funcall app env) + (restart-case + (funcall app env) + (throw-internal-server-error () + '(500 () ("Internal Server Error")))) (handler-case (funcall app env) (error (error) (princ error *error-output*) diff --git a/src/handler/toot.lisp b/src/handler/toot.lisp index 66e1d8b1..33df6456 100644 --- a/src/handler/toot.lisp +++ b/src/handler/toot.lisp @@ -39,7 +39,10 @@ (handle-response req (if debug - (funcall app env) + (restart-case + (funcall app env) + (throw-internal-server-error () + '(500 () ("Internal Server Error")))) (handler-case (funcall app env) (error (error) (princ error *error-output*) diff --git a/src/handler/wookie.lisp b/src/handler/wookie.lisp index 797ce6d1..1a3a660a 100644 --- a/src/handler/wookie.lisp +++ b/src/handler/wookie.lisp @@ -68,7 +68,10 @@ (handle-response res (if debug - (funcall app env) + (restart-case + (funcall app env) + (throw-internal-server-error () + '(500 nil ("Internal Server Error")))) (handler-case (funcall app env) (error (error) (princ error *error-output*)