mirror of
https://github.com/AuxXxilium/kmod.git
synced 2024-12-24 18:56:46 +07:00
Add missing O_CLOEXEC in kmod_module_get_size()
This commit is contained in:
parent
ae58de0fcb
commit
74c26943f1
@ -1783,7 +1783,7 @@ KMOD_EXPORT long kmod_module_get_size(const struct kmod_module *mod)
|
||||
* loaded.
|
||||
*/
|
||||
snprintf(line, sizeof(line), "/sys/module/%s", mod->name);
|
||||
dfd = open(line, O_RDONLY);
|
||||
dfd = open(line, O_RDONLY|O_CLOEXEC);
|
||||
if (dfd < 0)
|
||||
return -errno;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user