sfx2/source/doc/objserv.cxx |    4 ++++
 1 file changed, 4 insertions(+)

New commits:
commit 52dcafffc26a5dfbce4987cde0ec104b34dce3e1
Author:     Miklos Vajna <vmik...@collabora.com>
AuthorDate: Tue Jun 2 16:45:44 2020 +0200
Commit:     Miklos Vajna <vmik...@collabora.com>
CommitDate: Fri Jun 5 09:31:31 2020 +0200

    tdf#130354 sfx2: make PDF signing UI work again
    
    Regression from commit 9112c18524c9f5e67d6cbb282586a439e3020cdb (Don't
    create unnecessary tempfiles for opened doc, 2019-10-18), restore the
    temporary file creation for the PDF case, as it's needed for PDF signing
    to work.
    
    (cherry picked from commit 058caeef45f9abf12e4e243aafbbb1c2ebcbc057)
    
    Change-Id: I945f04f6ab90d0e04fb14a7634ec877fb0af1a0f

diff --git a/sfx2/source/doc/objserv.cxx b/sfx2/source/doc/objserv.cxx
index ba76289818aa..b2c7d07be18f 100644
--- a/sfx2/source/doc/objserv.cxx
+++ b/sfx2/source/doc/objserv.cxx
@@ -1593,6 +1593,10 @@ uno::Sequence< security::DocumentSignatureInformation > 
SfxObjectShell::GetDocum
                 else
                 {
                     // Not ZIP-based, e.g. PDF.
+
+                    // Create temp file if needed.
+                    GetMedium()->CreateTempFile(/*bReplace=*/false);
+
                     std::unique_ptr<SvStream> 
pStream(utl::UcbStreamHelper::CreateStream(GetMedium()->GetName(), 
StreamMode::READ));
                     uno::Reference<io::XStream> xStream(new 
utl::OStreamWrapper(*pStream));
                     uno::Reference<io::XInputStream> xInputStream(xStream, 
uno::UNO_QUERY);
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to