setlocale interceptor imitates a write into result,
which may be located in .rodata section.
This is the only interceptor that tries to do this and
I think the intention was to initialize the range for msan.
So do that instead. Writing into .rodata shouldn't happen
(without crashing later on the actual write) and this
traps on my local tsan experiments.
Details
Details
- Reviewers
vitalybuka - Commits
- rG23596fece043: sanitizer_common: don't write into .rodata
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Comment Actions
Can you make compiler-rt/test/sanitizer_common/TestCases/setlocale.cpp to fail without patch?
Comment Actions
It's not possible now. Currently tsan handles it and that's why we did not notice it earlier (it would crash on our internal codebase otherwise).
I noticed it only while making some significant changes to tsan runtime.