[sanitizer] Fix test to tolerate chmod not working as intended
authorTeresa Johnson <tejohnson@google.com>
Sun, 13 Feb 2022 16:39:59 +0000 (08:39 -0800)
committerTeresa Johnson <tejohnson@google.com>
Sun, 13 Feb 2022 19:56:08 +0000 (11:56 -0800)
commit986afe847951a59cd66783e1377b13cec6412972
treed5dd09e8117686c4d8e8b1c83a7052ecbfb9a3d1
parent06df1a2eff841d20b1811b5acca7a200aa08b0fb
[sanitizer] Fix test to tolerate chmod not working as intended

Attempts to fix a bot failure from
634da7a1c61ee8c173e90a841eb1f4ea03caa20b on an Android bot:
https://lab.llvm.org/buildbot#builders/77/builds/14339

It appears that the chmod is not making the directory unwritable as
expected on this system for some reason. Adopt an approach used in
compiler-rt/test/fuzzer/fuzzer-dirs.test for systems with
non-functioning chmod by including illegal characters in directory.
compiler-rt/test/sanitizer_common/TestCases/Posix/sanitizer_set_report_path_test.cpp