summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndroid Build Coastguard Worker <android-build-coastguard-worker@google.com>2021-11-12 15:43:53 +0000
committerAndroid Build Coastguard Worker <android-build-coastguard-worker@google.com>2021-11-12 15:43:53 +0000
commit840ade38f9c69c14fe497903ad8ced77d75bb93f (patch)
tree0d26f928e69c023cdd3b312fd3799c05764556cf
parent16a9e0ac0d9b9c7b7299a03d4f1e69eef8be5418 (diff)
parentc4bdc1cced75eea0c93e362b654d975b4b9c3279 (diff)
downloadscudo-android12-mainline-neuralnetworks-release.tar.gz
Snap for 7910331 from c4bdc1cced75eea0c93e362b654d975b4b9c3279 to mainline-neuralnetworks-releaseandroid-mainline-12.0.0_r92android-mainline-12.0.0_r78android-mainline-12.0.0_r50android12-mainline-neuralnetworks-release
Change-Id: Iaf41a5b9fb1bed740a3a90034db843a8fdec3cdb
-rw-r--r--standalone/include/scudo/interface.h16
1 files changed, 9 insertions, 7 deletions
diff --git a/standalone/include/scudo/interface.h b/standalone/include/scudo/interface.h
index 0e6cf3d4e25..9b9a84623c5 100644
--- a/standalone/include/scudo/interface.h
+++ b/standalone/include/scudo/interface.h
@@ -120,7 +120,7 @@ size_t __scudo_get_ring_buffer_size();
// Tune the allocator's choice of memory tags to make it more likely that
// a certain class of memory errors will be detected. The value argument should
-// be one of the enumerators of the scudo_memtag_tuning enum below.
+// be one of the M_MEMTAG_TUNING_* constants below.
#ifndef M_MEMTAG_TUNING
#define M_MEMTAG_TUNING -102
#endif
@@ -145,13 +145,15 @@ size_t __scudo_get_ring_buffer_size();
#define M_TSDS_COUNT_MAX -202
#endif
-enum scudo_memtag_tuning {
- // Tune for buffer overflows.
- M_MEMTAG_TUNING_BUFFER_OVERFLOW,
+// Tune for buffer overflows.
+#ifndef M_MEMTAG_TUNING_BUFFER_OVERFLOW
+#define M_MEMTAG_TUNING_BUFFER_OVERFLOW 0
+#endif
- // Tune for use-after-free.
- M_MEMTAG_TUNING_UAF,
-};
+// Tune for use-after-free.
+#ifndef M_MEMTAG_TUNING_UAF
+#define M_MEMTAG_TUNING_UAF 1
+#endif
} // extern "C"