diff options
author | Lennart Poettering <lennart@poettering.net> | 2011-05-25 18:02:28 +0200 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2011-05-25 18:02:28 +0200 |
commit | cf37e24688971b29223858f733beb1b85e3af03c (patch) | |
tree | 91200a08668455ca092f1a1d30cf8783e7fdb556 | |
parent | 3afe3725fcf21fab7204243b9485a118e499b4a3 (diff) |
readahead: explain that it is safe to ignore EACCES
-rw-r--r-- | src/readahead-collect.c | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/src/readahead-collect.c b/src/readahead-collect.c index 913a34005e..20881b3944 100644 --- a/src/readahead-collect.c +++ b/src/readahead-collect.c @@ -380,7 +380,17 @@ static int collect(const char *root) { if ((n = read(fanotify_fd, &data, sizeof(data))) < 0) { - if (errno == EINTR || errno == EAGAIN || errno == EACCES) + if (errno == EINTR || errno == EAGAIN) + continue; + + /* fanotify sometimes returns EACCES on read() + * where it shouldn't. For now let's just + * ignore it here (which is safe), but + * eventually this should be + * dropped when the kernel is fixed. + * + * https://bugzilla.redhat.com/show_bug.cgi?id=707577 */ + if (errno == EACCES) continue; log_error("Failed to read event: %m"); |