mirror of
https://github.com/Rockbox/rockbox.git
synced 2025-11-09 13:12:37 -05:00
hosted: Use O_CLOEXEC for all open() and "e" for fopen() calls
This way we'll automatically close the files upon exec() Change-Id: Ic0daca8fb56432830de4a2f4a86a77337121ecc7
This commit is contained in:
parent
4f8736909a
commit
5cfd3ae4e6
14 changed files with 27 additions and 31 deletions
|
|
@ -77,7 +77,7 @@ void button_init_device(void)
|
|||
|
||||
for(int i = 0; i < NR_POLL_DESC; i++)
|
||||
{
|
||||
int fd = open(input_devs[i], O_RDWR);
|
||||
int fd = open(input_devs[i], O_RDWR | O_CLOEXEC);
|
||||
|
||||
if(fd < 0)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue