Referencing a hashmap twice within another hashmap results in a "Circular reference found in HashMap" warning when attempting to save the game.
Description
Description
Details
Details
- Severity
- Minor
- Resolution
- Open
- Reproducibility
- Always
- Operating System
- Windows 10 x64
- Category
- Scripting
Steps To Reproduce
1.) Run code in debug console:
m = createHashMap; map = createHashMap; map set ["a", m]; map set ["b", m];
2.) Click save
3.) Check rpt for following output:
Circular reference found in HashMap, this will cause a memory leak! ➥ Context: Hash Key: "b" <- Serialize Game Variable: map
Additional Information
Similar to: https://feedback.bistudio.com/T162441
For more information: https://forums.bohemia.net/forums/topic/284948-circular-reference-in-hashmap/
Event Timeline
Comment Actions
Thats what I deserve for copy pasting code and then only fixing a bug in one of the two.
There is also a memory leak in there, on every save for every hashmap serialization.