Date: Wed, 18 May 2016 16:59:35 -0700 (PDT) From: Chris Torek <torek@elf.torek.net> To: brde@optusnet.com.au, ian@freebsd.org Cc: glebius@freebsd.org, src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r300167 - in head: contrib/bsnmp/snmpd usr.sbin/bsnmpd/bsnmpd Message-ID: <201605182359.u4INxZUk022590@elf.torek.net> In-Reply-To: <20160519092734.U1798@besplex.bde.org>
next in thread | previous in thread | raw e-mail | index | archive | help
>I don't know much about CMSG*, so I wouldn't have if you didn't ask :-). One thing to know about the CMSG (control message) stuff is that it is badly broken, at least on I32LP64 systems. Not the CMSG_* aligning macros themselves (the alignment is linked to stuff I did back in the early sparc-port days, around 1992 or so), but internally, when file descriptor rights are internalized before sending. This converts them from 32 bit "int"s to 64 bit pointers, which winds up breaking other code. See https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=181741 (I attached a revised set of patches that apply to current kernels, adding a rewrite of the transform code for sanity / readability.) >... So void * works better in all cases in the kernel. If someone wanted to change CMSG_DATA, CMSG_FIRSTHDR, and CMSG_NEXTHDR to produce "void *", I'd vote in favor of that. :-) Chris
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201605182359.u4INxZUk022590>