mirror of
https://github.com/alsa-project/alsa-lib.git
synced 2025-10-29 05:40:25 -04:00
ucm: use close_range on _GNU_SOURCE
This commit is contained in:
parent
07ec2ad34c
commit
2566687eba
1 changed files with 4 additions and 0 deletions
|
|
@ -254,8 +254,12 @@ int uc_mgr_exec(const char *prog)
|
|||
|
||||
close(f);
|
||||
|
||||
#if defined(_GNU_SOURCE)
|
||||
close_range(3, maxfd, 0);
|
||||
#else
|
||||
for (f = 3; f < maxfd; f++)
|
||||
close(f);
|
||||
#endif
|
||||
|
||||
/* install default handlers for the forked process */
|
||||
signal(SIGINT, SIG_DFL);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue