From 4f9139778da385083c8de55116110dbebefd06df Mon Sep 17 00:00:00 2001 From: Ben Gras Date: Sat, 16 Mar 2013 04:13:02 +0000 Subject: [PATCH] vfs: coredump fix: write zeroes for missing memory --- servers/vfs/coredump.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/servers/vfs/coredump.c b/servers/vfs/coredump.c index 43ccfda4f..9b5d24573 100644 --- a/servers/vfs/coredump.c +++ b/servers/vfs/coredump.c @@ -310,9 +310,9 @@ static void dump_segments(struct filp *f, Elf_Phdr phdrs[], int phnum) (phys_bytes) CLICK_SIZE); if(r != OK) { - printf("VFS: vircopy failed for %d @ 0x%lx during coredump\n", - fp->fp_endpoint, p); - break; + /* memory didn't exist; write as zeroes */ + memset(buf, 0, sizeof(buf)); + continue; } write_buf(f, (char *) buf, (off + CLICK_SIZE <= (off_t) len) ?