You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by ol...@apache.org on 2007/04/23 08:53:21 UTC
svn commit: r531354 - in /jakarta/commons/proper/httpclient/trunk:
release_notes.txt src/java/org/apache/commons/httpclient/Cookie.java
Author: olegk
Date: Sun Apr 22 23:53:20 2007
New Revision: 531354
URL: http://svn.apache.org/viewvc?view=rev&rev=531354
Log:
HTTPCLIENT-645: Cookie#compare() changed to do a simple case-sensitive string comparison when comparing path attributes instead of using a static instance of RuleBasedCollator
Contributed by Oleg Kalnichevski
Reviewed by Roland Weber
Modified:
jakarta/commons/proper/httpclient/trunk/release_notes.txt
jakarta/commons/proper/httpclient/trunk/src/java/org/apache/commons/httpclient/Cookie.java
Modified: jakarta/commons/proper/httpclient/trunk/release_notes.txt
URL: http://svn.apache.org/viewvc/jakarta/commons/proper/httpclient/trunk/release_notes.txt?view=diff&rev=531354&r1=531353&r2=531354
==============================================================================
--- jakarta/commons/proper/httpclient/trunk/release_notes.txt (original)
+++ jakarta/commons/proper/httpclient/trunk/release_notes.txt Sun Apr 22 23:53:20 2007
@@ -1,3 +1,9 @@
+Changes since 3.1 RC 1
+
+* [HTTPCLIENT-645] - Cookie#compare() changed to do a simple case-sensitive string comparison
+ when comparing path attributes instead of using a static instance of RuleBasedCollator
+ Contributed by Oleg Kalnichevski <olegk at apache.org>
+
Release 3.1 RC 1
-------------------
New features:
Modified: jakarta/commons/proper/httpclient/trunk/src/java/org/apache/commons/httpclient/Cookie.java
URL: http://svn.apache.org/viewvc/jakarta/commons/proper/httpclient/trunk/src/java/org/apache/commons/httpclient/Cookie.java?view=diff&rev=531354&r1=531353&r2=531354
==============================================================================
--- jakarta/commons/proper/httpclient/trunk/src/java/org/apache/commons/httpclient/Cookie.java (original)
+++ jakarta/commons/proper/httpclient/trunk/src/java/org/apache/commons/httpclient/Cookie.java Sun Apr 22 23:53:20 2007
@@ -31,10 +31,8 @@
package org.apache.commons.httpclient;
import java.io.Serializable;
-import java.text.RuleBasedCollator;
import java.util.Comparator;
import java.util.Date;
-import java.util.Locale;
import org.apache.commons.httpclient.cookie.CookiePolicy;
import org.apache.commons.httpclient.cookie.CookieSpec;
@@ -482,7 +480,7 @@
return 1;
}
} else {
- return STRING_COLLATOR.compare(c1.getPath(), c2.getPath());
+ return c1.getPath().compareTo(c2.getPath());
}
}
@@ -530,14 +528,6 @@
private int cookieVersion = 0;
// -------------------------------------------------------------- Constants
-
- /**
- * Collator for Cookie comparisons. Could be replaced with references to
- * specific Locales.
- */
- private static final RuleBasedCollator STRING_COLLATOR =
- (RuleBasedCollator) RuleBasedCollator.getInstance(
- new Locale("en", "US", ""));
/** Log object for this class */
private static final Log LOG = LogFactory.getLog(Cookie.class);
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org