mirror of
https://github.com/SELinuxProject/selinux
synced 2024-12-24 23:12:05 +00:00
semodule_package: Close leaking fd
Signed-off-by: Petr Lautrbach <plautrba@redhat.com>
This commit is contained in:
parent
28510556f8
commit
ac16531b5a
@ -73,6 +73,7 @@ static int file_to_data(const char *path, char **data, size_t * len)
|
|||||||
goto err;
|
goto err;
|
||||||
}
|
}
|
||||||
if (!sb.st_size) {
|
if (!sb.st_size) {
|
||||||
|
close(fd);
|
||||||
*len = 0;
|
*len = 0;
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user