From c852f04a83eb47afc3e3066e466bb5a218311a09 Mon Sep 17 00:00:00 2001 From: Ingo Weinhold Date: Thu, 20 Mar 2008 13:34:23 +0000 Subject: [PATCH] "rm" was leaking the dir FD when failing to read from the dir. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24493 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/tools/fs_shell/fssh.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/tools/fs_shell/fssh.cpp b/src/tools/fs_shell/fssh.cpp index 8f0a7a73b0..0060469627 100644 --- a/src/tools/fs_shell/fssh.cpp +++ b/src/tools/fs_shell/fssh.cpp @@ -887,7 +887,7 @@ remove_dir_contents(int parentDir, const char *name, bool force) if (numRead < 0) { fprintf(stderr, "Error: Failed to read directory \"%s\": %s\n", name, fssh_strerror(numRead)); - return numRead; + error = numRead; } // close