[jira] [Created] (BATIK-1281) URI BASE64 with whitespace

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

[jira] [Created] (BATIK-1281) URI BASE64 with whitespace

Simon Steiner (Jira)
Jan Hill created BATIK-1281:

             Summary: URI BASE64 with whitespace
                 Key: BATIK-1281
                 URL: https://issues.apache.org/jira/browse/BATIK-1281
             Project: Batik
          Issue Type: Bug
    Affects Versions: 1.12
            Reporter: Jan Hill

I am sure there is am bug, if the base64 string/stream has whitespaces ( SPACE; LF; CRLF; CR).

If you handle base64 strings you have to ignore whitespaces.

See below. Is there a chance to get them fixed? Or for wich class should this fix developed?

One solution could be:



import org.apache.batik.transcoder.keys.PaintKey;
+import org.apache.commons.lang3.StringUtils;
import org.w3c.dom.Document;


protected void transcode(Document document,
 String uri,
 TranscoderOutput output)
 throws TranscoderException {

+ StringUtils.deleteWhitespace(uri);
 // Sets up root, curTxf & curAoi
 super.transcode(document, uri, output);

// prepare the image to be painted


But you have to add

import org.apache.commons.lang3.StringUtils

and to put this jar to lib and put also a licensefile up there.

So i didn't know your package architecture policy

A solution for this bug would be great.




The Exception in BATIK-966 will also be fixed, but BATIK-966 won't work because they try to load a gif.

A part of BATIK-870 will be fixed, but there is some additional problem.


This message was sent by Atlassian Jira

To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]