diff options
author | Etienne Bergeron <etienneb@google.com> | 2016-04-05 01:46:26 +0000 |
---|---|---|
committer | Etienne Bergeron <etienneb@google.com> | 2016-04-05 01:46:26 +0000 |
commit | 1562f69febe074859bf29703587e5cfac7d119fa (patch) | |
tree | 578b08d54ba160097e97af36f9bbac2e9fd86e6d | |
parent | 009ec085db1f1a6d1f17149cca0e67eefd63397c (diff) | |
download | bcm5719-llvm-1562f69febe074859bf29703587e5cfac7d119fa.tar.gz bcm5719-llvm-1562f69febe074859bf29703587e5cfac7d119fa.zip |
[Support] Fix an invalid character escaping in string literal (unittest).
Summary:
A character within a string literal is not escaped correctly.
In this case, there is no semantic change because the invalid character turn out to be NUL anyway.
note: "\0x12" is equivalent to {0, 'x', '1', '2'} and not { 12 }.
This issue was found by clang-tidy.
Reviewers: rnk
Subscribers: cfe-commits
Differential Revision: http://reviews.llvm.org/D18747
llvm-svn: 265376
-rw-r--r-- | llvm/unittests/Support/Path.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/unittests/Support/Path.cpp b/llvm/unittests/Support/Path.cpp index 1653ac028d2..20e08721375 100644 --- a/llvm/unittests/Support/Path.cpp +++ b/llvm/unittests/Support/Path.cpp @@ -725,7 +725,7 @@ const char coff_bigobj[] = "\x00\x00\xff\xff\x00\x02......" const char coff_import_library[] = "\x00\x00\xff\xff...."; const char elf_relocatable[] = { 0x7f, 'E', 'L', 'F', 1, 2, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1 }; -const char macho_universal_binary[] = "\xca\xfe\xba\xbe...\0x00"; +const char macho_universal_binary[] = "\xca\xfe\xba\xbe...\x00"; const char macho_object[] = "\xfe\xed\xfa\xce........\x00\x00\x00\x01............"; const char macho_executable[] = |