On Tue, Dec 31, 2024 at 08:25:00PM +0000, Diego Nieto Cid wrote:
> On Tue, Dec 31, 2024 at 04:01:08PM +0000, Diego Nieto Cid wrote:
> >
> > Ok, I'll have a look in both OSes behaviour.
>
> There's something wrong with our CMSG_DATA macro. It produces the wrong
> output (or at least different from Linux).
>
> The attached program prints:
>
> cmsg: 0x101040a90; data: 0x101040a9c; hurd=0x101040a9c, linux=0x101040aa0
>
> data seems to be off by 4 bytes compared to linux output.
Adding the following line to the program:
printf("cmsghdr: %lu\n", sizeof (struct cmsghdr));
shows 12 on Hurd and 16 on Linux. I think I'm closer :)