mirror of https://github.com/BOINC/boinc.git
lib: fix resource leak
This commit is contained in:
parent
5282b53407
commit
d872d2bad5
|
@ -505,6 +505,7 @@ FILE* boinc_fopen(const char* path, const char* mode) {
|
|||
}
|
||||
if (f) {
|
||||
if (-1 == fcntl(fileno(f), F_SETFD, FD_CLOEXEC)) {
|
||||
fclose(f);
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue