Re: [PATCH] git-compat-util: prefer poll.h to sys/poll.h

2018-11-13 Thread Junio C Hamano
Đoàn Trần Công Danh writes: > -#ifndef NO_SYS_POLL_H > +#if !defined(NO_POLL_H) > +#include > +#elif !defined(NO_SYS_POLL_H) > #include > #else > +/* Pull the compat stuff */ > #include > #endif The last comment would help readers who got "Huh? When NO_POLL_H and NO_SYS_POLL_H is given,

Re: [PATCH] git-compat-util: prefer poll.h to sys/poll.h

2018-11-13 Thread Danh Doan
"brian m. carlson" writes: >> - t1308.23 is failing because musl `fopen` is success when open directory >> in readonly mode. POSIX allows this behavior: >> http://pubs.opengroup.org/onlinepubs/7908799/xsh/fopen.html >> [EISDIR] >> The named file is a directory and mode requires write access. > >

Re: [PATCH] git-compat-util: prefer poll.h to sys/poll.h

2018-11-13 Thread Junio C Hamano
"brian m. carlson" writes: > On Wed, Nov 14, 2018 at 08:10:43AM +0700, Đoàn Trần Công Danh wrote: >> POSIX specifies that is the correct header for poll(2) >> whereas is only needed for some old libc. >> >> Let's follow the POSIX way by default. >> >> This effectively eliminates musl's warnin

Re: [PATCH] git-compat-util: prefer poll.h to sys/poll.h

2018-11-13 Thread brian m. carlson
On Wed, Nov 14, 2018 at 08:10:43AM +0700, Đoàn Trần Công Danh wrote: > POSIX specifies that is the correct header for poll(2) > whereas is only needed for some old libc. > > Let's follow the POSIX way by default. > > This effectively eliminates musl's warning: > > warning redirecting incor

[PATCH] git-compat-util: prefer poll.h to sys/poll.h

2018-11-13 Thread Đoàn Trần Công Danh
POSIX specifies that is the correct header for poll(2) whereas is only needed for some old libc. Let's follow the POSIX way by default. This effectively eliminates musl's warning: warning redirecting incorrect #include to Signed-off-by: Đoàn Trần Công Danh --- t0028, t1308.23, t3900.34