Skip to content

Commit 3e4542e

Browse files
committedNov 26, 2014
[Msan] Check returning value of DTLS_Get()
Differential Revision: http://reviews.llvm.org/D6403 llvm-svn: 222818
1 parent 7ad0ddc commit 3e4542e

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed
 

‎compiler-rt/lib/msan/msan_thread.cc

+1
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ void MsanThread::ClearShadowForThreadStackAndTLS() {
3636
if (tls_begin_ != tls_end_)
3737
__msan_unpoison((void *)tls_begin_, tls_end_ - tls_begin_);
3838
DTLS *dtls = DTLS_Get();
39+
CHECK_NE(dtls, 0);
3940
for (uptr i = 0; i < dtls->dtv_size; ++i)
4041
__msan_unpoison((void *)(dtls->dtv[i].beg), dtls->dtv[i].size);
4142
}

0 commit comments

Comments
 (0)
Please sign in to comment.