commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bruno P. Kinoshita (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (IO-552) FilenameUtils.concat fails if second argument (fullFilenameToAdd) starts with '~' (tilde)
Date Thu, 12 Oct 2017 07:23:00 GMT

    [ https://issues.apache.org/jira/browse/IO-552?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16201556#comment-16201556
] 

Bruno P. Kinoshita commented on IO-552:
---------------------------------------

FWIW, checked out the latest code, quickly tried the provided sample code, and successfully
reproduced the issue.

> FilenameUtils.concat fails if second argument (fullFilenameToAdd) starts with '~' (tilde)
> -----------------------------------------------------------------------------------------
>
>                 Key: IO-552
>                 URL: https://issues.apache.org/jira/browse/IO-552
>             Project: Commons IO
>          Issue Type: Bug
>          Components: Utilities
>    Affects Versions: 2.2, 2.5
>         Environment: Windows 7 64bit, JavaVM 1.8 32bit
>            Reporter: Jochen Tümmers
>            Priority: Critical
>
> {{FilenameUtils.concat("c:/temp", "~abc.txt") returns "~abc.txt/" instead of "c:/temp/~abc.txt".}}
> As a result, the file would be created in the user's home directory instead of c:/temp.
> (Note: I Had to replace all instances of double backslashes that would normally appear
in the java code with forward slashes as the editor cannot handle backslashes properly.)
> commons io 2.2. and 2.5 behave the same. 2.3 and 2.4 not tested.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Mime
View raw message