output: correctly handle outputs without a test() impl
This fixes a crash when calling wlr_output_test() on a headless output. Closes: https://github.com/swaywm/sway/issues/6213
This commit is contained in:
parent
8e375ae340
commit
6622cd3277
|
@ -580,6 +580,9 @@ bool wlr_output_test(struct wlr_output *output) {
|
|||
if (!output_basic_test(output)) {
|
||||
return false;
|
||||
}
|
||||
if (!output->impl->test) {
|
||||
return true;
|
||||
}
|
||||
return output->impl->test(output);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue