[jboss-jira] [JBoss JIRA] Created: (JBJCA-322) get wrong filename from url string

Jeff Zhang (JIRA) jira-events at lists.jboss.org
Sun May 9 21:28:05 EDT 2010


get wrong filename from url string
----------------------------------

                 Key: JBJCA-322
                 URL: https://jira.jboss.org/jira/browse/JBJCA-322
             Project: JBoss JCA
          Issue Type: Bug
          Components: Deployer
            Reporter: Jeff Zhang
            Assignee: Jeff Zhang
             Fix For: 1.0.0.Alpha12


In the deployer and validator, we use the code to get the filename from url string, like:

            int lastIndex = urlFileName.lastIndexOf(File.separator);
            if (lastIndex != -1)
               urlFileName = urlFileName.substring(lastIndex + 1);
            urlFileName += ".log";

here is a bug. in the windows machine, File.separator) is "\", but the url.getPath is always return like "file://c/dir/filename", that we get wrong filename

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the jboss-jira mailing list