File gtkhtml-im-crash.patch of Package gtkhtml2
From: Hiroyuki Ikezoe <poincare@ikezoe.net>
Subject: A ptach for fixing crash GtkHTML with some IM modules
HI,
I found a crash bug in GtkHTML-3.2.3 with some type of IM modules, which
emits "commit" signal to the IMContext when focus out from the widget.
I send a patch for fixing this problem, but I could not understand the
whole codes of GtkHTML, please check that the patch does not cause any
other problems.
Thanks.
=== modified file 'gtkhtml/htmlcursor.c'
--- gtkhtml/htmlcursor.c 2007-12-18 22:30:17 +0000
+++ gtkhtml/htmlcursor.c 2007-12-18 22:32:24 +0000
@@ -703,8 +703,6 @@
g_return_if_fail (cursor != NULL);
g_return_if_fail (position >= 0);
- gtk_html_im_reset (engine->widget);
-
if (engine->need_spell_check)
html_engine_spell_check_range (engine, engine->cursor, engine->cursor);
@@ -719,6 +717,7 @@
break;
}
}
+ gtk_html_im_reset (engine->widget);
}
void