You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Tom Caruso (JIRA)" <ji...@apache.org> on 2008/02/14 21:01:11 UTC

[jira] Created: (NET-184) FtpClient.listFiles truncates directory name beginning with a number

FtpClient.listFiles truncates directory name beginning with a number
--------------------------------------------------------------------

                 Key: NET-184
                 URL: https://issues.apache.org/jira/browse/NET-184
             Project: Commons Net
          Issue Type: Bug
    Affects Versions: 1.4
         Environment: Local is Unix (AIX), remote is Windows 
            Reporter: Tom Caruso


I used FtpClient.listFiles() to get a listing of all files in the current working directory on a remote Windows server.  If a remote directory begins with a number followed by a space and more text (e.g., 2008 Rates) the name returned by FTPFile.getName() has the leading number truncated (so '2008 Rates' would be 'Rates').  Examining the value returned by FTPFile.toString() or getRawListing() both show the full file name, but the name returned by getName() is truncated.

If the directory begins with a number and is not followed by a space (e.g., 2008_Rates) the correct name is returned by getName().  If there is a number after the test (like'Rates for 2008') the correct name is returned by getName().

Files do not appear to be affected by this.  The getName() function returns the correct name regardless of  the position of a number or the white space aorund it.



-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Closed: (NET-184) FtpClient.listFiles truncates directory name beginning with a number

Posted by "Rory Winston (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/NET-184?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Rory Winston closed NET-184.
----------------------------

       Resolution: Fixed
    Fix Version/s: 2.0

This has been fixed in 2.0. 


> FtpClient.listFiles truncates directory name beginning with a number
> --------------------------------------------------------------------
>
>                 Key: NET-184
>                 URL: https://issues.apache.org/jira/browse/NET-184
>             Project: Commons Net
>          Issue Type: Bug
>    Affects Versions: 1.4
>         Environment: Local is Unix (AIX), remote is Windows 
>            Reporter: Tom Caruso
>             Fix For: 2.0
>
>
> I used FtpClient.listFiles() to get a listing of all files in the current working directory on a remote Windows server.  If a remote directory begins with a number followed by a space and more text (e.g., 2008 Rates) the name returned by FTPFile.getName() has the leading number truncated (so '2008 Rates' would be 'Rates').  Examining the value returned by FTPFile.toString() or getRawListing() both show the full file name, but the name returned by getName() is truncated.
> If the directory begins with a number and is not followed by a space (e.g., 2008_Rates) the correct name is returned by getName().  If there is a number after the test (like'Rates for 2008') the correct name is returned by getName().
> Files do not appear to be affected by this.  The getName() function returns the correct name regardless of  the position of a number or the white space aorund it.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.