[gobject-introspection] Use case insensitive compare for signal "when" attribute



commit f6770c808203d4d3eb9a30e5c4bc896f990cae34
Author: Simon Feltman <sfeltman src gnome org>
Date:   Sat Oct 5 01:40:20 2013 -0700

    Use case insensitive compare for signal "when" attribute
    
    Update parser to use g_ascii_strcasecmp instead of strcmp. This fixes
    incorrect flags being set when the incomming gir is using lowercase values
    for the "when" attribute.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=709462

 girepository/girparser.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/girepository/girparser.c b/girepository/girparser.c
index f96cfb1..6fbf2a6 100644
--- a/girepository/girparser.c
+++ b/girepository/girparser.c
@@ -2301,9 +2301,9 @@ start_glib_signal (GMarkupParseContext *context,
   signal->run_first = FALSE;
   signal->run_last = FALSE;
   signal->run_cleanup = FALSE;
-  if (when == NULL || strcmp (when, "LAST") == 0)
+  if (when == NULL || g_ascii_strcasecmp (when, "LAST") == 0)
     signal->run_last = TRUE;
-  else if (strcmp (when, "FIRST") == 0)
+  else if (g_ascii_strcasecmp (when, "FIRST") == 0)
     signal->run_first = TRUE;
   else
     signal->run_cleanup = TRUE;


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]