diff options
author | Brad King <brad.king@kitware.com> | 2017-05-18 12:50:42 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2017-05-18 12:50:47 (GMT) |
commit | b86c5e8003aa27ad359ec60802d9ee218eccdf78 (patch) | |
tree | 149006e3293162c912714ba3fd76da2fb6da5989 /Source | |
parent | 23b3d46e96f88ff66bdd064e484c0ba9ffa10ebc (diff) | |
parent | 8d754ad5e74a3b0edf3f6cb9ea2db6abf5cfec74 (diff) | |
download | CMake-b86c5e8003aa27ad359ec60802d9ee218eccdf78.zip CMake-b86c5e8003aa27ad359ec60802d9ee218eccdf78.tar.gz CMake-b86c5e8003aa27ad359ec60802d9ee218eccdf78.tar.bz2 |
Merge topic 'fix-invalid-export-name'
8d754ad5 bindexplib: Skip symbols containing a dot (.)
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !855
Diffstat (limited to 'Source')
-rw-r--r-- | Source/bindexplib.cxx | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/Source/bindexplib.cxx b/Source/bindexplib.cxx index 691e3ae..cd1fb8a 100644 --- a/Source/bindexplib.cxx +++ b/Source/bindexplib.cxx @@ -251,13 +251,16 @@ public: SectChar = this->SectionHeaders[pSymbolTable->SectionNumber - 1] .Characteristics; - if (SectChar & IMAGE_SCN_MEM_EXECUTE) { - this->Symbols.insert(symbol); - } else if (SectChar & IMAGE_SCN_MEM_READ) { - // skip __real@ and __xmm@ - if (symbol.find("_real") == std::string::npos && - symbol.find("_xmm") == std::string::npos) { - this->DataSymbols.insert(symbol); + // skip symbols containing a dot + if (symbol.find('.') == std::string::npos) { + if (SectChar & IMAGE_SCN_MEM_EXECUTE) { + this->Symbols.insert(symbol); + } else if (SectChar & IMAGE_SCN_MEM_READ) { + // skip __real@ and __xmm@ + if (symbol.find("_real") == std::string::npos && + symbol.find("_xmm") == std::string::npos) { + this->DataSymbols.insert(symbol); + } } } } |