Author: ivaynberg
Date: Sun Feb 1 17:49:11 2009
New Revision: 739798
URL: http://svn.apache.org/viewvc?rev=739798&view=rev
Log:
WICKET-1864
Modified:
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/protocol/http/MockHttpServletRequest.java
Modified:
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/protocol/http/MockHttpServletRequest.java
URL:
http://svn.apache.org/viewvc/wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/protocol/http/MockHttpServletRequest.java?rev=739798&r1=739797&r2=739798&view=diff
==============================================================================
---
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/protocol/http/MockHttpServletRequest.java
(original)
+++
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/protocol/http/MockHttpServletRequest.java
Sun Feb 1 17:49:11 2009
@@ -218,7 +218,7 @@
{
for (Iterator it = cookies.iterator(); it.hasNext();)
{
- Cookie cookie = (Cookie) it.next();
+ Cookie cookie = (Cookie)it.next();
addCookie(cookie);
}
}
@@ -1339,7 +1339,10 @@
// We need to absolutize the redirect URL as we are not as
smart as a web-browser
// (WICKET-702)
- url = getContextPath() + getServletPath() + "/" + redirect;
+ if (url.charAt(0) != '/')
+ {
+ url = getContextPath() + getServletPath() + "/" +
redirect;
+ }
// Remove occurrences of ".." from the path
url = RequestUtils.removeDoubleDots(url);