lerptag: Ensure we never return uninitialized data#1952
lerptag: Ensure we never return uninitialized data#1952DolceTriade merged 1 commit intoDaemonEngine:masterfrom
Conversation
If for any reason, we fail to find a tag for iqm/md5 code, if the
attachment is uninitialized like in the entity cache code, we will
return NaNs. Fixes this crash for me:
```
tuple=...) at /mnt/media/code/unv-master/daemon/src/common/Util.h:136
at /mnt/media/code/unv-master/daemon/src/common/Util.h:141
```
|
Maybe the fix for that issue? People report disconnections, and a VM crash would do that. |
|
Unlikely. I would expect to see a crash dump in that case. |
|
LGTM So does this look like a pre-existing bug that was triggered by the skeleton re-shuffling? Apparently this non-existent tag case always happens for the rifle, another gun that I forgot, and some buildables. I don't understand what's even supposed to happen when the tag is not found.
With a release build this should not cause any (immediate) halting, just a possible NaN propagating. Mod hosters could be building with asserts which should indeed cause a crash dump. |
If for any reason, we fail to find a tag for iqm/md5 code, if the attachment is uninitialized like in the entity cache code, we will return NaNs.
The md3 code path already did this, so pull it out of that path and do it globally so iqm/md5 code gets it too.
Fixes this crash for me: