Search Issue Tracker
By Design
Votes
0
Found in
2019.4
2020.1
2020.1.16f1
2020.2
2021.1
Issue ID
1297689
Regression
No
Editor GUI Labels change with creation of GUIContent in AssetImporterEditor
How to reproduce:
1. Download and open project 'GUICorruption.zip'
2. Select Asset 'Assets/SelectThisAndRecompile.asset'
3. Enter Play Mode
4. Observe Editor
Expected result: No changes in the Editor
Actual result: Most of Editor UI Labels are changed
Reproducible with: 2019.4.16f1, 2020.1.16f1, 2020.2.0b14, 2021.1.0a9
Couldn't test with: 2018.4.28f1 (No Namespace AssetImporters)
Notes: In CustomLevelImporterEditor.cs not initializing testlabel (changing "private GUIContent testlabel = GUIContent.none" -> "private GUIContent testlabel") and setting it's value later doesn't produce the issue
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
- “Remove Unused Overrides” available on not loaded Scene and throws “ArgumentException: The scene is not loaded” warning
- Adaptive Probe Volume occlusion edge is calculated incorrectly when viewing probes near geometry edges
- Sampling a texture using an HLSL file throws shader errors and the code does not compile
- "Graphics.CopyTexture called with null source texture" error when Base Camera of an Overlay Camera is removed with DX11 Graphics API and Compatibility Mode enabled
- WebGL sends wrong value with large numbers when SendMessage function is used
Resolution Note:
The issue is due to assigning the reference pointer of none to the users variable and when assigning the new it overwrites the pointer. Because GUIContent is a reference type (class) it will be assigned based on a reference, not sure we can break that pattern.