Fixed a segfault in ldc2 when compiling synchronized{} blocks.

This commit is contained in:
Robert Clipsham
2009-09-19 13:05:10 +01:00
parent d6a6b7c797
commit 70b2156010
2 changed files with 13 additions and 11 deletions

View File

@@ -874,11 +874,8 @@ const LLStructType* DtoMutexType()
opaque->refineAbstractTypeTo(pa.get());
pmutex = isaStruct(pa.get());
if (gIR->module != NULL)
{
gIR->mutexType = pmutex;
gIR->module->addTypeName("D_CRITICAL_SECTION", pmutex);
}
gIR->mutexType = pmutex;
gIR->module->addTypeName("D_CRITICAL_SECTION", pmutex);
return pmutex;
}