roller-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gango...@apache.org
Subject svn commit: r519980 - /incubator/roller/branches/roller_3.1/web/roller-ui/logout-redirect.jsp
Date Mon, 19 Mar 2007 16:04:43 GMT
Author: gangolli
Date: Mon Mar 19 09:04:42 2007
New Revision: 519980

URL: http://svn.apache.org/viewvc?view=rev&rev=519980
Log:
Integrated fix for ROL-1374.  Form cookie path properly.

Modified:
    incubator/roller/branches/roller_3.1/web/roller-ui/logout-redirect.jsp

Modified: incubator/roller/branches/roller_3.1/web/roller-ui/logout-redirect.jsp
URL: http://svn.apache.org/viewvc/incubator/roller/branches/roller_3.1/web/roller-ui/logout-redirect.jsp?view=diff&rev=519980&r1=519979&r2=519980
==============================================================================
--- incubator/roller/branches/roller_3.1/web/roller-ui/logout-redirect.jsp (original)
+++ incubator/roller/branches/roller_3.1/web/roller-ui/logout-redirect.jsp Mon Mar 19 09:04:42
2007
@@ -24,8 +24,10 @@
 request.getSession().removeAttribute(RollerSession.ROLLER_SESSION);
 request.getSession().invalidate(); 
 
+// Mimic exactly TokenBasedRememberMeServices.makeCancelCookie()
 Cookie terminate = new Cookie(TokenBasedRememberMeServices.ACEGI_SECURITY_HASHED_REMEMBER_ME_COOKIE_KEY,
null);
-terminate.setPath(request.getContextPath()+"/");
+String contextPath = request.getContextPath();
+terminate.setPath(contextPath != null && contextPath.length() > 0 ? contextPath
: "/");
 terminate.setMaxAge(0);
 response.addCookie(terminate);
 



Mime
View raw message