diff options
| author | Kostya Serebryany <kcc@google.com> | 2011-12-15 22:57:32 +0000 |
|---|---|---|
| committer | Kostya Serebryany <kcc@google.com> | 2011-12-15 22:57:32 +0000 |
| commit | 7ce9686921f20398cd2d9f55ebf8b7ab51cf5989 (patch) | |
| tree | 38edfbda6bd7c0808a379b886fa4aadfbd842a49 | |
| parent | c9bf1b1bffb11a02fbebc363932ff60614e0316d (diff) | |
| download | bcm5719-llvm-7ce9686921f20398cd2d9f55ebf8b7ab51cf5989.tar.gz bcm5719-llvm-7ce9686921f20398cd2d9f55ebf8b7ab51cf5989.zip | |
[asan] added a test to check that a global-buffer-overflow mentioned the module name; revert incorrect change in the test runner
llvm-svn: 146701
| -rw-r--r-- | compiler-rt/lib/asan/tests/asan_test.cc | 7 | ||||
| -rwxr-xr-x | compiler-rt/lib/asan/tests/test_output.sh | 4 |
2 files changed, 9 insertions, 2 deletions
diff --git a/compiler-rt/lib/asan/tests/asan_test.cc b/compiler-rt/lib/asan/tests/asan_test.cc index c302b8317cf..b1ac647c1ab 100644 --- a/compiler-rt/lib/asan/tests/asan_test.cc +++ b/compiler-rt/lib/asan/tests/asan_test.cc @@ -1577,6 +1577,13 @@ TEST(AddressSanitizer, GlobalStringConstTest) { EXPECT_DEATH(Ident(p[15]), "is ascii string 'FOOBAR123'"); } +TEST(AddressSanitizer, FileNameInGlobalReportTest) { + static char zoo[10]; + const char *p = Ident(zoo); + // The file name should be present in the report. + EXPECT_DEATH(Ident(p[15]), "zoo.*asan_test.cc"); +} + int *ReturnsPointerToALocalObject() { int a = 0; return Ident(&a); diff --git a/compiler-rt/lib/asan/tests/test_output.sh b/compiler-rt/lib/asan/tests/test_output.sh index 433d94fb89f..75e0c5ed29b 100755 --- a/compiler-rt/lib/asan/tests/test_output.sh +++ b/compiler-rt/lib/asan/tests/test_output.sh @@ -38,8 +38,8 @@ for t in *.tmpl; do actual_t="$t" fi ./$exe 2>&1 | $SYMBOLIZER 2> /dev/null | c++filt | ./match_output.py $actual_t - #rm ./$exe - #[ -e "$so" ] && rm ./$so + rm ./$exe + [ -e "$so" ] && rm ./$so done done done |

