You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@pdfbox.apache.org by "ASF subversion and git services (JIRA)" <ji...@apache.org> on 2016/03/22 19:29:25 UTC

[jira] [Commented] (PDFBOX-3279) PDDocument.importPage creates two inputstreams

    [ https://issues.apache.org/jira/browse/PDFBOX-3279?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15206977#comment-15206977 ] 

ASF subversion and git services commented on PDFBOX-3279:
---------------------------------------------------------

Commit 1736227 from [~lehmi] in branch 'pdfbox/trunk'
[ https://svn.apache.org/r1736227 ]

PDFBOX-3279: avoid creating unneeded stream

> PDDocument.importPage creates two inputstreams
> ----------------------------------------------
>
>                 Key: PDFBOX-3279
>                 URL: https://issues.apache.org/jira/browse/PDFBOX-3279
>             Project: PDFBox
>          Issue Type: Bug
>          Components: PDModel
>    Affects Versions: 2.0.0
>            Reporter: Cornelis Hoeflake
>            Assignee: Andreas Lehmkühler
>             Fix For: 2.0.1, 2.1.0
>
>
> PDDocument.importPage creates two inputstreams from page.getContents(), but uses one (for real). The first is only used to check if it exists.
> {code}
>         InputStream in = null;
>         try
>         {
>             in = page.getContents();
>             if (in != null)
>             {
>                 PDStream dest = new PDStream(this, page.getContents(), COSName.FLATE_DECODE);
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@pdfbox.apache.org
For additional commands, e-mail: dev-help@pdfbox.apache.org