commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject svn commit: r1325718 - in /commons/proper/net/trunk/src: changes/changes.xml main/java/org/apache/commons/net/ftp/parser/MVSFTPEntryParser.java
Date Fri, 13 Apr 2012 11:13:52 GMT
Author: sebb
Date: Fri Apr 13 11:13:51 2012
New Revision: 1325718

URL: http://svn.apache.org/viewvc?rev=1325718&view=rev
Log:
NET-458 MVSFTPEntryParser.parseSimpleEntry - ArrayIndexOutOfBoundsException

Modified:
    commons/proper/net/trunk/src/changes/changes.xml
    commons/proper/net/trunk/src/main/java/org/apache/commons/net/ftp/parser/MVSFTPEntryParser.java

Modified: commons/proper/net/trunk/src/changes/changes.xml
URL: http://svn.apache.org/viewvc/commons/proper/net/trunk/src/changes/changes.xml?rev=1325718&r1=1325717&r2=1325718&view=diff
==============================================================================
--- commons/proper/net/trunk/src/changes/changes.xml (original)
+++ commons/proper/net/trunk/src/changes/changes.xml Fri Apr 13 11:13:51 2012
@@ -65,6 +65,9 @@ The <action> type attribute can be add,u
         <release version="3.2" date="TBA" description="
 TBA
         ">
+            <action issue="NET-458" dev="sebb" type="fix" due-to="Denis Molony">
+            MVSFTPEntryParser.parseSimpleEntry - ArrayIndexOutOfBoundsException.
+            </action>
             <action issue="NET-450" dev="sebb" type="fix" due-to="Roger Hardiman">
             Bug in documentation for FTPClient.
             </action>

Modified: commons/proper/net/trunk/src/main/java/org/apache/commons/net/ftp/parser/MVSFTPEntryParser.java
URL: http://svn.apache.org/viewvc/commons/proper/net/trunk/src/main/java/org/apache/commons/net/ftp/parser/MVSFTPEntryParser.java?rev=1325718&r1=1325717&r2=1325718&view=diff
==============================================================================
--- commons/proper/net/trunk/src/main/java/org/apache/commons/net/ftp/parser/MVSFTPEntryParser.java
(original)
+++ commons/proper/net/trunk/src/main/java/org/apache/commons/net/ftp/parser/MVSFTPEntryParser.java
Fri Apr 13 11:13:51 2012
@@ -355,7 +355,7 @@ public class MVSFTPEntryParser extends C
      * @return
      */
     private boolean parseSimpleEntry(FTPFile file, String entry) {
-        if (entry != null && entry.length() > 0) {
+        if (entry != null && entry.trim().length() > 0) {
             file.setRawListing(entry);
             String name = entry.split(" ")[0];
             file.setName(name);



Mime
View raw message