mirror of
https://github.com/Relintai/pandemonium_engine.git
synced 2024-11-21 16:37:20 +01:00
Don't access a Message's memory after calling it's destructor in MessageQueue. (Even though the way the code works currently this was not really a bug, but it can easily become one.)
This commit is contained in:
parent
05f19a003b
commit
0bdb0ccac8
@ -438,12 +438,12 @@ MessageQueue::~MessageQueue() {
|
||||
}
|
||||
}
|
||||
|
||||
message->~Message();
|
||||
|
||||
read_pos += sizeof(Message);
|
||||
if ((message->type & FLAG_MASK) != TYPE_NOTIFICATION) {
|
||||
read_pos += sizeof(Variant) * message->args;
|
||||
}
|
||||
|
||||
message->~Message();
|
||||
}
|
||||
|
||||
} // for which
|
||||
|
Loading…
Reference in New Issue
Block a user