commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rwins...@apache.org
Subject svn commit: r920203 - /commons/proper/net/branches/NET_2_0/src/main/java/org/apache/commons/net/ftp/FTPClient.java
Date Mon, 08 Mar 2010 06:14:46 GMT
Author: rwinston
Date: Mon Mar  8 06:14:46 2010
New Revision: 920203

URL: http://svn.apache.org/viewvc?rev=920203&view=rev
Log:
Fixed NET-300

Modified:
    commons/proper/net/branches/NET_2_0/src/main/java/org/apache/commons/net/ftp/FTPClient.java

Modified: commons/proper/net/branches/NET_2_0/src/main/java/org/apache/commons/net/ftp/FTPClient.java
URL: http://svn.apache.org/viewvc/commons/proper/net/branches/NET_2_0/src/main/java/org/apache/commons/net/ftp/FTPClient.java?rev=920203&r1=920202&r2=920203&view=diff
==============================================================================
--- commons/proper/net/branches/NET_2_0/src/main/java/org/apache/commons/net/ftp/FTPClient.java
(original)
+++ commons/proper/net/branches/NET_2_0/src/main/java/org/apache/commons/net/ftp/FTPClient.java
Mon Mar  8 06:14:46 2010
@@ -2335,10 +2335,17 @@
     protected String getListArguments(String pathname) {
         if (getListHiddenFiles())
         {
-            StringBuffer sb = new StringBuffer(pathname.length() + 3);
-            sb.append("-a ");
-            sb.append(pathname);
-            return sb.toString();
+            if (pathname != null)
+            {
+                StringBuffer sb = new StringBuffer(pathname.length() + 3);
+                sb.append("-a ");
+                sb.append(pathname);
+                return sb.toString();
+            }
+            else
+            {
+                return "-a";
+            }
         }
         
         return pathname;



Mime
View raw message