mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-07-15 22:53:34 +02:00
g_private_new: use GSlice
We no longer call g_private_new() from anywhere in GLib, so we can use gslice instead of malloc().
This commit is contained in:
@ -2455,7 +2455,7 @@ g_private_new (GDestroyNotify notify)
|
|||||||
{
|
{
|
||||||
GPrivate *key;
|
GPrivate *key;
|
||||||
|
|
||||||
key = malloc (sizeof (GPrivate));
|
key = g_slice_new (GPrivate);
|
||||||
g_private_init (key, notify);
|
g_private_init (key, notify);
|
||||||
|
|
||||||
return key;
|
return key;
|
||||||
|
Reference in New Issue
Block a user