From 1ca946af2f5f9e96a3171e59eea92e96bce88a1e Mon Sep 17 00:00:00 2001 From: Jonas 'Sortie' Termansen Date: Tue, 23 Apr 2013 20:03:57 +0200 Subject: [PATCH] Fix ls exit code. --- utils/ls.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/utils/ls.cpp b/utils/ls.cpp index 8534a0fd..b8db290f 100644 --- a/utils/ls.cpp +++ b/utils/ls.cpp @@ -1,6 +1,6 @@ /******************************************************************************* - Copyright(C) Jonas 'Sortie' Termansen 2011, 2012. + Copyright(C) Jonas 'Sortie' Termansen 2011, 2012, 2013. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free @@ -184,6 +184,8 @@ int ls(const char* path) goto cleanup_dir; } + ret = 0; + cleanup_dir: closedir(dir); cleanup_entries: