From 29ecf7b04e49987dfdd0dbb78a280ba6b54a3a6a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Axel=20D=C3=B6rfler?= Date: Wed, 29 Feb 2012 23:27:46 +0100 Subject: [PATCH] command_ioctl() leaked the root directory's file descriptor. --- src/tools/fs_shell/fssh.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/tools/fs_shell/fssh.cpp b/src/tools/fs_shell/fssh.cpp index 58b51d37a1..bcff629a71 100644 --- a/src/tools/fs_shell/fssh.cpp +++ b/src/tools/fs_shell/fssh.cpp @@ -1195,6 +1195,9 @@ command_ioctl(int argc, const char* const* argv) return rootDir; fssh_status_t status = _kern_ioctl(rootDir, atoi(argv[1]), NULL, 0); + + _kern_close(rootDir); + if (status != FSSH_B_OK) { fprintf(stderr, "Error: ioctl failed: %s\n", fssh_strerror(status)); return status;