diff options
author | Zachary Turner <zturner@google.com> | 2018-03-07 18:40:41 +0000 |
---|---|---|
committer | Zachary Turner <zturner@google.com> | 2018-03-07 18:40:41 +0000 |
commit | df85654ae817d97e6b3e344b8f478c712457b2c6 (patch) | |
tree | 55947f9a0acc39763e93c145795ce5be95be7531 /unittests/BinaryFormat | |
parent | 59e31a6588bd64f0493e704c7840288466855815 (diff) |
Teach identify_file_magic to identify PDB files.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@326924 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'unittests/BinaryFormat')
-rw-r--r-- | unittests/BinaryFormat/TestFileMagic.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/unittests/BinaryFormat/TestFileMagic.cpp b/unittests/BinaryFormat/TestFileMagic.cpp index ca4ca9a2728..5f132ba4144 100644 --- a/unittests/BinaryFormat/TestFileMagic.cpp +++ b/unittests/BinaryFormat/TestFileMagic.cpp @@ -81,6 +81,8 @@ const char windows_resource[] = const char macho_dynamically_linked_shared_lib_stub[] = "\xfe\xed\xfa\xce........\x00\x00\x00\x09............"; const char ms_dos_stub_broken[] = "\x4d\x5a\x20\x20"; +const char pdb[] = "Microsoft C/C++ MSF 7.00\r\n\x1a" + "DS\x00\x00\x00"; TEST_F(MagicTest, Magic) { struct type { @@ -110,6 +112,7 @@ TEST_F(MagicTest, Magic) { DEFINE(macho_dsym_companion), DEFINE(macho_kext_bundle), DEFINE(windows_resource), + DEFINE(pdb), {"ms_dos_stub_broken", ms_dos_stub_broken, sizeof(ms_dos_stub_broken), file_magic::unknown}, #undef DEFINE |