summaryrefslogtreecommitdiff
path: root/src/Window.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/Window.cpp')
-rw-r--r--src/Window.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/Window.cpp b/src/Window.cpp
index 77960dc6..2f0809bf 100644
--- a/src/Window.cpp
+++ b/src/Window.cpp
@@ -223,6 +223,9 @@ pid_t CWindow::getPID() {
wl_client_get_credentials(wl_resource_get_client(m_uSurface.xdg->resource), &PID, nullptr, nullptr);
} else {
+ if (!m_bIsMapped || !m_bMappedX11)
+ return -1;
+
PID = m_uSurface.xwayland->pid;
}