Search Issue Tracker

Fixed in 2019.4.X

Votes

3

Found in

2019.4.19f1

2019.4.32f1

Issue ID

1381342

Regression

Yes

NullReferenceException error is thrown when a Renderer added to a LOD Group is deleted

Terrain

-

How to reproduce:
1. Open attached project "lodRepro"
2. Open the scene "SampleScene" (Assets/Scenes/SampleScene.unity)
3. In the Hierarchy window, delete the GameObject "Cube (1)"
4. Select the GameObject "LOD Group"
5. Inspect the Console window (Window > General > Console)

Expected result: No errors are seen in the Console
Actual result: A NullReferenceException error is seen in the Console

Reproducible with: 2019.4.19f1, 2019.4.33f1
Not reproducible with: 2019.4.18f1, 2020.1.0a1, 2020.3.24f1, 2021.2.4f1, 2022.1.0a16

Error:
NullReferenceException: Object reference not set to an instance of an object
UnityEditor.SpeedTreeMaterialFixer+<EnumerateMeshRenderers>d__2.MoveNext () (at /Users/bokken/buildslave/unity/build/Editor/Mono/SpeedTreeMaterialFixer.cs:27)

  1. Resolution Note (fix version 2019.4):

    Fixed in: 2019.4.36f1

Comments (1)

  1. mikelortega

    Dec 16, 2021 16:33

    The problem is still present in LTS 2019.4.34f1

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.