<sys/quota.h> standards compliance
Zack Weinberg
zackw@panix.com
Mon Aug 22 16:03:00 GMT 2016
On Fri, Aug 19, 2016 at 8:04 AM, Florian Weimer <fweimer@redhat.com> wrote:
> Are there any namespace standards compliance requirements for the
> <sys/quota.h> installed header?
It's not in C, POSIX, nor XSI, so probably the only concerns are BSD
compatibility (the non-Linux-specific aspects of this file look very
BSDish to me) and general tidiness. I don't know what BSD
compatibility would entail for this file. <linux/quota.h> looks
acceptably tidy as is; the only symbols that don't at least have a 'q'
somewhere are SUBCMDMASK, SUBCMDSHIFT, and the IIF_* constants, and
those are already in <sys/quota.h> so *shrug*. Actually I think the
kernel's version has fewer dubious macros...
> If there aren't any namespace issues, I propose to remove all duplicate
> definitions from it, include <linux/quota.h> from the file, and leave in
> <sys/quota.h> only the glibc-specific additions.
>
> Is this a viable plan?
The only thing I'd add is, while you're at it, please make sure none
of the glibc-specific additions are using the legacy u_intN_t, u_long,
etc. typedefs. It might be best to use kernel-style __i64, __u64, etc
for consistency with the kernel header.
zw
More information about the Libc-alpha
mailing list