[PATCH] [Sanitizer] Make CommonFlags immutable after initialization.

Alexey Samsonov vonosmas at gmail.com
Fri Dec 19 13:57:22 PST 2014


Hi kcc, eugenis, glider,

Protect CommonFlags singleton by adding const qualifier to
common_flags() accessor. The only ways to modify the flags are
SetCommonFlagsDefaults(), ParseCommonFlagsFromString() functions
and OVERRIDE_COMMON_FLAG macro, which are only supposed to be
called during initialization.

http://reviews.llvm.org/D6741

Files:
  lib/asan/asan_flags.cc
  lib/lsan/lsan_common.cc
  lib/msan/msan.cc
  lib/sanitizer_common/sanitizer_flags.h
  lib/tsan/dd/dd_rtl.cc
  lib/tsan/rtl/tsan_flags.cc
  lib/ubsan/ubsan_flags.cc

EMAIL PREFERENCES
  http://reviews.llvm.org/settings/panel/emailpreferences/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D6741.17517.patch
Type: text/x-patch
Size: 6548 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20141219/88b5bb55/attachment.bin>


More information about the llvm-commits mailing list