mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-02-09 04:15:49 +01:00
Allow NULL strings in g_parse_debug_string. (#503862, Matthew Barnes)
* glib/gutils.c: Allow NULL strings in g_parse_debug_string. (#503862, Matthew Barnes) svn path=/trunk/; revision=6137
This commit is contained in:
parent
db005ce233
commit
f87b822b21
@ -1,3 +1,8 @@
|
|||||||
|
2007-12-16 Mathias Hasselmann <mathias@openismus.com>
|
||||||
|
|
||||||
|
* glib/gutils.c:
|
||||||
|
Allow NULL strings in g_parse_debug_string. (#503862, Matthew Barnes)
|
||||||
|
|
||||||
2007-12-14 Matthias Clasen <mclasen@redhat.com>
|
2007-12-14 Matthias Clasen <mclasen@redhat.com>
|
||||||
|
|
||||||
* glib/glib.symbols:
|
* glib/glib.symbols:
|
||||||
|
@ -565,7 +565,7 @@ debug_key_matches (const gchar *key,
|
|||||||
/**
|
/**
|
||||||
* g_parse_debug_string:
|
* g_parse_debug_string:
|
||||||
* @string: a list of debug options separated by colons, spaces, or
|
* @string: a list of debug options separated by colons, spaces, or
|
||||||
* commas; or the string "all" to set all flags.
|
* commas; or the string "all" to set all flags, or %NULL.
|
||||||
* @keys: pointer to an array of #GDebugKey which associate
|
* @keys: pointer to an array of #GDebugKey which associate
|
||||||
* strings with bit flags.
|
* strings with bit flags.
|
||||||
* @nkeys: the number of #GDebugKey<!-- -->s in the array.
|
* @nkeys: the number of #GDebugKey<!-- -->s in the array.
|
||||||
@ -585,7 +585,8 @@ g_parse_debug_string (const gchar *string,
|
|||||||
guint i;
|
guint i;
|
||||||
guint result = 0;
|
guint result = 0;
|
||||||
|
|
||||||
g_return_val_if_fail (string != NULL, 0);
|
if (string == NULL)
|
||||||
|
return 0;
|
||||||
|
|
||||||
/* this function is used by gmem.c/gslice.c initialization code,
|
/* this function is used by gmem.c/gslice.c initialization code,
|
||||||
* so introducing malloc dependencies here would require adaptions
|
* so introducing malloc dependencies here would require adaptions
|
||||||
|
Loading…
x
Reference in New Issue
Block a user