sanitizer_common: avoid compiler-interted memset in deadlock detector

Compilers tends to insert memset/memcpy for some struct/array operations,
and these don't play well inside of sanitizer runtimes.
Avoiding these calls was the intention behind internal_memset.
Remove the leftover ={} that can result in memset call.

Reviewed By: vitalybuka, pgousseau

Differential Revision: https://reviews.llvm.org/D106978
This commit is contained in:
Dmitry Vyukov 2021-07-28 19:58:52 +02:00
parent 9dad34423b
commit 170a8c1284
1 changed files with 1 additions and 1 deletions

View File

@ -73,7 +73,7 @@ void DebugMutexInit() {
// Build adjacency matrix.
bool leaf[kMutexTypeMax];
internal_memset(&leaf, 0, sizeof(leaf));
int cnt[kMutexTypeMax] = {};
int cnt[kMutexTypeMax];
internal_memset(&cnt, 0, sizeof(cnt));
for (int t = 0; t < kMutexTypeMax; t++) {
mutex_type_count = t;