Skip to content

Commit

Permalink
Fix boolean assignment
Browse files Browse the repository at this point in the history
On --no-vd-system-decoration, the boolean option must be set to false.

It was wrongly assigned from optarg. This worked because optarg is NULL
at this point (so it was converted to false).
  • Loading branch information
rom1v committed Dec 5, 2024
1 parent baa10ed commit 5c4f8ed
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/src/cli.c
Original file line number Diff line number Diff line change
Expand Up @@ -2706,7 +2706,7 @@ parse_args_with_getopt(struct scrcpy_cli_args *args, int argc, char *argv[],
opts->angle = optarg;
break;
case OPT_NO_VD_SYSTEM_DECORATIONS:
opts->vd_system_decorations = optarg;
opts->vd_system_decorations = false;
break;
default:
// getopt prints the error message on stderr
Expand Down

0 comments on commit 5c4f8ed

Please sign in to comment.