diff options
author | Vaxry <[email protected]> | 2024-01-28 00:41:54 +0000 |
---|---|---|
committer | Vaxry <[email protected]> | 2024-01-28 00:41:54 +0000 |
commit | 9002657bcca1d4f69e2ebd0447d4129fdb950245 (patch) | |
tree | a653c9db6a0b08d9c292ecd065acdac0a980f1a0 | |
parent | 3e93fdf7794416272430300426a62497d9d0b835 (diff) | |
download | Hyprland-9002657bcca1d4f69e2ebd0447d4129fdb950245.tar.gz Hyprland-9002657bcca1d4f69e2ebd0447d4129fdb950245.zip |
monitor: don't call output_state_finish on buffer-less state clears
ref #4546
-rw-r--r-- | src/helpers/Monitor.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/helpers/Monitor.cpp b/src/helpers/Monitor.cpp index 6dfd0a65..11f37704 100644 --- a/src/helpers/Monitor.cpp +++ b/src/helpers/Monitor.cpp @@ -684,7 +684,11 @@ void CMonitor::updateMatrix() { } void CMonitor::clearState() { - wlr_output_state_finish(&outputState); + if (outputState.buffer) + wlr_output_state_finish(&outputState); + else // free(gamma_lut) should be unnecessary as it shouldn't be non-null for buffer-less commits? + pixman_region32_fini(&outputState.damage); + outputState = {0}; wlr_output_state_init(&outputState); } |