Commit 553a5ec4 authored by Nick Kralevich's avatar Nick Kralevich
Browse files

mmap: Don't call madvise if mmap fails

Fix improper check of return value from __mmap2. On a failed
mmap(), it returns MAP_FAILED, not 0. This ended up clobbering errno
when madvise subsequently failed.

Change-Id: I364fb2f158fe258c55a73e552195384b2c11c193
parent c6ac3ae2
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment