mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-02-24 03:02:10 +01:00
Merge from trunk:
2007-06-15 Cody Russell <cody@jhu.edu> Merge from trunk: * gobject/gtype.c (g_type_class_add_private): Check for 0-sized private data. (#443869) svn path=/branches/glib-2-12/; revision=5562
This commit is contained in:
parent
5acfdc7ca2
commit
528be68c00
@ -1,3 +1,10 @@
|
||||
2007-06-15 Cody Russell <cody@jhu.edu>
|
||||
|
||||
Merge from trunk:
|
||||
|
||||
* gobject/gtype.c (g_type_class_add_private): Check for 0-sized
|
||||
private data. (#443869)
|
||||
|
||||
2007-06-11 Tor Lillqvist <tml@novell.com>
|
||||
|
||||
* glib/gwin32.c (g_win32_get_package_installation_directory)
|
||||
|
@ -3483,6 +3483,8 @@ g_type_class_add_private (gpointer g_class,
|
||||
TypeNode *node = lookup_type_node_I (instance_type);
|
||||
gsize offset;
|
||||
|
||||
g_return_if_fail (private_size > 0);
|
||||
|
||||
if (!node || !node->is_instantiatable || !node->data || node->data->class.class != g_class)
|
||||
{
|
||||
g_warning ("cannot add private field to invalid (non-instantiatable) type '%s'",
|
||||
|
Loading…
x
Reference in New Issue
Block a user