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
- UI Toolkit Slider value defaults to min value when the initial value is set in the UXML file
- The Player hangs when unloading a scene using the UnloadUnusedAssets() method
- [iOS] Too many texture parameters error is thrown when running on devices that support the number of parameters
- [MacOS] Trying to pick a Colour from full-screen window breaks Colour Picker Tool functionality
- WebGL Player hangs on first frame when "Autoconnect Profiler" is enabled and large amount of Profiler data is buffered before the first frame
Add comment