Don't crash if PR_SET_VMA_ANON_NAME fails.

This prctl is not implemented on very old devices.
It is not necessary for the core functionality of the tool. Simply
ignore the failure.

llvm-svn: 363755
This commit is contained in:
Evgeniy Stepanov 2019-06-18 23:50:43 +00:00
parent 2b285c664d
commit c6b5be6cf0
1 changed files with 1 additions and 2 deletions

View File

@ -367,8 +367,7 @@ int GetNamedMappingFd(const char *name, uptr size, int *flags) {
void DecorateMapping(uptr addr, uptr size, const char *name) {
if (!common_flags()->decorate_proc_maps || !name)
return;
CHECK(internal_prctl(PR_SET_VMA, PR_SET_VMA_ANON_NAME, addr, size,
(uptr)name) == 0);
internal_prctl(PR_SET_VMA, PR_SET_VMA_ANON_NAME, addr, size, (uptr)name);
}
#else
void DecorateMapping(uptr addr, uptr size, const char *name) {