layout: avoid nullptr deref (#11831)
OPENINGON can be a nullptr and that makes FLOATEDINTOTILED to nullptr deref and segfault.
This commit is contained in:
parent
8cce3b98ce
commit
5212099b9f
1 changed files with 1 additions and 1 deletions
|
|
@ -206,7 +206,7 @@ bool IHyprLayout::onWindowCreatedAutoGroup(PHLWINDOW pWindow) {
|
|||
const PHLWINDOW OPENINGON = g_pCompositor->m_lastWindow.lock() && g_pCompositor->m_lastWindow->m_workspace == pWindow->m_workspace ?
|
||||
g_pCompositor->m_lastWindow.lock() :
|
||||
(pWindow->m_workspace ? pWindow->m_workspace->getFirstWindow() : nullptr);
|
||||
const bool FLOATEDINTOTILED = pWindow->m_isFloating && !OPENINGON->m_isFloating;
|
||||
const bool FLOATEDINTOTILED = pWindow->m_isFloating && OPENINGON && !OPENINGON->m_isFloating;
|
||||
const bool SWALLOWING = pWindow->m_swallowed || pWindow->m_groupSwallowed;
|
||||
|
||||
if ((*PAUTOGROUP || SWALLOWING) // continue if auto_group is enabled or if dealing with window swallowing.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue