I noticed that when a symbol is named just "x", it gets demangled to "long long". On POSIX, AFAIK, mangled names always start with "_Z", so lets just require that.
Details
Diff Detail
Event Timeline
lib/sanitizer_common/sanitizer_symbolizer_posix_libcdep.cc | ||
---|---|---|
51 | Please make sure name[1] is addressable (BTW do we always know name is not NULL?) |
lib/sanitizer_common/sanitizer_symbolizer_posix_libcdep.cc | ||
---|---|---|
51 | Assuming that name is NULL, this check is OK. If the string of zero length we will bail out after checking name[0] (which is addressable and contains 0) |
LGTM
lib/sanitizer_common/sanitizer_symbolizer_posix_libcdep.cc | ||
---|---|---|
51 | s/NULL/not NULL agreed |
Reverted in r253129. There were ARM bot failures: http://lab.llvm.org:8011/builders/clang-cmake-armv7-a15-full/builds/9068
I guess the (de)mangling rules are different there?
That's quite strange, I thought name mangling rules depend on the
language/compiler, not the architecture.
By the way, I think we must not demangle names starting with double underscores.
Please make sure name[1] is addressable (BTW do we always know name is not NULL?)