Fix a crash with mmap