backends/drm: fix error in finding the best plane
This commit is contained in:
parent
e708f8a166
commit
9078d916c2
1 changed files with 1 additions and 1 deletions
|
@ -197,7 +197,7 @@ void DrmGpu::initDrmResources()
|
|||
const auto notconnected = std::find_if(list.begin(), list.end(), [](DrmPlane *plane) {
|
||||
return plane->getProp(DrmPlane::PropertyIndex::CrtcId)->pending() == 0;
|
||||
});
|
||||
if (notconnected == list.end()) {
|
||||
if (notconnected != list.end()) {
|
||||
return *notconnected;
|
||||
}
|
||||
return list.empty() ? nullptr : list.front();
|
||||
|
|
Loading…
Reference in a new issue