[Libreoffice-commits] core.git: Branch 'libreoffice-5-4' - vcl/unx
Eike Rathke
erack at redhat.com
Thu Jun 29 20:21:26 UTC 2017
vcl/unx/gtk3/gtk3gtkframe.cxx | 9 ++++++---
1 file changed, 6 insertions(+), 3 deletions(-)
New commits:
commit 1c32dedb3d6931079a3903a64300a1fad4548556
Author: Eike Rathke <erack at redhat.com>
Date: Thu Jun 29 14:02:58 2017 +0200
Don't let m_nGrabLevel become negative, tdf#108705 related
... which then later leads to 2 Giga loops on the next GtkSalFrame dtor call,
for example on the second AutoFilter button popup in Calc.
Fall-out from
commit 9b32355ea6d8d5e34363ba0c57e74d75d7a7b1b7
Date: Fri Jun 23 12:48:12 2017 +0100
Resolves: tdf#108705 remove grabs on widget before destroying it
that brought this to surface.
Change-Id: I0edb7eec9384c716800f07ef1ed91fc8f1d7c119
(cherry picked from commit 637d917d7551fed19c9685f974fb3e732a8f97e2)
Reviewed-on: https://gerrit.libreoffice.org/39387
Tested-by: Jenkins <ci at libreoffice.org>
Reviewed-by: Michael Stahl <mstahl at redhat.com>
diff --git a/vcl/unx/gtk3/gtk3gtkframe.cxx b/vcl/unx/gtk3/gtk3gtkframe.cxx
index 9b56adc2bdf5..c02a19093f7d 100644
--- a/vcl/unx/gtk3/gtk3gtkframe.cxx
+++ b/vcl/unx/gtk3/gtk3gtkframe.cxx
@@ -2579,9 +2579,12 @@ void GtkSalFrame::addGrabLevel()
void GtkSalFrame::removeGrabLevel()
{
- --m_nGrabLevel;
- if (m_nGrabLevel == 0)
- gtk_grab_remove(getMouseEventWidget());
+ if (m_nGrabLevel > 0)
+ {
+ --m_nGrabLevel;
+ if (m_nGrabLevel == 0)
+ gtk_grab_remove(getMouseEventWidget());
+ }
}
void GtkSalFrame::closePopup()
More information about the Libreoffice-commits
mailing list