[poppler] c++ interface segfaults for invalid password

Jeroen Ooms jeroen at berkeley.edu
Sun Jun 11 11:51:26 UTC 2017


If the user enters an incorrect password when reading a protected pdf via
document::load_from_raw_data() an error is printed to stdout

 error: Incorrect password

However the load_from_raw_data() does not raise an exception and returns a
valid *document. However this document segfaults when we call for
example doc->pages().

I would have expected that load_from_raw_data() raises an exception instead
of just printing "incorrect password"?

If this is intended, what property of *document should I check to see if
document::load_from_raw_data() was successful?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/poppler/attachments/20170611/66c3ea30/attachment.html>


More information about the poppler mailing list