Buffer fields hit assertion when applied to unnamed buffers
avdgrinten opened this issue · 0 comments
avdgrinten commented
When a buffer field (BITFIELD_OP, BYTEFIELD_OP, WORDFIELD_OP, DWORDFIELD_OP, QWORDFIELD_OP or ARBFIELD_OP) targets an unnamed buffer (e.g., an immediate operand), LAI dies with the error below.
This should be fixed by storing a reference to the buffer in struct lai_nsnode
s of type LAI_NAMESPACE_BUFFER_FIELD
(and not a reference to another struct lai_nsnode
as we do currently). More precisely, we should store a struct lai_buffer_head *
(and increment its reference count using lai_rc_ref
).