wsd/DocumentBroker.cpp |   13 ++++++++-----
 1 file changed, 8 insertions(+), 5 deletions(-)

New commits:
commit 22ebc22c420f3c2707b9b5edca8a1c73b1e0093e
Author:     Michael Meeks <michael.me...@collabora.com>
AuthorDate: Wed May 22 02:38:39 2019 +0100
Commit:     Andras Timar <andras.ti...@collabora.com>
CommitDate: Thu Jun 13 10:04:45 2019 +0200

    Avoid exceptions in some shutdown corner cases.
    
    Change-Id: I1c301dc96d925fd5d74c00bf4b9417782822a997
    Reviewed-on: https://gerrit.libreoffice.org/72745
    Reviewed-by: Andras Timar <andras.ti...@collabora.com>
    Tested-by: Andras Timar <andras.ti...@collabora.com>

diff --git a/wsd/DocumentBroker.cpp b/wsd/DocumentBroker.cpp
index b2eabd655..674fb2f4a 100644
--- a/wsd/DocumentBroker.cpp
+++ b/wsd/DocumentBroker.cpp
@@ -1939,11 +1939,14 @@ void ConvertToBroker::removeFile(const std::string 
&uriOrig)
 {
     if (!uriOrig.empty())
     {
-        // Remove source file and directory
-        Poco::Path path = uriOrig;
-        Poco::File(path).remove();
-        Poco::File(path.makeParent()).remove();
-        FileUtil::removeFile(uriOrig);
+        try {
+            // Remove source file and directory
+            Poco::Path path = uriOrig;
+            Poco::File(path).remove();
+            Poco::File(path.makeParent()).remove();
+        } catch (const std::exception &ex) {
+            LOG_ERR("Error while removing conversion temporary: '" << uriOrig 
<< "' - " << ex.what());
+        }
     }
 }
 
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to