Don't bother checking canRead() before calling getMagicNumber();
[oota-llvm.git] / lib / System / Win32 / ThreadLocal.inc
index 8ab37d9d75e06718cfe343f4b1bc54a0b94520d4..c8f7840b00387f894e93d772fd5463d244fafafe 100644 (file)
@@ -43,7 +43,7 @@ const void* ThreadLocalImpl::getInstance() {
 void ThreadLocalImpl::setInstance(const void* d){
   DWORD* tls = static_cast<DWORD*>(data);
   int errorcode = TlsSetValue(*tls, const_cast<void*>(d));
-  assert(errorcode == 0);
+  assert(errorcode != 0);
 }
 
 }