Reproduction steps:
1. Open the user's attached "AutoConnectBug.zip" project
2. Open the "AutoConnect_Unecessary_Garbage_Generation" Scene
3. Enter the Play mode
4. Open the Profiler window and enable the Deep Profile setting
5. Press the "Remove Terrain" button in the Scene view and stop the Play mode
6. Observe the Profiler window
Expected result: Memory is not allocated to TerrainUtility.AutoConnect()
Actual result: Memory is allocated to TerrainUtility.AutoConnect()
Reproducible with: 2019.4.36f1, 2020.3.30f1, 2021.2.14f1, 2022.1.0b10, 2022.2.0a7
Reproducible with: Windows
Not reproducible with: macOS