ETH_P_* constants (and probably more I haven't stumbled across) should be defined as c_ushorton linux x86-64 rather than c_int for 2 related reasons:
- To improve ease of use with the various
sockaddr_* structs where they most often get used.
- Because when they are converted to big endian network ordering for use in those structs,
(0x00000003).to_be() != (0x0003).to_be(), which is a really irritating gotcha.
I'm happy to do a find-and-replace to get those (and any others which people think should be changed) if you think it's a sane change.
ETH_P_*constants (and probably more I haven't stumbled across) should be defined asc_ushorton linux x86-64 rather thanc_intfor 2 related reasons:sockaddr_*structs where they most often get used.(0x00000003).to_be() != (0x0003).to_be(), which is a really irritating gotcha.I'm happy to do a find-and-replace to get those (and any others which people think should be changed) if you think it's a sane change.