Grr, another fix for bitfields, this time for a sequence of

bitfields, i.e. the offset changes from one bitfield to another.

Signed-off-by: Arnaldo Carvalho de Melo <acme@mandriva.com>
This commit is contained in:
Arnaldo Carvalho de Melo 2006-10-25 12:14:27 -03:00
parent e45d94f9de
commit a4e260fc1a
1 changed files with 2 additions and 1 deletions

View File

@ -295,7 +295,8 @@ void class__print(struct class *self)
* check for bitfields, accounting only the first
* field.
*/
if (pos->bit_size == 0 || last_bit_size == 0)
if (last_offset != pos->offset ||
pos->bit_size == 0 || last_bit_size == 0)
sum += last_size;
last_offset = pos->offset;
last_bit_size = pos->bit_size;