Skip to content

Commit

Permalink
Correctly parse cookies and print out page name on 404
Browse files Browse the repository at this point in the history
  • Loading branch information
vii committed Oct 24, 2010
1 parent a22c4f9 commit 3cf38ec
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/http/dispatcher.lisp
Expand Up @@ -26,8 +26,8 @@
(match-bind ( (* name "=" value (or (last) "&")
'(f name value)))
str)))
(parse-cookie-params (str)
(when str
(parse-cookie-params (cookies)
(loop for str in cookies do
(match-bind ( (* name "=" value (or (last) "," ";")
'(f name value)))
str))))
Expand Down Expand Up @@ -101,6 +101,7 @@
(setf (gethash (force-byte-vector path) (my paths)) (alexandria:ensure-function func)))

(my-defun dispatcher 'default-http-error-page ()
(format *trace-output* "~&Page ~A not found~&" (strcat (my canonical-name) (servestate-path*)))
(with-sendbuf ()
"<h1>I made a mistake. Sorry for the inconvenience.</h1>"))

Expand Down

0 comments on commit 3cf38ec

Please sign in to comment.