Skip to content

backends/drm: Fix accessing a dangling reference

Vlad Zahorodnii requested to merge work/cherry-pick-4f4f35e0 into Plasma/6.2

m_commits.front() is a reference to the first item in the m_commits list. If it's submitted sucessfully, everything will be alright.

If the candidate commit fails, it can be merged with other pending commits in the m_commits list. It will also invalidate any previously taken reference to the first item in the m_commits list, which is not okay for commit->test().

(cherry picked from commit 4f4f35e0)

Merge request reports

Loading