From 3ecf6f35068e784c424dc0fe814f56f9821c40eb Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Wed, 24 Jan 2007 04:02:33 +0000 Subject: [PATCH] Use bitwise & when operating on flags. (#399971, Jon Oberheide) 2007-01-23 Matthias Clasen * glib/goption.c (print_help): Use bitwise & when operating on flags. (#399971, Jon Oberheide) svn path=/trunk/; revision=5308 --- ChangeLog | 5 +++++ glib/goption.c | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index 93e5452..20bf7c1 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2007-01-23 Matthias Clasen + + * glib/goption.c (print_help): Use bitwise & + when operating on flags. (#399971, Jon Oberheide) + 2007-01-19 Matthias Clasen Some file list updates (#398069, Owen Taylor) diff --git a/glib/goption.c b/glib/goption.c index 5d08e30..b0fcab7 100644 --- a/glib/goption.c +++ b/glib/goption.c @@ -581,13 +581,13 @@ print_help (GOptionContext *context, { entry = &group->entries[i]; if (g_hash_table_lookup (shadow_map, entry->long_name) && - !(entry->flags && G_OPTION_FLAG_NOALIAS)) + !(entry->flags & G_OPTION_FLAG_NOALIAS)) entry->long_name = g_strdup_printf ("%s-%s", group->name, entry->long_name); else g_hash_table_insert (shadow_map, (gpointer)entry->long_name, entry); if (seen[(guchar)entry->short_name] && - !(entry->flags && G_OPTION_FLAG_NOALIAS)) + !(entry->flags & G_OPTION_FLAG_NOALIAS)) entry->short_name = 0; else seen[(guchar)entry->short_name] = TRUE; -- 2.7.4