|
Message-ID: <3cd586df-a7fa-8660-c17e-d32aa845431c@linaro.org> Date: Mon, 28 Jan 2019 18:30:57 -0200 From: Adhemerval Zanella <adhemerval.zanella@...aro.org> To: musl@...ts.openwall.com Subject: Re: fdopendir (BUG?) On 28/01/2019 17:42, Jorge Almeida wrote: > On Mon, Jan 28, 2019 at 6:54 PM Adhemerval Zanella > <adhemerval.zanella@...aro.org> wrote: >> >> >> >> On 28/01/2019 10:37, Jorge Almeida wrote: >>> (the problem also occurs with glibc, besides the fact that glibc >>> requires also _GNU_SOURCE to compile, contradicting the linux man >>> page) >> Because O_PATH is a Linux extension and it guards such definitions >> with _GNU_SOURCE. And although man-pages is not the canonical glibc >> documentation, it does states that O_PATH is only defined if >> _GNU_SOURCE is also defined (man-pages commit >> 1135dbe188a48d7fa237396ab371ebf74037c1f6 from 2013-02-13). > > My man page for opendir has the date 2017-09-15 ("release 4.16 of > the Linux man-pages project") It says: > Feature Test Macro Requirements for glibc (see feature_test_macros(7)): > > fdopendir(): > Since glibc 2.10: > _POSIX_C_SOURCE >= 200809L > Before glibc 2.10: > _GNU_SOURCE > > I have glibc-2.27 > This is for *fdopendir* declaration, the *O_PATH* flag is documented by open.2 and it defines: --- CONFORMING TO open(), creat() SVr4, 4.3BSD, POSIX.1-2001, POSIX.1-2008. openat(): POSIX.1-2008. The O_DIRECT, O_NOATIME, O_PATH, and O_TMPFILE flags are Linux-specific. One must define _GNU_SOURCE to obtain their definitions. ---
Powered by blists - more mailing lists
Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.