diff options
author | Nathan Pratta Teodosio <nathan.teodosio@canonical.com> | 2022-06-21 08:47:14 -0300 |
---|---|---|
committer | Andras Timar <andras.timar@collabora.com> | 2023-03-25 19:19:48 +0100 |
commit | 58648d46629e81f887f65b5b76a1252005b49394 (patch) | |
tree | a1871708a75a78a665b87e149c02cc6420cbde3b /sdext/source/pdfimport/xpdfwrapper/wrapper_gpl.cxx | |
parent | c9464c59f119bbf923d7c0bdab20712c37686e0b (diff) |
Update for Poppler 22.06
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/136261
Tested-by: Jenkins
Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
(cherry picked from commit 0d0469b4302dfe95b016a6f04b145834b79d5ed3)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/136319
Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
(cherry picked from commit 56c7e666ebf47d6cdf29adf85fc5de56246be86d)
Follow-up for Poppler 22.06 update
Change-Id: I8ee9f1a53cc4389e6a4d44e9765b478b5edfffd4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/136342
Tested-by: Jenkins
Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
(cherry picked from commit ad1ffc62e40c2409b610dfff25a8483b1f2556ad)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/136382
Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
(cherry picked from commit 71fb0151f985924af60c383331b214a5a27790a5)
Diffstat (limited to 'sdext/source/pdfimport/xpdfwrapper/wrapper_gpl.cxx')
-rw-r--r-- | sdext/source/pdfimport/xpdfwrapper/wrapper_gpl.cxx | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/sdext/source/pdfimport/xpdfwrapper/wrapper_gpl.cxx b/sdext/source/pdfimport/xpdfwrapper/wrapper_gpl.cxx index b1a54bd09c5f..3ab3381652cd 100644 --- a/sdext/source/pdfimport/xpdfwrapper/wrapper_gpl.cxx +++ b/sdext/source/pdfimport/xpdfwrapper/wrapper_gpl.cxx @@ -119,6 +119,15 @@ int main(int argc, char **argv) _setmode( _fileno( g_binary_out ), _O_BINARY ); #endif +#if POPPLER_CHECK_VERSION(22, 6, 0) + PDFDoc aDoc( std::make_unique<GooString>(pFileName), + std::optional<GooString>(pOwnerPasswordStr), + std::optional<GooString>(pUserPasswordStr) ); + + PDFDoc aErrDoc( std::make_unique<GooString>(pErrFileName), + std::optional<GooString>(pOwnerPasswordStr), + std::optional<GooString>(pUserPasswordStr) ); +#else PDFDoc aDoc( pFileName, pOwnerPasswordStr, pUserPasswordStr ); @@ -126,6 +135,7 @@ int main(int argc, char **argv) PDFDoc aErrDoc( pErrFileName, pOwnerPasswordStr, pUserPasswordStr ); +#endif // Check various permissions for aDoc. PDFDoc &rDoc = aDoc.isOk()? aDoc: aErrDoc; |