Date: Sat, 26 Jan 2002 18:13:52 +0100 From: Bernd Walter <ticso@cicely8.cicely.de> To: freebsd-alpha@freebsd.org Subject: ifconfig alignment fix Message-ID: <20020126181352.C75106@cicely8.cicely.de>
next in thread | raw e-mail | index | archive | help
--DBIVS5p969aUjpLe Content-Type: text/plain; charset=us-ascii Content-Disposition: inline The reason is that struct ifa_msghdr is not n * 8 bytes. If an interface has an uneven number of addresses it toggles alignment for the next interface. I would be more happy when struct ifa_msghdr gets resized, but that will break binary compatibility. -- B.Walter COSMO-Project http://www.cosmo-project.de ticso@cicely.de Usergroup info@cosmo-project.de --DBIVS5p969aUjpLe Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="ifconfig_align.patch" --- sys/net/rtsock.c.orig Sat Jan 26 16:59:56 2002 +++ sys/net/rtsock.c Sat Jan 26 17:00:01 2002 @@ -664,6 +664,7 @@ } len += dlen; } + len = _ALIGN(len); if (cp == 0 && w != NULL && !second_time) { register struct walkarg *rw = w; --DBIVS5p969aUjpLe-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-alpha" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020126181352.C75106>