On Fri, 2018-05-11 at 16:24 +0000, Georg Funk wrote:
> 723 0 R Current Reference
> 
> The failing step seems to be the check of IsReference().

        Hi,
does 723 0 object exist in your PDF document at all? Everything points
to it does not exist. There is really nothing to fail (or better crash)
in IsReference() when it's called on a valid (non-NULL) object.

Could you verify that objectVector.GetObject(currentReference) returns
non-NULL object, please?

You also wrote that the objectVector is some global variable. How is it
set? What if you use PdfDocument::GetObjects() instead (which returns a
pointer, not a reference), thus something like this:

   PdfObject *function (PdfDocument &doc, const PdfReference & ref)
   {
       return doc.GetObjects()->GetObject(ref);
   }

Is the associated PdfDocument still valid, when you are at this place
in the code?

There are quite few things you can do wrong, but you didn't give enough
information to point to an exact place.

Eventually see PdfObject::GetIndirectKey(), it does something similar
what you want to achieve and it surely works.
        Bye,
        zyx

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Podofo-users mailing list
Podofo-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/podofo-users

Reply via email to