I have a userspace app that is doing an IPv6 IPV6_2292PKTOPTIONS setsockopt to add an Extension header in a mixed 64 bit/32 bit setup. It is failing with an EINVAL because it seems the cmsghdr doesn't get the proper fixup. This isn't stuff I really look at much but I came up with this hack to at least get past the error. All my userspace is 32 bits so I just put in the "#if 1" rather than attempting a runtime check on the socket. I am not sure if the userspace app is doing something wrong, but it seems like this is a real problem. The "on the stack" assumption by the fixup helper seems like it really should be reworked, but I have no idea how it should be done. And I didn't bother to handle the the getsockopt function. Doing a grep I didn't find any other offenders, but I can't say for sure. Does anyone have any ideas on the "right" way to fix this, or point out my flaw? Thanks.