vcl/source/gdi/embeddedfontsmanager.cxx |    3 +++
 1 file changed, 3 insertions(+)

New commits:
commit ca9c56b13edaa97cfd6c70a7506b7b69414b47bb
Author:     Mike Kaganski <[email protected]>
AuthorDate: Mon Oct 20 16:02:43 2025 +0500
Commit:     Andras Timar <[email protected]>
CommitDate: Tue Oct 21 14:52:24 2025 +0200

    lok: background save: avoid removing fonts used by parent process
    
    The forked process used to remove them, while destroying its document
    - which caused missing text on screen.
    
    Change-Id: I7c19dbd311fe26b8e594ed9042e4181fffa42238
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/192719
    Tested-by: Jenkins CollaboraOffice <[email protected]>
    Reviewed-by: Miklos Vajna <[email protected]>
    (cherry picked from commit e8c54433d4a573840bf51f1142a0e56de97f0eda)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/192791
    Reviewed-by: Andras Timar <[email protected]>
    Tested-by: Andras Timar <[email protected]>

diff --git a/vcl/source/gdi/embeddedfontsmanager.cxx 
b/vcl/source/gdi/embeddedfontsmanager.cxx
index a32910004b26..047238f73dd5 100644
--- a/vcl/source/gdi/embeddedfontsmanager.cxx
+++ b/vcl/source/gdi/embeddedfontsmanager.cxx
@@ -475,6 +475,9 @@ void 
EmbeddedFontsManager::activateFonts(std::vector<std::pair<OUString, OUStrin
 
 void EmbeddedFontsManager::releaseFonts(const std::vector<std::pair<OUString, 
OUString>>& fonts)
 {
+    // Background save process: avoid deletion of files created by the parent
+    if (comphelper::LibreOfficeKit::isForkedChild())
+        return;
     std::vector<std::pair<OUString, OUString>> unregister;
     if (!fonts.empty())
     {

Reply via email to