diff options
| author | Vaxry <vaxry@vaxry.net> | 2024-02-07 00:18:47 +0000 |
|---|---|---|
| committer | Vaxry <vaxry@vaxry.net> | 2024-02-07 00:18:47 +0000 |
| commit | f085ed4454fc0c9045b324c32f9ca34cd4c28808 (patch) | |
| tree | e300a7a0ba532c5f44e00330e2e135b14890316e /src/Compositor.cpp | |
| parent | ded174d6e5d14bc376919194cbc52c238a07f640 (diff) | |
screencopy/toplevelexport: sanitize pointers in ::copyFrame
oopsie~~ >///<
Diffstat (limited to 'src/Compositor.cpp')
| -rw-r--r-- | src/Compositor.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/Compositor.cpp b/src/Compositor.cpp index 422dfa22..69812482 100644 --- a/src/Compositor.cpp +++ b/src/Compositor.cpp @@ -688,6 +688,15 @@ bool CCompositor::windowExists(CWindow* pWindow) { return false; } +bool CCompositor::monitorExists(CMonitor* pMonitor) { + for (auto& m : m_vRealMonitors) { + if (m.get() == pMonitor) + return true; + } + + return false; +} + CWindow* CCompositor::vectorToWindowUnified(const Vector2D& pos, uint8_t properties, CWindow* pIgnoreWindow) { const auto PMONITOR = getMonitorFromVector(pos); static auto* const PRESIZEONBORDER = &g_pConfigManager->getConfigValuePtr("general:resize_on_border")->intValue; |
