Fix segfault when user isn't authorized to read /dev/mem