Closed muktihari closed 1 week ago
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 99.94%. Comparing base (
e6386e5
) to head (f148c37
).
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
Previously, d.fieldDescriptions was resliced on reset, resulting d.releaseTemporaryObjects to do nothing regarding that field so the pointers (if any) will be keep until next decoding process reaching the previous slice index then replacing the value.
In general, this should not be a problem since the values will be replaced anyway when we do decode again, and the pointer will eventually be released at some point or when the decoder is no longer used (garbage-collected), but it becomes nondeterministic, so let's fix it.
We can move the resetting of d.fieldDescriptions and d.developerDataIndexes to d.releaseTemporaryObjects instead of in d.reset, since these fields only changes during decoding messages.