Search Issue Tracker
Fixed
Fixed in 2020.3.48f1, 2021.3.23f1, 2022.2.14f1, 2023.1.0b9, 2023.2.0a6
Votes
0
Found in
2020.3.42f1
2021.3.14f1
2022.1.23f1
2022.2.0b15
2023.1.0a19
2023.2.0a1
Issue ID
UUM-20790
Regression
No
IL2CPP returns a pointer to the stack value which points to invalid memory when generating code
How to reproduce:
1. Open the attached project
2. Build and Run (File>Build And Run)
3. Observe the outputted “Assembly-CSharp.cpp“ file, in the “il2cppOutput” folder of the Build
Expected result: IL2CPP passes the pointer through without marshalling (or dynamically allocates the returned value)
Actual result: IL2CPP allocates a stack value of BadPInvokedStruct, un-marshals the return value from the native call, and returns a pointer to the stack value
Reproducible with: 2020.3.42f1, 2021.3.14f1, 2022.1.23f1, 2022.2.0b15, 2023.1.0a19
Reproduced on: macOS 12.5 (Intel)
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Buttons in the Overlay Menu in the Scene View are all gray even if they're activated when Game View is maximized and minimized
- NullReferenceException is thrown when baking Adaptive Probe Volume for a Terrain with Non-GI Contributing Tree Prototypes and multiple APV objects with different LayerMasks are present on the scene
- Hands are not recognized when using Hololens 2
- "OnTriggerExit2D" is called before "OnTriggerEnter2D" when object is destroyed immediately
- Editor crashes on PrepareSpriteTilingData when exiting Play mode
Add comment