From e4fee22b94d62824fa6a463cbd19aa861bd87230 Mon Sep 17 00:00:00 2001
From: Guillaume Roguez <guillaume.roguez@savoirfairelinux.com>
Date: Fri, 6 Jan 2017 16:09:17 -0500
Subject: [PATCH] remove annoying RING_ERR log in fileutils

Remove the RING_ERR call with directory argument doesn't exist
when fileutils::readDirectory() is called.

This function returns an empty result if such case that's enough
for callers to log something if they want. but not log (as error)
by default, more annoying!

Change-Id: I0f1fff604de70997f3f6419ccd050687629e10d4
---
 src/fileutils.cpp | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/src/fileutils.cpp b/src/fileutils.cpp
index 0894383cb1..037d6c37c3 100644
--- a/src/fileutils.cpp
+++ b/src/fileutils.cpp
@@ -336,10 +336,8 @@ std::vector<std::string>
 readDirectory(const std::string& dir)
 {
     DIR *dp = opendir(dir.c_str());
-    if (!dp) {
-        RING_ERR("Could not open %s", dir.c_str());
+    if (!dp)
         return {};
-    }
 
     size_t size = dirent_buf_size(dp);
     if (size == (size_t)(-1))
-- 
GitLab