Use bitwise & when operating on flags. (#399971, Jon Oberheide)

2007-01-23  Matthias Clasen  <mclasen@redhat.com>

        * glib/goption.c (print_help): Use bitwise &
        when operating on flags.  (#399971, Jon Oberheide)



svn path=/trunk/; revision=5308
This commit is contained in:
Matthias Clasen 2007-01-24 04:02:33 +00:00 committed by Matthias Clasen
parent 2375b6285d
commit 3ecf6f3506
2 changed files with 7 additions and 2 deletions

View File

@ -1,3 +1,8 @@
2007-01-23 Matthias Clasen <mclasen@redhat.com>
* glib/goption.c (print_help): Use bitwise &
when operating on flags. (#399971, Jon Oberheide)
2007-01-19 Matthias Clasen <mclasen@redhat.com>
Some file list updates (#398069, Owen Taylor)

View File

@ -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;