Don't try to poke at the header on deinit if MPQueue is nullptr
This commit is contained in:
parent
890a66c0eb
commit
5ef35a4ccf
|
@ -303,10 +303,13 @@ void DeInit()
|
|||
if (MPQueue)
|
||||
{
|
||||
MPQueue->lock();
|
||||
MPQueueHeader* header = (MPQueueHeader*)MPQueue->data();
|
||||
header->ConnectedBitmask &= ~(1 << InstanceID);
|
||||
header->InstanceBitmask &= ~(1 << InstanceID);
|
||||
header->NumInstances--;
|
||||
if (MPQueue->data() != nullptr)
|
||||
{
|
||||
MPQueueHeader *header = (MPQueueHeader *) MPQueue->data();
|
||||
header->ConnectedBitmask &= ~(1 << InstanceID);
|
||||
header->InstanceBitmask &= ~(1 << InstanceID);
|
||||
header->NumInstances--;
|
||||
}
|
||||
MPQueue->unlock();
|
||||
|
||||
SemPoolDeinit();
|
||||
|
|
Loading…
Reference in New Issue