From 0256e324c7befaf5e3ec43fb5ac7af6aca220225 Mon Sep 17 00:00:00 2001 From: Helmut Grohne Date: Sat, 25 May 2024 10:35:49 +0200 Subject: examples/chrootfuse.py: fix file descriptor leak Fixes: f01c7690de8e ("add example chrootfuse2fs.py") --- examples/chrootfuse.py | 1 + 1 file changed, 1 insertion(+) diff --git a/examples/chrootfuse.py b/examples/chrootfuse.py index ef67e8a..93a9da0 100755 --- a/examples/chrootfuse.py +++ b/examples/chrootfuse.py @@ -50,6 +50,7 @@ def main() -> None: "squashfs": "squashfuse", }[args.fstype] os.execlp(driver, driver, str(args.fsimage), "/dev/fd/%d" % fds[0]) + childsock.close() linuxnamespaces.unshare( linuxnamespaces.CloneFlags.NEWUSER | linuxnamespaces.CloneFlags.NEWNS ) -- cgit v1.2.3