Search Issue Tracker
Won't Fix
Won't Fix in 1.0.X
Votes
2
Found in [Package]
1.0.0
Issue ID
ECSB-197
Regression
No
Crash with multiple stack traces when using the EntityManager.CopyAndReplaceEntitiesFrom method
Reproduction steps:
1. Open the attached “repro-project“
2. Open the “Assets/Demos/2. Setup/2b. Motion Properties/2b1. Motion Properties - Mass.unity” scene
3. Enter Play Mode
4. Repeatedly press “X“
5. Observe the crash
Reproducible with: 1.0.0-pre.15 (2022.2.10f1, 2023.1.0b7, 2023.2.0a5)
Reproduced on: Windows 10 Pro
Notes:
1. If the crash does not reproduce repeat steps 3 and 4
2. Reproduction is inconsistent
3. Also reproduced in Player
First few lines of the stack traces:
{{0x00007FF949D68A2A (Unity) remove_free_block }}
{{0x00007FF949D68D3D (Unity) tlsf_free }}
{{0x00007FF9459B93FF (Unity) DynamicHeapAllocator::Deallocate }}
{{0x00007FF9459F2376 (Unity) DualThreadAllocator<DynamicHeapAllocator>::TryDeallocate}}
{{0x00007FF9459B9B68 (Unity) MemoryManager::Deallocate}}
{{0x00007ff7aacfaf6e (Unity) DynamicHeapAllocator::Deallocate }}
{{0x00007ff7aad07a32 (Unity) DelayedPointerDeletionManager::CleanupPendingMainThreadPointersInternal }}
{{0x00007ff7aad07164 (Unity) DualThreadAllocator<DynamicHeapAllocator>::Allocate }}
{{0x00007ff7aacfa0c1 (Unity) MemoryManager::Allocate }}
{{0x00007ff7aad0420e (Unity) malloc_internal}}
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Assets are created in the Package folders when creating assets via custom buttons in the Inspector window or other windows
- “Select” windows are named differently on Windows and macOS
- [Windows] No minimum “Select” window size
- Enabling “Editor Extension Authoring” in UI Builder doesn’t dirty the document and saving with shortcut doesn’t persist the state
- WebRequest.Create() function fails with "URI prefix is not recognized" errors when the project is built for Linux Standalone or Windows Dedicated Server
Resolution Note:
EntityManager.CopyAndReplaceEntitiesFrom is unfortunately making a series of assumptions that fundamentally prevent this function from ever working in the general case. And recent changes in the way entities are allocated made it even more difficult to use properly. So we have decided to deprecate this function. There is just no way it would ever deliver on what it was supposed to do.
Resolution Note (1.0.X):
EntityManager.CopyAndReplaceEntitiesFrom is unfortunately making a series of assumptions that fundamentally prevent this function from ever working in the general case. And recent changes in the way entities are allocated made it even more difficult to use properly. So we have decided to deprecate this function. There is just no way it would ever deliver on what it was supposed to do.