Skip to content

Fix null reference in the Undo callback of the graphics compositor #2210

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Oct 14, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions com.unity.render-pipelines.high-definition/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,8 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
- Fixed the denoising and multi-sample not being used for smooth multibounce RTReflections.
- Fixed issue where multiple cameras would cause GC each frame.
- Fixed after post process rendering pass options not showing for unlit ShaderGraphs.
- Fixed a migration issue with the rendering queue in ShaderGraph when upgrading to 10.x;
- Fixed null reference in the Undo callback of the graphics compositor

### Changed
- Preparation pass for RTSSShadows to be supported by render graph.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -206,6 +206,8 @@ void UndoCallback()
s_SelectionIndex = m_Editor.selectionIndex;

CompositionManager compositor = CompositionManager.GetInstance();
// The compositor might be null even if the CompositionManagerEditor is not (in case the user switches from a scene with a compositor to a scene without one)
if (compositor)
{
// Some properties were changed, mark the profile as dirty so it can be saved if the user saves the scene
EditorUtility.SetDirty(compositor);
Expand Down