You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@cocoon.apache.org by an...@apache.org on 2005/07/31 09:14:07 UTC
svn commit: r226612 -
/cocoon/branches/BRANCH_2_1_X/src/java/org/apache/cocoon/components/modules/input/CookieModule.java
Author: antonio
Date: Sun Jul 31 00:14:02 2005
New Revision: 226612
URL: http://svn.apache.org/viewcvs?rev=226612&view=rev
Log:
Fix for Java 1.3.
Modified:
cocoon/branches/BRANCH_2_1_X/src/java/org/apache/cocoon/components/modules/input/CookieModule.java
Modified: cocoon/branches/BRANCH_2_1_X/src/java/org/apache/cocoon/components/modules/input/CookieModule.java
URL: http://svn.apache.org/viewcvs/cocoon/branches/BRANCH_2_1_X/src/java/org/apache/cocoon/components/modules/input/CookieModule.java?rev=226612&r1=226611&r2=226612&view=diff
==============================================================================
--- cocoon/branches/BRANCH_2_1_X/src/java/org/apache/cocoon/components/modules/input/CookieModule.java (original)
+++ cocoon/branches/BRANCH_2_1_X/src/java/org/apache/cocoon/components/modules/input/CookieModule.java Sun Jul 31 00:14:02 2005
@@ -27,6 +27,7 @@
import org.apache.cocoon.components.modules.input.AbstractInputModule;
import org.apache.cocoon.environment.ObjectModelHelper;
import org.apache.cocoon.environment.http.HttpCookie;
+import org.apache.regexp.RE;
/**
* Input module for cookies. Retrieves the value of the requested cookie.
@@ -78,9 +79,10 @@
Iterator it = allCookies.values().iterator();
List matched = new LinkedList();
+ RE regexp = new RE(name);
while (it.hasNext()) {
HttpCookie cookie = (HttpCookie) it.next();
- if (cookie.getName().matches(name)) {
+ if (regexp.match(cookie.getName())) {
matched.add(cookie.getValue());
}
}