aboutsummaryrefslogtreecommitdiff
path: root/contrib/llvm/lib/Support/Windows/RWMutex.inc
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/llvm/lib/Support/Windows/RWMutex.inc')
-rw-r--r--contrib/llvm/lib/Support/Windows/RWMutex.inc4
1 files changed, 2 insertions, 2 deletions
diff --git a/contrib/llvm/lib/Support/Windows/RWMutex.inc b/contrib/llvm/lib/Support/Windows/RWMutex.inc
index ac60c2fc05be..5eb9351eee52 100644
--- a/contrib/llvm/lib/Support/Windows/RWMutex.inc
+++ b/contrib/llvm/lib/Support/Windows/RWMutex.inc
@@ -74,10 +74,10 @@ static bool loadSRW() {
sys::RWMutexImpl::RWMutexImpl() {
if (loadSRW()) {
- data_ = calloc(1, sizeof(SRWLOCK));
+ data_ = safe_calloc(1, sizeof(SRWLOCK));
fpInitializeSRWLock(static_cast<PSRWLOCK>(data_));
} else {
- data_ = calloc(1, sizeof(CRITICAL_SECTION));
+ data_ = safe_calloc(1, sizeof(CRITICAL_SECTION));
InitializeCriticalSection(static_cast<LPCRITICAL_SECTION>(data_));
}
}