Hagai Cohen 50352e5862 config/actions: fix null derefs in pin dispatcher (#14914)
* hyprtester: add issue14134 regression test

D#14134 reports a pin dispatcher SEGV when a monitor hosting a
pinned floating window is disabled (e.g. lid close on a laptop).
After CMonitor::onDisconnect resets m_activeWorkspace to null,
the CMonitor SP stays alive in m_realMonitors, and the pinned-
window branch of moveWorkspaceToMonitor leaves the window's
m_monitor pointing at the disabled monitor.

The next pin dispatch does null deref inside Config::Actions::pinWindow.

* config/actions: fix null derefs in pin dispatcher

PR #14061 replaced moveToWorkspace(m_activeWorkspace) with
assignToSpace(m_activeWorkspace->m_space) and a separate
layoutTarget() call.

The two new derefs aren't covered by the existing PMONITOR check,
and either one being null crashes the compositor.

In practice, i use pyprland which uses pining function,
and since i am on laptop, sometimes my lid is closed and i have
monitor disabled, this causes null deref when computer goes idle.

    Layout::CWindowTarget::assignToSpace   <- segv
    Config::Actions::pinWindow
    pin
    CDispatcherTranslator::run
    CHyprCtl::getReply

In this fix i've added null checks to avoid crashing
2026-06-07 12:26:03 +02:00
2025-11-17 08:54:47 +02:00
2026-04-04 08:50:36 -04:00
2026-05-07 00:17:10 +01:00
2026-01-05 12:57:40 +01:00
2026-05-13 22:55:46 +00:00
2026-03-02 21:03:44 +02:00
2026-01-11 16:13:52 +01:00
2026-05-16 13:59:19 +01:00

banner

Badge Workflow Badge License Badge Language Badge Pull Requests Badge Issues Badge Hi Mom


Hyprland is a 100% independent, dynamic tiling Wayland compositor that doesn't sacrifice on its looks.

It provides the latest Wayland features, is highly customizable, has all the eyecandy, the most powerful plugins, easy IPC, much more QoL stuff than other compositors and more...


 
 Install 
 
   
 Quick Start 
 
   
 Configure 
 
   
 Contribute 
 



Features

  • All of the eyecandy: gradient borders, blur, animations, shadows and much more
  • A lot of customization
  • 100% independent, no wlroots, no libweston, no kwin, no mutter.
  • Custom bezier curves for the best animations
  • Powerful plugin support
  • Built-in plugin manager
  • Tearing support for better gaming performance
  • Easily expandable and readable codebase
  • Fast and active development
  • Not afraid to provide bleeding-edge features
  • Config reloaded instantly upon saving
  • Fully dynamic workspaces
  • Two built-in layouts and more available as plugins
  • Global keybinds passed to your apps of choice
  • Tiling/pseudotiling/floating/fullscreen windows
  • Special workspaces (scratchpads)
  • Window groups (tabbed mode)
  • Powerful window/monitor/layer rules
  • Socket-based IPC
  • Native IME and Input Panels Support
  • and much more...


Gallery


Preview A


Preview B


Preview C



Special Thanks


wlroots - For powering Hyprland in the past

tinywl - For showing how 2 do stuff

Sway - For showing how 2 do stuff the overkill way

Vivarium - For showing how 2 do stuff the simple way

dwl - For showing how 2 do stuff the hacky way

Wayfire - For showing how 2 do some graphics stuff

S
Description
Hyprland is an independent, highly customizable, dynamic tiling Wayland compositor that doesn't sacrifice on its looks.
Readme BSD-3-Clause
221 MiB
Languages
C++ 95.1%
GLSL 2%
Shell 0.8%
CMake 0.5%
Nix 0.5%
Other 1%