From 1f75dfd95d7d321179433be3eb1f512c64d84e54 Mon Sep 17 00:00:00 2001 From: Shannon Booth Date: Sat, 15 Feb 2020 11:23:39 +1300 Subject: [PATCH] Userland: Fix error handling in rm program Fixes: #1218 --- Userland/rm.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Userland/rm.cpp b/Userland/rm.cpp index ed0a82c52c..2b33d3d7d9 100644 --- a/Userland/rm.cpp +++ b/Userland/rm.cpp @@ -55,7 +55,7 @@ int remove(bool recursive, String path) builder.append('/'); builder.append(de->d_name); int s = remove(true, builder.to_string()); - if (s < 0) + if (s != 0) return s; } }