mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-02-22 10:12:10 +01:00
when !hook_list->is_setup, wrap the flag around the call to g_hook_free()
Mon Mar 8 07:42:08 1999 Tim Janik <timj@gtk.org> * ghook.c (g_hook_unref): when !hook_list->is_setup, wrap the flag around the call to g_hook_free() to avoid spurious warnings (happens during destruction phase).
This commit is contained in:
parent
45ce5e5c30
commit
6e6166ddd3
@ -1,3 +1,9 @@
|
||||
Mon Mar 8 07:42:08 1999 Tim Janik <timj@gtk.org>
|
||||
|
||||
* ghook.c (g_hook_unref): when !hook_list->is_setup, wrap the
|
||||
flag around the call to g_hook_free() to avoid spurious
|
||||
warnings (happens during destruction phase).
|
||||
|
||||
1999-03-03 Sebastian Wilhelmi <wilhelmi@ira.uka.de>
|
||||
|
||||
* glibconfig.h.win32, config.h.win32: Moved G_THREADS_IMPL_POSIX
|
||||
|
@ -1,3 +1,9 @@
|
||||
Mon Mar 8 07:42:08 1999 Tim Janik <timj@gtk.org>
|
||||
|
||||
* ghook.c (g_hook_unref): when !hook_list->is_setup, wrap the
|
||||
flag around the call to g_hook_free() to avoid spurious
|
||||
warnings (happens during destruction phase).
|
||||
|
||||
1999-03-03 Sebastian Wilhelmi <wilhelmi@ira.uka.de>
|
||||
|
||||
* glibconfig.h.win32, config.h.win32: Moved G_THREADS_IMPL_POSIX
|
||||
|
@ -1,3 +1,9 @@
|
||||
Mon Mar 8 07:42:08 1999 Tim Janik <timj@gtk.org>
|
||||
|
||||
* ghook.c (g_hook_unref): when !hook_list->is_setup, wrap the
|
||||
flag around the call to g_hook_free() to avoid spurious
|
||||
warnings (happens during destruction phase).
|
||||
|
||||
1999-03-03 Sebastian Wilhelmi <wilhelmi@ira.uka.de>
|
||||
|
||||
* glibconfig.h.win32, config.h.win32: Moved G_THREADS_IMPL_POSIX
|
||||
|
@ -1,3 +1,9 @@
|
||||
Mon Mar 8 07:42:08 1999 Tim Janik <timj@gtk.org>
|
||||
|
||||
* ghook.c (g_hook_unref): when !hook_list->is_setup, wrap the
|
||||
flag around the call to g_hook_free() to avoid spurious
|
||||
warnings (happens during destruction phase).
|
||||
|
||||
1999-03-03 Sebastian Wilhelmi <wilhelmi@ira.uka.de>
|
||||
|
||||
* glibconfig.h.win32, config.h.win32: Moved G_THREADS_IMPL_POSIX
|
||||
|
@ -1,3 +1,9 @@
|
||||
Mon Mar 8 07:42:08 1999 Tim Janik <timj@gtk.org>
|
||||
|
||||
* ghook.c (g_hook_unref): when !hook_list->is_setup, wrap the
|
||||
flag around the call to g_hook_free() to avoid spurious
|
||||
warnings (happens during destruction phase).
|
||||
|
||||
1999-03-03 Sebastian Wilhelmi <wilhelmi@ira.uka.de>
|
||||
|
||||
* glibconfig.h.win32, config.h.win32: Moved G_THREADS_IMPL_POSIX
|
||||
|
@ -1,3 +1,9 @@
|
||||
Mon Mar 8 07:42:08 1999 Tim Janik <timj@gtk.org>
|
||||
|
||||
* ghook.c (g_hook_unref): when !hook_list->is_setup, wrap the
|
||||
flag around the call to g_hook_free() to avoid spurious
|
||||
warnings (happens during destruction phase).
|
||||
|
||||
1999-03-03 Sebastian Wilhelmi <wilhelmi@ira.uka.de>
|
||||
|
||||
* glibconfig.h.win32, config.h.win32: Moved G_THREADS_IMPL_POSIX
|
||||
|
@ -1,3 +1,9 @@
|
||||
Mon Mar 8 07:42:08 1999 Tim Janik <timj@gtk.org>
|
||||
|
||||
* ghook.c (g_hook_unref): when !hook_list->is_setup, wrap the
|
||||
flag around the call to g_hook_free() to avoid spurious
|
||||
warnings (happens during destruction phase).
|
||||
|
||||
1999-03-03 Sebastian Wilhelmi <wilhelmi@ira.uka.de>
|
||||
|
||||
* glibconfig.h.win32, config.h.win32: Moved G_THREADS_IMPL_POSIX
|
||||
|
@ -1,3 +1,9 @@
|
||||
Mon Mar 8 07:42:08 1999 Tim Janik <timj@gtk.org>
|
||||
|
||||
* ghook.c (g_hook_unref): when !hook_list->is_setup, wrap the
|
||||
flag around the call to g_hook_free() to avoid spurious
|
||||
warnings (happens during destruction phase).
|
||||
|
||||
1999-03-03 Sebastian Wilhelmi <wilhelmi@ira.uka.de>
|
||||
|
||||
* glibconfig.h.win32, config.h.win32: Moved G_THREADS_IMPL_POSIX
|
||||
|
21
ghook.c
21
ghook.c
@ -177,6 +177,7 @@ g_hook_unref (GHookList *hook_list,
|
||||
GHook *hook)
|
||||
{
|
||||
g_return_if_fail (hook_list != NULL);
|
||||
g_return_if_fail (hook_list->hook_memchunk != NULL);
|
||||
g_return_if_fail (hook != NULL);
|
||||
g_return_if_fail (hook->ref_count > 0);
|
||||
|
||||
@ -196,15 +197,21 @@ g_hook_unref (GHookList *hook_list,
|
||||
hook->next = NULL;
|
||||
}
|
||||
hook->prev = NULL;
|
||||
|
||||
g_hook_free (hook_list, hook);
|
||||
|
||||
if (!hook_list->hooks &&
|
||||
!hook_list->is_setup)
|
||||
|
||||
if (!hook_list->is_setup)
|
||||
{
|
||||
g_mem_chunk_destroy (hook_list->hook_memchunk);
|
||||
hook_list->hook_memchunk = NULL;
|
||||
hook_list->is_setup = TRUE;
|
||||
g_hook_free (hook_list, hook);
|
||||
hook_list->is_setup = FALSE;
|
||||
|
||||
if (!hook_list->hooks)
|
||||
{
|
||||
g_mem_chunk_destroy (hook_list->hook_memchunk);
|
||||
hook_list->hook_memchunk = NULL;
|
||||
}
|
||||
}
|
||||
else
|
||||
g_hook_free (hook_list, hook);
|
||||
}
|
||||
}
|
||||
|
||||
|
21
glib/ghook.c
21
glib/ghook.c
@ -177,6 +177,7 @@ g_hook_unref (GHookList *hook_list,
|
||||
GHook *hook)
|
||||
{
|
||||
g_return_if_fail (hook_list != NULL);
|
||||
g_return_if_fail (hook_list->hook_memchunk != NULL);
|
||||
g_return_if_fail (hook != NULL);
|
||||
g_return_if_fail (hook->ref_count > 0);
|
||||
|
||||
@ -196,15 +197,21 @@ g_hook_unref (GHookList *hook_list,
|
||||
hook->next = NULL;
|
||||
}
|
||||
hook->prev = NULL;
|
||||
|
||||
g_hook_free (hook_list, hook);
|
||||
|
||||
if (!hook_list->hooks &&
|
||||
!hook_list->is_setup)
|
||||
|
||||
if (!hook_list->is_setup)
|
||||
{
|
||||
g_mem_chunk_destroy (hook_list->hook_memchunk);
|
||||
hook_list->hook_memchunk = NULL;
|
||||
hook_list->is_setup = TRUE;
|
||||
g_hook_free (hook_list, hook);
|
||||
hook_list->is_setup = FALSE;
|
||||
|
||||
if (!hook_list->hooks)
|
||||
{
|
||||
g_mem_chunk_destroy (hook_list->hook_memchunk);
|
||||
hook_list->hook_memchunk = NULL;
|
||||
}
|
||||
}
|
||||
else
|
||||
g_hook_free (hook_list, hook);
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user