You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by gg...@apache.org on 2016/05/11 21:11:33 UTC
svn commit: r1743432 -
/commons/proper/csv/trunk/src/main/java/org/apache/commons/csv/CSVFormat.java
Author: ggregory
Date: Wed May 11 21:11:32 2016
New Revision: 1743432
URL: http://svn.apache.org/viewvc?rev=1743432&view=rev
Log:
Reuse constant instead of magic char.
Modified:
commons/proper/csv/trunk/src/main/java/org/apache/commons/csv/CSVFormat.java
Modified: commons/proper/csv/trunk/src/main/java/org/apache/commons/csv/CSVFormat.java
URL: http://svn.apache.org/viewvc/commons/proper/csv/trunk/src/main/java/org/apache/commons/csv/CSVFormat.java?rev=1743432&r1=1743431&r2=1743432&view=diff
==============================================================================
--- commons/proper/csv/trunk/src/main/java/org/apache/commons/csv/CSVFormat.java (original)
+++ commons/proper/csv/trunk/src/main/java/org/apache/commons/csv/CSVFormat.java Wed May 11 21:11:32 2016
@@ -1164,10 +1164,10 @@ public final class CSVFormat implements
int len = count;
int pos = 0;
- while (pos < len && charSequence.charAt(pos) <= ' ') {
+ while (pos < len && charSequence.charAt(pos) <= Constants.SP) {
pos++;
}
- while (pos < len && charSequence.charAt(len - 1) <= ' ') {
+ while (pos < len && charSequence.charAt(len - 1) <= Constants.SP) {
len--;
}
return pos > 0 || len < count ? charSequence.subSequence(pos, len) : charSequence;