News for hackers. Stuff that matters.
Re:A bug story: data alignment on x86 by codys on Monday November 07, 2016 @03:08PM (#12894537)
Note the use of `packed`. `packed` causes the alignment to be set as small as possible (1 byte). The aligned(2) that follows then increases the alignment from 1 byte to 2 bytes.
Re:A bug story: data alignment on x86 by qb45 on Monday November 07, 2016 @03:20PM (#12894660)
Yeah, you're right. Add packed then if you want but I swear the code I posted works on 5.4 as it is.