chiark / gitweb /
Always use errno > 0 to help gcc
[elogind.git] / src / tmpfiles / tmpfiles.c
index 4a76a2f778bbfbdcbab1bb8b7c9310dd1fdb086a..918702e06f0fa6ea28d79b78521da2856c830af8 100644 (file)
@@ -43,6 +43,7 @@
 #include "log.h"
 #include "util.h"
 #include "macro.h"
+#include "missing.h"
 #include "mkdir.h"
 #include "path-util.h"
 #include "strv.h"
@@ -610,7 +611,7 @@ static int glob_item(Item *i, int (*action)(Item *, const char *)) {
         if ((k = glob(i->path, GLOB_NOSORT|GLOB_BRACE, NULL, &g)) != 0) {
 
                 if (k != GLOB_NOMATCH) {
-                        if (errno != 0)
+                        if (errno > 0)
                                 errno = EIO;
 
                         log_error("glob(%s) failed: %m", i->path);