You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@pdfbox.apache.org by "Andreas Lehmkühler (JIRA)" <ji...@apache.org> on 2013/04/28 18:52:16 UTC

[jira] [Resolved] (PDFBOX-1583) wasted work in PDDocument.addSignature(...)

     [ https://issues.apache.org/jira/browse/PDFBOX-1583?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Andreas Lehmkühler resolved PDFBOX-1583.
----------------------------------------

       Resolution: Fixed
    Fix Version/s: 1.8.2
         Assignee: Andreas Lehmkühler

I added the patch in revision 1476795 as proposed.

Thanks for the contribution
                
> wasted work in PDDocument.addSignature(...)
> -------------------------------------------
>
>                 Key: PDFBOX-1583
>                 URL: https://issues.apache.org/jira/browse/PDFBOX-1583
>             Project: PDFBox
>          Issue Type: Bug
>    Affects Versions: 1.8.1
>            Reporter: Adrian Nistor
>            Assignee: Andreas Lehmkühler
>              Labels: patch
>             Fix For: 1.8.2
>
>         Attachments: patch.diff
>
>
> The problem appears in version 1.8.1 and in revision 1476791.  I
> attached a one-line patch that fixes it.  This problem is similar to
> the already fixed PDFBOX-1447 and PDFBOX-1457.
> In method "PDDocument.addSignature", the loop over "cosObjects" should
> break immediately after "annotNotFound" and "sigFieldNotFound" are set
> to "false".  All the iterations after "annotNotFound" and
> "sigFieldNotFound" are set to "false" do not perform any useful work
> because the two "if" statements performing useful work depend on
> "annotNotFound" and "sigFieldNotFound".

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira