Re: [PATCH] tests: commandhelper: Accept POLLNVAL on macOS

2020-10-08 Thread Ján Tomko
On a Wednesday in 2020, Roman Bolshakov wrote: On Wed, Oct 07, 2020 at 07:17:05PM +0200, Ján Tomko wrote: On a Wednesday in 2020, Roman Bolshakov wrote: Hi Jano, *indefinitely Thanks, I'll correct it. > BUGS >The poll() system call currently does not support devices. > Is there a

Re: [PATCH] tests: commandhelper: Accept POLLNVAL on macOS

2020-10-07 Thread Roman Bolshakov
On Wed, Oct 07, 2020 at 07:17:05PM +0200, Ján Tomko wrote: > On a Wednesday in 2020, Roman Bolshakov wrote: Hi Jano, > > *indefinitely > Thanks, I'll correct it. > > BUGS > >The poll() system call currently does not support devices. > > > > Is there a bug that track this? If so, includ

Re: [PATCH] tests: commandhelper: Accept POLLNVAL on macOS

2020-10-07 Thread Roman Bolshakov
On Wed, Oct 07, 2020 at 06:57:21PM +0200, Andrea Bolognani wrote: > On Wed, 2020-10-07 at 15:20 +0300, Roman Bolshakov wrote: > > for (i = 0; i < numpollfds; i++) { > > -if (fds[i].revents & (POLLIN | POLLHUP | POLLERR)) { > > +if (fds[i].revents & (POLLIN | POLLHUP

Re: [PATCH] tests: commandhelper: Accept POLLNVAL on macOS

2020-10-07 Thread Ján Tomko
On a Wednesday in 2020, Roman Bolshakov wrote: commandhelper hangs indefinetely in poll() on macOS on commandtest test2 *indefinitely and later because POLLNVAL is returned on revents for input file descriptor opened from /dev/null, i.e this hangs: $ tests/commandhelper < /dev/null BEGIN S

Re: [PATCH] tests: commandhelper: Accept POLLNVAL on macOS

2020-10-07 Thread Andrea Bolognani
On Wed, 2020-10-07 at 15:20 +0300, Roman Bolshakov wrote: > for (i = 0; i < numpollfds; i++) { > -if (fds[i].revents & (POLLIN | POLLHUP | POLLERR)) { > +if (fds[i].revents & (POLLIN | POLLHUP | POLLERR | > +# ifdef __APPLE__ > + /*

[PATCH] tests: commandhelper: Accept POLLNVAL on macOS

2020-10-07 Thread Roman Bolshakov
commandhelper hangs indefinetely in poll() on macOS on commandtest test2 and later because POLLNVAL is returned on revents for input file descriptor opened from /dev/null, i.e this hangs: $ tests/commandhelper < /dev/null BEGIN STDOUT BEGIN STDERR ^C But it works fine with regular stdin: