[Libreoffice-commits] core.git: Branch 'libreoffice-6-0' - vcl/source
Samuel Mehrbrodt
Samuel.Mehrbrodt at cib.de
Thu Jan 11 15:06:48 UTC 2018
vcl/source/window/accessibility.cxx | 4 +++-
vcl/source/window/window.cxx | 3 ++-
2 files changed, 5 insertions(+), 2 deletions(-)
New commits:
commit 10eb616c3106b538857542f1c4b1df375a6cf1b6
Author: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
Date: Wed Jan 10 13:25:33 2018 +0100
tdf#113874 Guard against invalid states
Change-Id: I013dd4eb81f0fbef25d9f58e27fe72d800d910ba
Reviewed-on: https://gerrit.libreoffice.org/47702
Tested-by: Jenkins <ci at libreoffice.org>
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
(cherry picked from commit d2763bde00f0f840585e1ec4c8f94c0ef804a580)
Reviewed-on: https://gerrit.libreoffice.org/47744
Reviewed-by: Thorsten Behrens <Thorsten.Behrens at CIB.de>
Reviewed-by: Miklos Vajna <vmiklos at collabora.co.uk>
diff --git a/vcl/source/window/accessibility.cxx b/vcl/source/window/accessibility.cxx
index 3d81a1e82edc..4ee4b07ea89d 100644
--- a/vcl/source/window/accessibility.cxx
+++ b/vcl/source/window/accessibility.cxx
@@ -139,7 +139,9 @@ css::uno::Reference< css::accessibility::XAccessible > Window::CreateAccessible(
void Window::SetAccessible( const css::uno::Reference< css::accessibility::XAccessible >& x )
{
- assert(mpWindowImpl);
+ if (!mpWindowImpl)
+ return;
+
mpWindowImpl->mxAccessible = x;
}
diff --git a/vcl/source/window/window.cxx b/vcl/source/window/window.cxx
index 84dabd027689..a3310a5b4976 100644
--- a/vcl/source/window/window.cxx
+++ b/vcl/source/window/window.cxx
@@ -3136,7 +3136,8 @@ const OUString& Window::GetHelpText() const
void Window::SetWindowPeer( Reference< css::awt::XWindowPeer > const & xPeer, VCLXWindow* pVCLXWindow )
{
- assert(mpWindowImpl);
+ if (!mpWindowImpl)
+ return;
// be safe against re-entrance: first clear the old ref, then assign the new one
mpWindowImpl->mxWindowPeer.clear();
More information about the Libreoffice-commits
mailing list