You are viewing a plain text version of this content. The canonical link for it is here.
Posted to batik-dev@xmlgraphics.apache.org by "Jan Hill (Jira)" <ji...@apache.org> on 2020/05/23 08:33:00 UTC
[jira] [Resolved] (BATIK-1281) URI BASE64 with whitespace
[ https://issues.apache.org/jira/browse/BATIK-1281?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Jan Hill resolved BATIK-1281.
-----------------------------
Resolution: Not A Problem
> 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
> Priority: Critical
> Labels: easyfix
>
> 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:
> org.apache.batik.transcoder.image.ImageTranscoder
> ...
> 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.
> regards
> Jan
>
> 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
(v8.3.4#803005)
---------------------------------------------------------------------
To unsubscribe, e-mail: batik-dev-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: batik-dev-help@xmlgraphics.apache.org