From a76fad090a6a1388fbaa609e8ca37e82223d2bd7 Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Fri, 18 Feb 2011 02:26:01 +0100 Subject: readahead: remove misleading error messages https://bugzilla.redhat.com/show_bug.cgi?id=678255 --- src/readahead-collect.c | 3 +++ src/readahead-replay.c | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/readahead-collect.c b/src/readahead-collect.c index 4ca6d74726..ea07b3ff49 100644 --- a/src/readahead-collect.c +++ b/src/readahead-collect.c @@ -96,6 +96,9 @@ static int pack_file(FILE *pack, const char *fn, bool on_btrfs) { if (errno == ENOENT) return 0; + if (errno == EPERM || errno == EACCES) + return 0; + log_warning("open(%s) failed: %m", fn); r = -errno; goto finish; diff --git a/src/readahead-replay.c b/src/readahead-replay.c index e9c573a593..9447fe0775 100644 --- a/src/readahead-replay.c +++ b/src/readahead-replay.c @@ -62,7 +62,7 @@ static int unpack_file(FILE *pack) { if ((fd = open(fn, O_RDONLY|O_CLOEXEC|O_NOATIME|O_NOCTTY|O_NOFOLLOW)) < 0) { - if (errno != ENOENT) + if (errno != ENOENT && errno != EPERM && errno != EACCES) log_warning("open(%s) failed: %m", fn); } else if (file_verify(fd, fn, arg_file_size_max, &st) <= 0) { -- cgit v1.2.3-54-g00ecf