Skip to content

Commit

Permalink
Fix compilation error
Browse files Browse the repository at this point in the history
Fix the following warning/error:

    ../app/src/cli.c:2158:17: warning: a label can only be part of a
    statement and a declaration is not a statement [-Wpedantic]

With some compilers, this is an error rather than a pedantic warning.

Refs <#2256 (comment)>
  • Loading branch information
rom1v committed Nov 25, 2023
1 parent 5e06163 commit 4135c41
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion app/src/cli.c
Original file line number Diff line number Diff line change
Expand Up @@ -2154,14 +2154,15 @@ parse_args_with_getopt(struct scrcpy_cli_args *args, int argc, char *argv[],
return false;
}
break;
case OPT_ORIENTATION:
case OPT_ORIENTATION: {
enum sc_orientation orientation;
if (!parse_orientation(optarg, &orientation)) {
return false;
}
opts->display_orientation = orientation;
opts->record_orientation = orientation;
break;
}
case OPT_RENDER_DRIVER:
opts->render_driver = optarg;
break;
Expand Down

0 comments on commit 4135c41

Please sign in to comment.