This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH 11/13] Installed-header hygiene (BZ#20366): struct osockaddr.


On 08/29/2016 09:16 PM, Zack Weinberg wrote:
> sys/socket.h defines struct osockaddr only under __USE_MISC, whereas
> protocols/talkd.h requires it unconditionally.  This is another place
> where the bits/types/foo.h approach comes in handy.
> 
> I would also be amenable to removing struct osockaddr from sys/socket.h,
> defining it only in protocols/talkd.h, on the theory that nothing else
> should be using it anymore.  (Frankly, I doubt anyone would miss
> protocols/talkd.h at this point, but we _have_ historically preferred
> not to delete anything.)

Without a strong reason for deleting it we should keep it :-)
 
> 	* socket/bits/types/struct_osockaddr.h: New header.
> 	* include/bits/types/struct_osockaddr.h: New wrapper.
> 	* socket/Makefile: Install the new header.
> 	* socket/sys/socket.h
> 	* inet/protocols/talkd.h: Refer to bits/types/struct_osockaddr.h
> 	for the definition of struct osockaddr.

LGTM.

-- 
Cheers,
Carlos.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]