From ff560c934e837540307669c240d1e390adc99f2c Mon Sep 17 00:00:00 2001 From: Michael Natterer Date: Fri, 26 Jan 2007 13:31:35 +0000 Subject: [PATCH] destroy the XIM only if it exists. While the code does look safe in 2007-01-26 Michael Natterer * modules/input/gtkimcontextxim.c (gtk_im_context_xim_finalize): destroy the XIM only if it exists. While the code does look safe in general, there can be corner cases where the "reconnecting" boolean being FALSE does not correspond to the XIM being allocated (fix taken from maemo-gtk). svn path=/trunk/; revision=17218 --- ChangeLog | 8 ++++++++ modules/input/gtkimcontextxim.c | 2 +- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index d4ee62567..176db033f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2007-01-26 Michael Natterer + + * modules/input/gtkimcontextxim.c (gtk_im_context_xim_finalize): + destroy the XIM only if it exists. While the code does look safe + in general, there can be corner cases where the "reconnecting" + boolean being FALSE does not correspond to the XIM being + allocated (fix taken from maemo-gtk). + Fri Jan 26 13:07:07 2007 Tim Janik * gtk/gtkstyle.c (draw_insertion_cursor): clamp cursor coordinates to diff --git a/modules/input/gtkimcontextxim.c b/modules/input/gtkimcontextxim.c index 68f6ec4f9..f6f7bd947 100644 --- a/modules/input/gtkimcontextxim.c +++ b/modules/input/gtkimcontextxim.c @@ -577,7 +577,7 @@ gtk_im_context_xim_finalize (GObject *obj) xim_instantiate_callback, (XPointer)context_xim->im_info); } - else + else if (context_xim->im_info->im) { XIMCallback im_destroy_callback; -- 2.43.2