mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-04-29 16:25:42 +00:00
Ref Count Catch
With Permission from Jeff Faust.
// AFX CODE BLOCK (bug-fix) <<
// for events that are not GuaranteedOrdered we can get here w/o ever
// incrementing ref-count on the event.
This commit is contained in:
parent
84430a46a8
commit
dbf9275037
1 changed files with 2 additions and 0 deletions
|
|
@ -344,6 +344,8 @@ void NetConnection::eventReadPacket(BitStream *bstream)
|
||||||
if(unguaranteedPhase)
|
if(unguaranteedPhase)
|
||||||
{
|
{
|
||||||
evt->process(this);
|
evt->process(this);
|
||||||
|
if (evt->getRefCount() == 0)
|
||||||
|
evt->incRef();
|
||||||
evt->decRef();
|
evt->decRef();
|
||||||
if(mErrorBuffer.isNotEmpty())
|
if(mErrorBuffer.isNotEmpty())
|
||||||
return;
|
return;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue