diff options
author | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2016-01-11 14:31:14 -0500 |
---|---|---|
committer | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2016-01-13 15:10:17 -0500 |
commit | b3267152783d5784c45010615045d4e8ee459da2 (patch) | |
tree | 4c616f8441b42dcb07cedad7958da2af3750dce2 /src/backlight/backlight.c | |
parent | f5e5c28f42a2f6d006785ec8b5e98c11a71bb039 (diff) |
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.
Diffstat (limited to 'src/backlight/backlight.c')
-rw-r--r-- | src/backlight/backlight.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/backlight/backlight.c b/src/backlight/backlight.c index b0fa079fec..a59459bc26 100644 --- a/src/backlight/backlight.c +++ b/src/backlight/backlight.c @@ -323,7 +323,7 @@ int main(int argc, char *argv[]) { errno = 0; device = udev_device_new_from_subsystem_sysname(udev, ss, sysname); if (!device) { - if (errno != 0) + if (errno > 0) log_error_errno(errno, "Failed to get backlight or LED device '%s:%s': %m", ss, sysname); else log_oom(); |