Search Issue Tracker
Not Reproducible
Votes
0
Found in
2017.1.0b2
Issue ID
902189
Regression
Yes
"NullReferenceException: Object reference not set to an instance of an object" when exiting Play on OSX only
"NullReferenceException: Object reference not set to an instance of an object" when exiting Play on OSX only.
Happening only on OSX, both OpenGL 4.1 and Metal.
1. Open attached project (there should only be a single script file inside)
2. Window -> ProgressbarTest (this will open a new window)
3. Enter and exit Play mode a few times
Expected: No errors in console
Observed: NullReferenceException: Object reference not set to an instance of an object
Occurring on: 2017.1.0b1 onwards
Not occurring: 2017.1.0a6 and older, 5.6.0f3s2, 5.5.3f1
NullReferenceException: Object reference not set to an instance of an object
UnityEngine.GUILayoutUtility.LayoutFromContainer (Single w, Single h) (at /Users/weswong/Work/trunk/unity/Runtime/IMGUI/Managed/GUILayoutUtility.cs:182)
UnityEngine.Experimental.UIElements.UIElementsUtility.EndContainerGUI () (at /Users/weswong/Work/trunk/unity/Runtime/UIElements/Managed/UIElementsUtility.cs:173)
UnityEngine.Experimental.UIElements.IMGUIContainer.DoOnGUI (UnityEngine.Event evt) (at /Users/weswong/Work/trunk/unity/Runtime/UIElements/Managed/IMGUIContainer.cs:110)
UnityEngine.Experimental.UIElements.IMGUIContainer.HandleEvent (UnityEngine.Event evt, UnityEngine.Experimental.UIElements.VisualElement finalTarget) (at /Users/weswong/Work/trunk/unity/Runtime/UIElements/Managed/IMGUIContainer.cs:137)
UnityEngine.Experimental.UIElements.IMGUIContainer.DoRepaint (IStylePainter painter) (at /Users/weswong/Work/trunk/unity/Runtime/UIElements/Managed/IMGUIContainer.cs:36)
UnityEngine.Experimental.UIElements.Panel.PaintSubTree (UnityEngine.Event e, UnityEngine.Experimental.UIElements.VisualElement root, Matrix4x4 offset, Rect currentClip, Matrix4x4 clipTransform, Rect currentGlobalClip) (at /Users/weswong/Work/trunk/unity/Runtime/UIElements/Managed/Panel.cs:397)
UnityEngine.Experimental.UIElements.Panel.PaintSubTree (UnityEngine.Event e, UnityEngine.Experimental.UIElements.VisualElement root, Matrix4x4 offset, Rect currentClip, Matrix4x4 clipTransform, Rect currentGlobalClip) (at /Users/weswong/Work/trunk/unity/Runtime/UIElements/Managed/Panel.cs:405)
UnityEngine.Experimental.UIElements.Panel.Repaint (UnityEngine.Event e) (at /Users/weswong/Work/trunk/unity/Runtime/UIElements/Managed/Panel.cs:419)
UnityEngine.Experimental.UIElements.UIElementsUtility.DoDispatch (IVisualElementPanel panel) (at /Users/weswong/Work/trunk/unity/Runtime/UIElements/Managed/UIElementsUtility.cs:203)
UnityEngine.Experimental.UIElements.UIElementsUtility.ProcessEvent (Int32 instanceID, IntPtr nativeEventPtr) (at /Users/weswong/Work/trunk/unity/Runtime/UIElements/Managed/UIElementsUtility.cs:67)
UnityEngine.GUIUtility.ProcessEvent (Int32 instanceID, IntPtr nativeEventPtr) (at /Users/weswong/Work/trunk/unity/Runtime/IMGUI/Managed/GUIUtility.cs:186)
Comments (1)
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
- Mono Windows Builds don't produce full log callstacks when generating logs
- AssetBundles fail to load when running in Built Players for Mobile Devices
- UI elements with text gets bigger and grey when Player window is moved to another screen with different resolution
- System name accepts multiline text but crops it on confirmation, duplicates input, and shrinks the field when empty
- UI element scale and position are wrong in project build when DRS is changed with HDR and Software Dynamic Resolution enabled
Ragtop_59
Nov 23, 2017 20:40
Same issue for me on OSX
NullReferenceException: Object reference not set to an instance of an object
UnityEngine.GUILayoutUtility.LayoutFromContainer (Single w, Single h) (at /Users/builduser/buildslave/unity/build/Runtime/IMGUI/Managed/GUILayoutUtility.cs:182)
UnityEngine.Experimental.UIElements.UIElementsUtility.EndContainerGUI () (at /Users/builduser/buildslave/unity/build/Runtime/UIElements/Managed/UIElementsUtility.cs:139)
UnityEngine.Experimental.UIElements.IMGUIContainer.DoOnGUI (UnityEngine.Event evt) (at /Users/builduser/buildslave/unity/build/Runtime/UIElements/Managed/IMGUIContainer.cs:152)
UnityEngine.Experimental.UIElements.IMGUIContainer.HandleEvent (UnityEngine.Experimental.UIElements.EventBase evt) (at /Users/builduser/buildslave/unity/build/Runtime/UIElements/Managed/IMGUIContainer.cs:210)
UnityEngine.Experimental.UIElements.IMGUIContainer.DoRepaint (IStylePainter painter) (at /Users/builduser/buildslave/unity/build/Runtime/UIElements/Managed/IMGUIContainer.cs:50)
UnityEngine.Experimental.UIElements.Panel.PaintSubTree (UnityEngine.Event e, UnityEngine.Experimental.UIElements.VisualElement root, Matrix4x4 offset, Rect currentGlobalClip) (at /Users/builduser/buildslave/unity/build/Runtime/UIElements/Managed/Panel.cs:447)
UnityEngine.Experimental.UIElements.Panel.PaintSubTree (UnityEngine.Event e, UnityEngine.Experimental.UIElements.VisualElement root, Matrix4x4 offset, Rect currentGlobalClip) (at /Users/builduser/buildslave/unity/build/Runtime/UIElements/Managed/Panel.cs:457)
UnityEngine.Experimental.UIElements.Panel.Repaint (UnityEngine.Event e) (at /Users/builduser/buildslave/unity/build/Runtime/UIElements/Managed/Panel.cs:474)
UnityEngine.Experimental.UIElements.UIElementsUtility.DoDispatch (UnityEngine.Experimental.UIElements.BaseVisualElementPanel panel) (at /Users/builduser/buildslave/unity/build/Runtime/UIElements/Managed/UIElementsUtility.cs:192)
UnityEngine.Experimental.UIElements.UIElementsUtility.ProcessEvent (Int32 instanceID, IntPtr nativeEventPtr) (at /Users/builduser/buildslave/unity/build/Runtime/UIElements/Managed/UIElementsUtility.cs:72)
UnityEngine.GUIUtility.ProcessEvent (Int32 instanceID, IntPtr nativeEventPtr) (at /Users/builduser/buildslave/unity/build/Runtime/IMGUI/Managed/GUIUtility.cs:175)