Blame SOURCES/0004-gnome-documents-hold-solarmutex-on-dtor-patch-as-wel.patch

69cc7b
From 710bbe401ada2cbcb18f5923635809566e748351 Mon Sep 17 00:00:00 2001
135360
From: =?UTF-8?q?Caol=C3=A1n=20McNamara?= <caolanm@redhat.com>
135360
Date: Mon, 8 May 2017 15:51:46 +0100
69cc7b
Subject: [PATCH 4/5] gnome-documents: hold solarmutex on dtor patch as well
135360
MIME-Version: 1.0
135360
Content-Type: text/plain; charset=UTF-8
135360
Content-Transfer-Encoding: 8bit
135360
135360
Change-Id: I75fe71612116d435606c37185bf55b450425fc25
135360
Reviewed-on: https://gerrit.libreoffice.org/37396
135360
Tested-by: Jenkins <ci@libreoffice.org>
135360
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
135360
Tested-by: Caolán McNamara <caolanm@redhat.com>
135360
(cherry picked from commit 899ffa4c4c66702e2a65f4065cbb7970d0e9c0e2)
135360
---
135360
 include/comphelper/unique_disposing_ptr.hxx | 6 ++++++
135360
 1 file changed, 6 insertions(+)
135360
135360
diff --git a/include/comphelper/unique_disposing_ptr.hxx b/include/comphelper/unique_disposing_ptr.hxx
69cc7b
index c986b12..324b7ae 100644
135360
--- a/include/comphelper/unique_disposing_ptr.hxx
135360
+++ b/include/comphelper/unique_disposing_ptr.hxx
69cc7b
@@ -177,6 +177,12 @@ public:
135360
         SolarMutexGuard aGuard;
135360
         unique_disposing_ptr<T>::reset(p);
135360
     }
135360
+
135360
+    virtual ~unique_disposing_solar_mutex_reset_ptr() override
135360
+    {
135360
+        if (unique_disposing_ptr<T>::get() && comphelper::SolarMutex::get())
135360
+            reset();
135360
+    }
135360
 };
135360
 
135360
 }
135360
-- 
135360
2.9.3
135360