sfx2/source/view/frmload.cxx |    3 +++
 1 file changed, 3 insertions(+)

New commits:
commit e3eec266ad242fb64861695e03c03d2989ad9cb6
Author:     Michael Stahl <[email protected]>
AuthorDate: Fri Mar 21 15:48:41 2025 +0100
Commit:     Stephan Bergmann <[email protected]>
CommitDate: Mon Nov 17 13:49:43 2025 +0100

    tdf#165851 sfx2: fix loading template with expand URL from configuration
    
    Expand trusted URLs from configuration or extension.
    
    (regression from commit 836d73a65180d89a077e36457f1f3aa1698c2058)
    
    Change-Id: I7c2f8a59b44ae62e25ac26eb568f3f80c77a01ee
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/183206
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <[email protected]>
    Reviewed-by: Michael Stahl <[email protected]>
    (cherry picked from commit 8c548d46f4eacd615527412a0019d7a46150bee6)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/183210
    Reviewed-by: Adolfo Jayme Barrientos <[email protected]>
    (cherry picked from commit 286e46c1a572f77df382af46c29ce862f4fe5c31)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/194029
    Reviewed-by: Stephan Bergmann <[email protected]>
    Tested-by: Jenkins CollaboraOffice <[email protected]>

diff --git a/sfx2/source/view/frmload.cxx b/sfx2/source/view/frmload.cxx
index 99a06d12f269..013dea60eaa4 100644
--- a/sfx2/source/view/frmload.cxx
+++ b/sfx2/source/view/frmload.cxx
@@ -47,6 +47,7 @@
 #include <com/sun/star/uno/XComponentContext.hpp>
 #include <com/sun/star/util/XCloseable.hpp>
 
+#include <comphelper/getexpandeduri.hxx>
 #include <comphelper/interaction.hxx>
 #include <comphelper/namedvaluecollection.hxx>
 #include <cppuhelper/exc_hlp.hxx>
@@ -418,6 +419,8 @@ bool SfxFrameLoader_Impl::impl_determineTemplateDocument( 
::comphelper::NamedVal
                 sTemplateURL = SfxObjectFactory::GetStandardTemplate( 
sServiceName );
             else
                 sTemplateURL = SfxObjectFactory::GetStandardTemplate( 
SfxObjectShell::GetServiceNameFromFactory( sURL ) );
+            // tdf#165851 expand trusted urls from configuration here
+            sTemplateURL = comphelper::getExpandedUri(m_aContext, 
sTemplateURL);
         }
 
         if ( !sTemplateURL.isEmpty() )

Reply via email to