aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--README.md2
-rw-r--r--fuzzer/fuzzer.go4
2 files changed, 5 insertions, 1 deletions
diff --git a/README.md b/README.md
index 7617bc2b8..d9b7cff28 100644
--- a/README.md
+++ b/README.md
@@ -56,6 +56,8 @@ In particular:
$SSHID -p $PORT root@localhost` without being prompted for a password (where `SSHID` is the SSH
identification file and `PORT` is the port that are specified in the `manager` configuration
file).
+ - The kernel exports coverage information via a debugfs entry, so the VM image needs to mount
+ the debugfs filesystem at `/sys/kernel/debug`.
TODO: Describe how to support other types of VM other than QEMU.
diff --git a/fuzzer/fuzzer.go b/fuzzer/fuzzer.go
index f71b2d90f..f85a59a64 100644
--- a/fuzzer/fuzzer.go
+++ b/fuzzer/fuzzer.go
@@ -518,8 +518,10 @@ func (g *Gate) Leave(idx int) {
func kmemleakInit() {
fd, err := syscall.Open("/sys/kernel/debug/kmemleak", syscall.O_RDWR, 0)
if err != nil {
- if !*flagLeak {
+ if *flagLeak {
panic(err)
+ } else {
+ return
}
}
defer syscall.Close(fd)