Date: Sat, 28 Dec 2002 14:17:29 -0800 (PST) From: Poul-Henning Kamp <phk@FreeBSD.org> To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: cvs commit: src/sys/sys _iovec.h socket.h uio.h Message-ID: <200212282217.gBSMHTRJ050345@repoman.freebsd.org>
index | next in thread | raw e-mail
phk 2002/12/28 14:17:29 PST
Modified files:
sys/sys socket.h uio.h
Added files:
sys/sys _iovec.h
Log:
It is bad style to define the same structure in multiple header
files which might be included together.
Things like debuggers and lint-like programs get their knickers in
a twist (rightly so one might add) when they find different locations
for the same named struct depending on which .h file were included
first.
This is a stellar example of Very Bad Thinking on the part of the
standards dudes who wrote that both sys/uio.h and sys/socket.h
should define struct iovec the same way.
Fix this by putting struct iovec into its own miniature sys/_iovec.h
file and #include that from sys/socket.h and sys/uio.h.
Sensible people could just put iovec into sys/_types.h but there
is probably some standard or other which will be violated if we
did something that horrible.
Revision Changes Path
1.1 +45 -0 src/sys/sys/_iovec.h (new)
1.70 +1 -8 src/sys/sys/socket.h
1.24 +1 -8 src/sys/sys/uio.h
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe cvs-all" in the body of the message
help
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200212282217.gBSMHTRJ050345>
