[claw-cvs] r148 - trunk/main/claw-as/src

Andrea Chiumenti achiumenti at common-lisp.net
Wed Nov 19 22:36:18 UTC 2008


Author: achiumenti
Date: Wed Nov 19 22:36:18 2008
New Revision: 148

Log:
redirect-to-https bugfix (when no ssl port is defined)


Modified:
   trunk/main/claw-as/src/lisplet.lisp

Modified: trunk/main/claw-as/src/lisplet.lisp
==============================================================================
--- trunk/main/claw-as/src/lisplet.lisp	(original)
+++ trunk/main/claw-as/src/lisplet.lisp	Wed Nov 19 22:36:18 2008
@@ -232,11 +232,13 @@
   "Redirects a request sent through http using https"
   (let* ((connector (clawserver-connector *clawserver*))
          (path (or uri (claw-request-uri)))
-         (sslport (if (claw-proxified-p)
-                      (clawserver-proxy-https-port *clawserver*)
-                      (connector-sslport connector))))
-    (claw-redirect path :host (claw-host-name) :port sslport
-                   :protocol :https)))
+         (sslport (and (connector-sslport connector) (if (claw-proxified-p)
+                                                         (clawserver-proxy-https-port *clawserver*)
+                                                         (connector-sslport connector)))))
+    (claw-redirect path :host (claw-host-name) :port (or sslport (connector-port connector))
+                   :protocol (if sslport
+                                 :https
+                                 :http))))
 
 (defmethod lisplet-check-authorization ((lisplet lisplet))
   (let* ((connector (clawserver-connector *clawserver*))




More information about the Claw-cvs mailing list