mirror of
https://github.com/corda/corda.git
synced 2025-01-07 13:38:47 +00:00
fix bootimage field offset calculation for derived classes
There was a subtle bug in that we were not considering alignment padding for fields defined in superclasses when calculating field offsets for a derived class when the superclass(es) were visited by the bootimage generator before the derived class.
This commit is contained in:
parent
1d77b06540
commit
ac63d08450
@ -435,6 +435,10 @@ makeCodeImage(Thread* t, Zone* zone, BootImage* image, uint8_t* code,
|
||||
|
||||
memberFields[memberIndex] = *f;
|
||||
|
||||
while (targetMemberOffset % f->targetSize) {
|
||||
++ targetMemberOffset;
|
||||
}
|
||||
|
||||
targetMemberOffset += f->targetSize;
|
||||
|
||||
++ memberIndex;
|
||||
|
Loading…
Reference in New Issue
Block a user