diff options
Diffstat (limited to 'libdwfl/linux-proc-maps.c')
| -rw-r--r-- | libdwfl/linux-proc-maps.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/libdwfl/linux-proc-maps.c b/libdwfl/linux-proc-maps.c index b4bb6cfc..2206f63c 100644 --- a/libdwfl/linux-proc-maps.c +++ b/libdwfl/linux-proc-maps.c @@ -267,6 +267,9 @@ read_proc_memory (void *arg, void *data, GElf_Addr address, { const int fd = *(const int *) arg; ssize_t nread = pread64 (fd, data, maxread, (off64_t) address); + /* Some kernels don't actually let us do this read, ignore those errors. */ + if (nread < 0 && (errno == EINVAL || errno == EPERM)) + return 0; if (nread > 0 && (size_t) nread < minread) nread = 0; return nread; |
