Re: [PATCH 2/2] util: command: improve generic mass close of fds

2020-08-19 Thread Natanael Copa
On Wed, 19 Aug 2020 11:55:06 +0100 Daniel P. Berrangé wrote: > On Wed, Aug 19, 2020 at 12:03:41PM +0200, Natanael Copa wrote: > > Add a portable generic implementation of virMassClose as fallback on > > non-FreeBSD and non-glibc. > > > > This implementation uses poll(2) to look for open files

Re: [PATCH 2/2] util: command: improve generic mass close of fds

2020-08-19 Thread Daniel P . Berrangé
On Wed, Aug 19, 2020 at 12:03:41PM +0200, Natanael Copa wrote: > Add a portable generic implementation of virMassClose as fallback on > non-FreeBSD and non-glibc. > > This implementation uses poll(2) to look for open files to keep > performance reasonable while not using any mallocs. The patch

[PATCH 2/2] util: command: improve generic mass close of fds

2020-08-19 Thread Natanael Copa
Add a portable generic implementation of virMassClose as fallback on non-FreeBSD and non-glibc. This implementation uses poll(2) to look for open files to keep performance reasonable while not using any mallocs. This solves a deadlock with musl libc. Signed-off-by: Natanael Copa ---