commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 20259] New: - Parsing error
Date Tue, 27 May 2003 09:44:33 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=20259>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=20259

Parsing error

           Summary: Parsing error
           Product: Commons
           Version: 1.0.1 Final
          Platform: PC
        OS/Version: Windows NT/2K
            Status: NEW
          Severity: Normal
          Priority: Other
         Component: Net
        AssignedTo: commons-dev@jakarta.apache.org
        ReportedBy: lchiesa2000@yahoo.it


The NTFTPEntryParser parsing  a row in not correct mode  of "dir" when the 
filename starts with a number. In such case the number is cut by the name and 
maybe interpreted as size of the file.
I patched the problem specifing in the regular expression of the row that the 
number must be followed by at least a space to be interpreted as size of the 
file and not as part of the name.
However if the filename contains more words and the first word is a number the 
problem also appears

My Patch:
Before of the correction 
     private static final String REGEX =
       ..................
        + "([0-9]+)?\\s*" 
        + "(\\S.*)";

After the correction
    private static final String REGEX =
         ........
        + "([0-9]+)?\\s+"     <--- Here the correction
        + "(\\S.*)";


Best Regards
Luca Chiesa

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org


Mime
View raw message