Bug 569408, Bug 568680 - Scanner misses fields (at least in GObject.Object)

The scanner misses all fields of the GObject struct -- there
are no <field> children of the <class> element for GObject in the GIR. This of
course yields wrong field offsets for all derived objects.

svn path=/trunk/; revision=1079
This commit is contained in:
Colin Walters 2009-02-02 16:31:06 +00:00
parent 4e5037e0f3
commit 306ca05c5e

View File

@ -357,8 +357,9 @@ compute_struct_field_offsets (GIrNode *node,
}
else if (member->type == G_IR_NODE_CALLBACK)
{
size = ffi_type_pointer.size;
alignment = ffi_type_pointer.alignment;
size = ALIGN (size, ffi_type_pointer.alignment);
alignment = MAX (alignment, ffi_type_pointer.alignment);
size += ffi_type_pointer.size;
}
}