]> Pileus Git - ~andy/gtk/commitdiff
Stop preediting if strtoul couldn't parse the complete preedit string.
authorMatthias Clasen <mclasen@redhat.com>
Tue, 26 Oct 2004 20:56:52 +0000 (20:56 +0000)
committerMatthias Clasen <matthiasc@src.gnome.org>
Tue, 26 Oct 2004 20:56:52 +0000 (20:56 +0000)
2004-10-26  Matthias Clasen  <mclasen@redhat.com>

* gtk/gtkimcontextsimple.c (check_hex): Stop preediting if strtoul couldn't
parse the complete preedit string.  (#156434)

ChangeLog
ChangeLog.pre-2-10
ChangeLog.pre-2-6
ChangeLog.pre-2-8
gtk/gtkimcontextsimple.c

index 0fa4153a006839e20a06ed67a2d09a98460080c0..c0e5eb0d7a459c8b69cdef7f2b52ea52cf7ff8bf 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
 2004-10-26  Matthias Clasen  <mclasen@redhat.com>
 
+       * gtk/gtkimcontextsimple.c (check_hex): Stop preediting if strtoul couldn't 
+       parse the complete preedit string.  (#156434)
+
        * gtk/gtkmessagedialog.c: 
        * gtk/gtkfilechooserbutton.c: Add missing includes.  (#156503, Kazuki IWAMOTO)
 
index 0fa4153a006839e20a06ed67a2d09a98460080c0..c0e5eb0d7a459c8b69cdef7f2b52ea52cf7ff8bf 100644 (file)
@@ -1,5 +1,8 @@
 2004-10-26  Matthias Clasen  <mclasen@redhat.com>
 
+       * gtk/gtkimcontextsimple.c (check_hex): Stop preediting if strtoul couldn't 
+       parse the complete preedit string.  (#156434)
+
        * gtk/gtkmessagedialog.c: 
        * gtk/gtkfilechooserbutton.c: Add missing includes.  (#156503, Kazuki IWAMOTO)
 
index 0fa4153a006839e20a06ed67a2d09a98460080c0..c0e5eb0d7a459c8b69cdef7f2b52ea52cf7ff8bf 100644 (file)
@@ -1,5 +1,8 @@
 2004-10-26  Matthias Clasen  <mclasen@redhat.com>
 
+       * gtk/gtkimcontextsimple.c (check_hex): Stop preediting if strtoul couldn't 
+       parse the complete preedit string.  (#156434)
+
        * gtk/gtkmessagedialog.c: 
        * gtk/gtkfilechooserbutton.c: Add missing includes.  (#156503, Kazuki IWAMOTO)
 
index 0fa4153a006839e20a06ed67a2d09a98460080c0..c0e5eb0d7a459c8b69cdef7f2b52ea52cf7ff8bf 100644 (file)
@@ -1,5 +1,8 @@
 2004-10-26  Matthias Clasen  <mclasen@redhat.com>
 
+       * gtk/gtkimcontextsimple.c (check_hex): Stop preediting if strtoul couldn't 
+       parse the complete preedit string.  (#156434)
+
        * gtk/gtkmessagedialog.c: 
        * gtk/gtkfilechooserbutton.c: Add missing includes.  (#156503, Kazuki IWAMOTO)
 
index 40f8ac28269aaeccbf6b690272ebb7c03a6e3f27..00809ec90a0f5570905037f18fd67397a25aadc4 100644 (file)
@@ -1167,7 +1167,7 @@ check_hex (GtkIMContextSimple *context_simple,
   /* if strtoul fails it probably means non-latin digits were used;
    * we should in principle handle that, but we probably don't.
    */
-  if (str->str == nptr)
+  if (nptr - str->str < str->len)
     {
       g_string_free (str, TRUE);
       return FALSE;