summaryrefslogtreecommitdiffstats
path: root/compiler-rt/test/msan
diff options
context:
space:
mode:
authorEvgeniy Stepanov <eugeni.stepanov@gmail.com>2014-05-13 08:36:31 +0000
committerEvgeniy Stepanov <eugeni.stepanov@gmail.com>2014-05-13 08:36:31 +0000
commit5680a26b0b3751532709e3f75003935e4c7716a4 (patch)
tree3a365a8219f6221d90ba3f6d0f1aa45ac4598d75 /compiler-rt/test/msan
parentb359051d9e4ce8a4436e46c7d3321496b9515e65 (diff)
downloadbcm5719-llvm-5680a26b0b3751532709e3f75003935e4c7716a4.tar.gz
bcm5719-llvm-5680a26b0b3751532709e3f75003935e4c7716a4.zip
[msan] Better open_memstream support.
Move fflush and fclose interceptors to sanitizer_common. Use a metadata map to keep information about the external locations that must be updated when the file is written to. llvm-svn: 208676
Diffstat (limited to 'compiler-rt/test/msan')
-rw-r--r--compiler-rt/test/msan/open_memstream.cc18
1 files changed, 0 insertions, 18 deletions
diff --git a/compiler-rt/test/msan/open_memstream.cc b/compiler-rt/test/msan/open_memstream.cc
deleted file mode 100644
index e2b914b0f2e..00000000000
--- a/compiler-rt/test/msan/open_memstream.cc
+++ /dev/null
@@ -1,18 +0,0 @@
-// RUN: %clangxx_msan -m64 -O0 -g -xc++ %s -o %t && %run %t
-// RUN: %clangxx_msan -m64 -O3 -g -xc++ %s -o %t && %run %t
-
-#include <stdio.h>
-#include <stdlib.h>
-
-int main(void) {
- char *buf;
- size_t buf_len = 42;
- FILE *fp = open_memstream(&buf, &buf_len);
- fprintf(fp, "hello");
- fflush(fp);
- printf("buf_len = %zu\n", buf_len);
- for (int j = 0; j < buf_len; j++) {
- printf("buf[%d] = %c\n", j, buf[j]);
- }
- return 0;
-}
OpenPOWER on IntegriCloud