ASF Bugzilla – Attachment 24012 Details for
Bug 47122
Hyperlinks to a directory containing a %20 space are not correctly handled
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
possible fix (for PDF output)
b47122.patch (text/plain), 1.61 KB, created by
Andreas L. Delmelle
on 2009-07-21 03:13:51 UTC
(
hide
)
Description:
possible fix (for PDF output)
Filename:
MIME Type:
Creator:
Andreas L. Delmelle
Created:
2009-07-21 03:13:51 UTC
Size:
1.61 KB
patch
obsolete
>Index: src/java/org/apache/fop/render/intermediate/extensions/URIAction.java >=================================================================== >--- src/java/org/apache/fop/render/intermediate/extensions/URIAction.java (revision 746664) >+++ src/java/org/apache/fop/render/intermediate/extensions/URIAction.java Tue Jul 21 11:58:30 CEST 2009 >@@ -25,6 +25,8 @@ > > import org.apache.fop.util.XMLUtil; > >+import java.io.UnsupportedEncodingException; >+ > /** > * Action class which represents a "URI" action, i.e. an action that will call up an external > * resource identified by a URI. >@@ -43,7 +45,13 @@ > if (uri == null) { > throw new NullPointerException("uri must not be null"); > } >+ try { >+ this.uri = java.net.URLDecoder.decode(uri, "UTF-8"); >+ } catch (UnsupportedEncodingException uee) { >+ assert false; >- this.uri = uri; >+ this.uri = uri; >+ } >+ > this.newWindow = newWindow; > } > >@@ -92,7 +100,14 @@ > if (hasID()) { > atts.addAttribute(null, "id", "id", XMLUtil.CDATA, getID()); > } >- atts.addAttribute(null, "uri", "uri", XMLUtil.CDATA, getURI()); >+ String encodedURI; >+ try { >+ encodedURI = java.net.URLEncoder.encode(getURI(), "UTF-8"); >+ } catch (UnsupportedEncodingException uee) { >+ assert false; >+ encodedURI = getURI(); >+ } >+ atts.addAttribute(null, "uri", "uri", XMLUtil.CDATA, encodedURI); > if (isNewWindow()) { > atts.addAttribute(null, "show-destination", "show-destination", XMLUtil.CDATA, "new"); > }
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 47122
:
23563
|
23564
| 24012