tree-wide: check if errno is greater than zero (2)
Compare errno with zero in a way that tells gcc that (if the condition is true) errno is positive.
This commit is contained in:
+1
-1
@@ -156,7 +156,7 @@ static int iterate_dir(
|
||||
|
||||
errno = 0;
|
||||
de = readdir(d);
|
||||
if (!de && errno != 0)
|
||||
if (!de && errno > 0)
|
||||
return log_error_errno(errno, "Failed to read directory %s: %m", path);
|
||||
|
||||
if (!de)
|
||||
|
||||
Reference in New Issue
Block a user