commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rwins...@apache.org
Subject svn commit: r637643 - in /commons/proper/net/trunk/src: java/org/apache/commons/net/ftp/parser/UnixFTPEntryParser.java test/org/apache/commons/net/ftp/parser/UnixFTPEntryParserTest.java
Date Sun, 16 Mar 2008 20:19:52 GMT
Author: rwinston
Date: Sun Mar 16 13:19:52 2008
New Revision: 637643

URL: http://svn.apache.org/viewvc?rev=637643&view=rev
Log:
NET-201

Modified:
    commons/proper/net/trunk/src/java/org/apache/commons/net/ftp/parser/UnixFTPEntryParser.java
    commons/proper/net/trunk/src/test/org/apache/commons/net/ftp/parser/UnixFTPEntryParserTest.java

Modified: commons/proper/net/trunk/src/java/org/apache/commons/net/ftp/parser/UnixFTPEntryParser.java
URL: http://svn.apache.org/viewvc/commons/proper/net/trunk/src/java/org/apache/commons/net/ftp/parser/UnixFTPEntryParser.java?rev=637643&r1=637642&r2=637643&view=diff
==============================================================================
--- commons/proper/net/trunk/src/java/org/apache/commons/net/ftp/parser/UnixFTPEntryParser.java
(original)
+++ commons/proper/net/trunk/src/java/org/apache/commons/net/ftp/parser/UnixFTPEntryParser.java
Sun Mar 16 13:19:52 2008
@@ -91,7 +91,7 @@
         + "(\\d+)\\s+"
         + "(\\S+)\\s+"
         + "(?:(\\S+(?:\\s\\S+)*)\\s+)?"
-        + "(\\d+)\\s+"
+        + "(\\d+(?:,\\s*\\d+)?)\\s+"
         
         /*
           numeric or standard format date

Modified: commons/proper/net/trunk/src/test/org/apache/commons/net/ftp/parser/UnixFTPEntryParserTest.java
URL: http://svn.apache.org/viewvc/commons/proper/net/trunk/src/test/org/apache/commons/net/ftp/parser/UnixFTPEntryParserTest.java?rev=637643&r1=637642&r2=637643&view=diff
==============================================================================
--- commons/proper/net/trunk/src/test/org/apache/commons/net/ftp/parser/UnixFTPEntryParserTest.java
(original)
+++ commons/proper/net/trunk/src/test/org/apache/commons/net/ftp/parser/UnixFTPEntryParserTest.java
Sun Mar 16 13:19:52 2008
@@ -72,7 +72,9 @@
 			"drwxrwx---+ 23 500     500    0 Jan 10 13:09 testACL",
 			"-rw-r--r--   1 1        3518644 May 25 12:12 std",
             "lrwxrwxrwx   1 neeme neeme             23 Mar  2 18:06 macros -> ./../../global/macros/.",
-			"-rw-r--r--   1 ftp      group with spaces in it as allowed in cygwin see bug 38634  
83853 Jan 22  2001 zxJDBC-1.2.4.tar.gz"
+			"-rw-r--r--   1 ftp      group with spaces in it as allowed in cygwin see bug 38634  
83853 Jan 22  2001 zxJDBC-1.2.4.tar.gz",
+			"crw-r----- 1 root kmem 0, 27 Jan 30 11:42 kmem",  //FreeBSD device
+			"crw-------   1 root     sys      109,767 Jul  2  2004 pci@1c,600000:devctl" //Solaris
device
 
 
 		};
@@ -283,8 +285,8 @@
                 int pos = 3*access + perm + 1;
                 char permchar = test.charAt(pos);
                 assertEquals("Permission " + test.substring(1,10), 
-                        f.hasPermission(access, perm), 
-                        permchar != '-' && !Character.isUpperCase(permchar)); 
+                        new Boolean(f.hasPermission(access, perm)), 
+                        new Boolean(permchar != '-' && !Character.isUpperCase(permchar)));

             }
         }
 



Mime
View raw message