summaryrefslogtreecommitdiff
path: root/src/readahead/sd-readahead.c
diff options
context:
space:
mode:
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2013-04-11 18:57:42 -0400
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2013-04-11 19:13:18 -0400
commitbcb161b0230fdd1faf9176f95fee76a7db6afd59 (patch)
treec3ba8c1cf806c961842bd51b42c6e8f9b7b59c6e /src/readahead/sd-readahead.c
parent0ad4e1a872e789c77828d4c4825a56241103650c (diff)
errno is positive
Make sure we compare errno against positive error codes. The ones in hwclock.c and install.c can have an impact, the rest are unlikely to be hit or in code that isn't widely used. Also check that errno > 0, to help gcc know that we are returning a negative error code.
Diffstat (limited to 'src/readahead/sd-readahead.c')
-rw-r--r--src/readahead/sd-readahead.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/readahead/sd-readahead.c b/src/readahead/sd-readahead.c
index 4a096eed42..675d82cdd1 100644
--- a/src/readahead/sd-readahead.c
+++ b/src/readahead/sd-readahead.c
@@ -65,7 +65,7 @@ static int touch(const char *path) {
if (close(fd) >= 0)
break;
- if (errno != -EINTR)
+ if (errno != EINTR)
return -errno;
}