Sophie

Sophie

distrib > Fedora > 17 > i386 > media > updates-src > by-pkgid > ab4b662b9827b6375ffd451bf4abd615 > files > 556

systemd-44-24.fc17.src.rpm

From 40ea553204c855d8eba3bbf3d7a89de33514c030 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?V=C3=A1clav=20Pavl=C3=ADn?= <vpavlin@redhat.com>
Date: Fri, 21 Sep 2012 12:04:02 +0200
Subject: [PATCH] cgtop: missing '-'

Return codes in systemd are negated and
if (r < 0)  if (r == ENOENT)
        was never true.
(cherry picked from commit 2f29c419b01c104475f04d58a873b181273cfd8b)
---
 src/cgtop/cgtop.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/cgtop/cgtop.c b/src/cgtop/cgtop.c
index a44e59f..cec0c4b 100644
--- a/src/cgtop/cgtop.c
+++ b/src/cgtop/cgtop.c
@@ -297,7 +297,7 @@ static int refresh_one(
 
         r = cg_enumerate_subgroups(controller, path, &d);
         if (r < 0) {
-                if (r == ENOENT)
+                if (r == -ENOENT)
                         return 0;
 
                 return r;