You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@myfaces.apache.org by "Jayson Raymond (JIRA)" <de...@myfaces.apache.org> on 2008/01/16 05:27:35 UTC
[jira] Created: (TOMAHAWK-1176) XmlTemplate fails when filename
contains spaces on WindowsXP
XmlTemplate fails when filename contains spaces on WindowsXP
------------------------------------------------------------
Key: TOMAHAWK-1176
URL: https://issues.apache.org/jira/browse/TOMAHAWK-1176
Project: MyFaces Tomahawk
Issue Type: Bug
Components: XmlTemplate
Affects Versions: 1.1.7-SNAPSHOT
Environment: Windows XP SP2
Reporter: Jayson Raymond
Fix For: 1.1.7-SNAPSHOT
XmlTemplate uses URLs. From this it extracts the filename and uses this to load a file. WindowsXP at least doesn't understand the %20 encoding for spaces in a filename. Attached patch replaces instances of %20 in URL filepath with " " in filepath use to open file.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (TOMAHAWK-1176) XmlTemplate fails when filename
contains spaces on WindowsXP
Posted by "Leonardo Uribe (JIRA)" <de...@myfaces.apache.org>.
[ https://issues.apache.org/jira/browse/TOMAHAWK-1176?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12572664#action_12572664 ]
Leonardo Uribe commented on TOMAHAWK-1176:
------------------------------------------
The patch works but it has several drawbacks
Better is use
new FileInputStream(new File(URI.create(url.toString())))
on every call to a file instead. This solution was tested on windows and works well.
> XmlTemplate fails when filename contains spaces on WindowsXP
> ------------------------------------------------------------
>
> Key: TOMAHAWK-1176
> URL: https://issues.apache.org/jira/browse/TOMAHAWK-1176
> Project: MyFaces Tomahawk
> Issue Type: Bug
> Components: XmlTemplate
> Affects Versions: 1.1.7-SNAPSHOT
> Environment: Windows XP SP2
> Reporter: Jayson Raymond
> Assignee: Leonardo Uribe
> Fix For: 1.1.7-SNAPSHOT
>
> Attachments: XmlTemplate-472727-patch.txt, XmlTemplateTest-508758-patch.txt
>
>
> XmlTemplate uses URLs. From this it extracts the filename and uses this to load a file. WindowsXP at least doesn't understand the %20 encoding for spaces in a filename. Attached patch replaces instances of %20 in URL filepath with " " in filepath use to open file.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.