Skip to content

Commit

Permalink
fixed a bug that Clack wouldn't run on port 80.
Browse files Browse the repository at this point in the history
  • Loading branch information
fukamachi committed Jun 13, 2011
1 parent c0696ff commit 1a7c3ac
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
5 changes: 3 additions & 2 deletions src/core/handler/apache.lisp
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -49,8 +49,9 @@ This function is called on each request."
(defun command->plist (command) (defun command->plist (command)
(bind ((url (ml:header-value command :url)) (bind ((url (ml:header-value command :url))
(pos (position #\? url)) (pos (position #\? url))
((server-name server-port) ((server-name &optional (server-port "80"))
(split-sequence #\: (ml:header-value command :host)))) (split-sequence #\: (ml:header-value command :host)
:from-end t)))
(append (append
(list (list
:request-method (ml:header-value command :method) :request-method (ml:header-value command :method)
Expand Down
2 changes: 1 addition & 1 deletion src/core/handler/hunchentoot.lisp
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ before pass to Hunchentoot."
(defun request->plist (req) (defun request->plist (req)
"Convert Request from server into a plist "Convert Request from server into a plist
before pass to Clack application." before pass to Clack application."
(destructuring-bind (server-name server-port) (destructuring-bind (server-name &optional (server-port "80"))
(split-sequence #\: (host req) :from-end t) (split-sequence #\: (host req) :from-end t)
(append (append
(list (list
Expand Down

0 comments on commit 1a7c3ac

Please sign in to comment.