Fix C99isms. (#328705, Kazuki Iwamoto)

2006-01-26  Matthias Clasen  <mclasen@redhat.com>

	* glib/gmem.c (g_mem_init_nomessage): Fix C99isms.  (#328705,
	Kazuki Iwamoto)
This commit is contained in:
Matthias Clasen 2006-01-26 19:43:48 +00:00 committed by Matthias Clasen
parent 5cb432b56c
commit 6c9179512d
4 changed files with 22 additions and 5 deletions

View File

@ -1,3 +1,8 @@
2006-01-26 Matthias Clasen <mclasen@redhat.com>
* glib/gmem.c (g_mem_init_nomessage): Fix C99isms. (#328705,
Kazuki Iwamoto)
Wed Jan 25 19:16:57 2006 Tim Janik <timj@imendio.com>
* fixed buglets reported by Jens Granseuer in #328254.

View File

@ -1,3 +1,8 @@
2006-01-26 Matthias Clasen <mclasen@redhat.com>
* glib/gmem.c (g_mem_init_nomessage): Fix C99isms. (#328705,
Kazuki Iwamoto)
Wed Jan 25 19:16:57 2006 Tim Janik <timj@imendio.com>
* fixed buglets reported by Jens Granseuer in #328254.

View File

@ -1,3 +1,8 @@
2006-01-26 Matthias Clasen <mclasen@redhat.com>
* glib/gmem.c (g_mem_init_nomessage): Fix C99isms. (#328705,
Kazuki Iwamoto)
Wed Jan 25 19:16:57 2006 Tim Janik <timj@imendio.com>
* fixed buglets reported by Jens Granseuer in #328254.

View File

@ -686,15 +686,17 @@ gboolean g_mem_gc_friendly = FALSE;
static void
g_mem_init_nomessage (void)
{
if (g_mem_initialized)
return;
/* don't use g_malloc/g_message here */
gchar buffer[1024];
const gchar *val = _g_getenv_nomalloc ("G_DEBUG", buffer);
const gchar *val;
static const GDebugKey keys[] = {
{ "gc-friendly", 1 },
};
gint flags = !val ? 0 : g_parse_debug_string (val, keys, G_N_ELEMENTS (keys));
gint flags;
if (g_mem_initialized)
return;
/* don't use g_malloc/g_message here */
val = _g_getenv_nomalloc ("G_DEBUG", buffer);
flags = !val ? 0 : g_parse_debug_string (val, keys, G_N_ELEMENTS (keys));
if (flags & 1) /* gc-friendly */
{
g_mem_gc_friendly = TRUE;