mirror of
https://github.com/labwc/labwc.git
synced 2026-04-12 08:21:13 -04:00
if-if to if-and
This commit is contained in:
parent
f9c1712890
commit
44d7b6e558
1 changed files with 4 additions and 5 deletions
|
|
@ -784,12 +784,11 @@ output_add_virtual(struct server *server, const char *output_name)
|
||||||
/* Prevent creating outputs with the same name */
|
/* Prevent creating outputs with the same name */
|
||||||
struct output *output;
|
struct output *output;
|
||||||
wl_list_for_each(output, &server->outputs, link) {
|
wl_list_for_each(output, &server->outputs, link) {
|
||||||
if (wlr_output_is_headless(output->wlr_output)) {
|
if (wlr_output_is_headless(output->wlr_output) &&
|
||||||
if (!strcmp(output->wlr_output->name, output_name)) {
|
!strcmp(output->wlr_output->name, output_name)) {
|
||||||
wlr_log(WLR_DEBUG,
|
wlr_log(WLR_DEBUG,
|
||||||
"refusing to create virtual output with duplicate name");
|
"refusing to create virtual output with duplicate name");
|
||||||
return;
|
return;
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
strncpy(server->headless.pending_output_name, output_name,
|
strncpy(server->headless.pending_output_name, output_name,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue