mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-03-14 19:55:12 +01:00
Don't do pointer arithmetics on void*
For instance MSVC doesn't like that. Signed-off-by: Tor Lillqvist <tml@iki.fi>
This commit is contained in:
parent
759fbac7b7
commit
4c55b45162
@ -77,7 +77,7 @@ freelist_alloc (gsize size, gboolean reuse)
|
|||||||
|
|
||||||
real_size = sizeof (gsize) + MAX (size, sizeof (FreeListNode));
|
real_size = sizeof (gsize) + MAX (size, sizeof (FreeListNode));
|
||||||
mem = g_slice_alloc (real_size);
|
mem = g_slice_alloc (real_size);
|
||||||
mem += sizeof (gsize);
|
mem = ((char *) mem) + sizeof (gsize);
|
||||||
G_ATOMIC_ARRAY_DATA_SIZE (mem) = size;
|
G_ATOMIC_ARRAY_DATA_SIZE (mem) = size;
|
||||||
return mem;
|
return mem;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user