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 03/13] Installed-header hygiene (BZ#20366): missing inclusions A.


On 08/29/2016 09:16 PM, Zack Weinberg wrote:
> These are all fallout from the change from u_intNN_t to uintNN_t; a
> number of headers now need to include <stdint.h> to pick up those
> types.  It is possible that __uintNN_t should be used instead.

Why should __uintNN_t ever be used? At a minimum the uintNN_t types
should be available regardless of whatever mode you are being compiled in?

> Some of these files directly included <features.h> and/or
> <sys/cdefs.h>, which I removed, as the style generally seems to be to
> let <sys/types.h> do that for us.  One file included <asm/types.h>
> gratuitously.

Are you certain that was safe? I would be worried about arbitrarily
removing those headers without a deeper analysis.

> 	* inet/protocols/talkd.h, resolv/arpa/nameser.h
> 	* sysdeps/generic/netinet/in_systm.h
> 	* sysdeps/gnu/netinet/ip_icmp.h, sysdeps/gnu/netinet/tcp.h
> 	* sysdeps/gnu/netinet/udp.h
> 	* sysdeps/unix/sysv/linux/net/ethernet.h
> 	* sysdeps/unix/sysv/linux/net/if_arp.h
> 	* sysdeps/unix/sysv/linux/net/if_ppp.h
> 	* sysdeps/unix/sysv/linux/net/if_shaper.h
> 	* sysdeps/unix/sysv/linux/netinet/if_fddi.h
> 	* sysdeps/unix/sysv/linux/netinet/if_tr.h
> 	* sysdeps/unix/sysv/linux/netipx/ipx.h
> 	* sysdeps/unix/sysv/linux/sys/acct.h
> 	* sysdeps/unix/sysv/linux/sys/quota.h:
> 	Include stdint.h for uintNN_t definitions.
> 	Don't include sys/cdefs.h, features.h, or asm/types.h directly.

OK only if you verified that the generated code did not change due to the
removal of unneeded headers, or if you drop the unneeded header removal.

-- 
Cheers,
Carlos.


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