diff options
| author | Furkan Sahin <furkan-dev@proton.me> | 2025-08-22 15:37:44 +0200 |
|---|---|---|
| committer | Furkan Sahin <furkan-dev@proton.me> | 2025-08-22 15:37:44 +0200 |
| commit | 002eb76d7ece84482f472ce0568669bb2fd7a77a (patch) | |
| tree | 7300c9ca39588aa490d19e28d2cba89d7fd80981 | |
| parent | 0343901425e282da0e7e4e894f3481b8620ef88c (diff) | |
config/output: Only error when enabling HDR
We currently emit errors about HDR support even if HDR is not being
requested, which mean errors on every regular modeset when monitors not
supporting HDR are connected.
Only emit errors when attempting to enable HDR on such device.
| -rw-r--r-- | sway/config/output.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sway/config/output.c b/sway/config/output.c index 2e3c05db..ed8147b8 100644 --- a/sway/config/output.c +++ b/sway/config/output.c @@ -365,7 +365,7 @@ bool output_supports_hdr(struct wlr_output *output, const char **unsupported_rea static void set_hdr(struct wlr_output *output, struct wlr_output_state *pending, bool enabled) { const char *unsupported_reason = NULL; - if (!output_supports_hdr(output, &unsupported_reason)) { + if (enabled && !output_supports_hdr(output, &unsupported_reason)) { sway_log(SWAY_ERROR, "Cannot enable HDR on output %s: %s", output->name, unsupported_reason); enabled = false; |
