dissect: restore compat with clang

clang says:
  src/dissect/dissect.c:292:17: warning: label followed by a declaration is a C23 extension [-Wc23-extensions]

Another option would be to raise the C standard to C23. I think that'd
make sense, but it's better to do it separately.
This commit is contained in:
Zbigniew Jędrzejewski-Szmek
2026-03-22 16:52:22 +01:00
parent 34fba9e561
commit 08f7a4865e
+3 -3
View File
@@ -260,7 +260,7 @@ static int parse_argv(int argc, char *argv[]) {
arg_in_memory = true;
break;
OPTION_LONG("root-hash", "HASH", "Specify root hash for verity"):
OPTION_LONG("root-hash", "HASH", "Specify root hash for verity"): {}
OPTION_LONG("usr-hash", "HASH", "Same, but for the usr partition"): {
_cleanup_(iovec_done) struct iovec roothash = {};
@@ -286,7 +286,7 @@ static int parse_argv(int argc, char *argv[]) {
OPTION_LONG("root-hash-sig", "SIG",
"Specify signature of root hash for verity as DER-encoded PKCS7, "
"either as a path to a file or as an ASCII base64-encoded string "
"prefixed by 'base64:'"):
"prefixed by 'base64:'"): {}
OPTION_LONG("usr-hash-sig", "SIG", "Same, but for the usr partition"): {
const char *value;
_cleanup_(iovec_done) struct iovec sig = {};
@@ -410,7 +410,7 @@ static int parse_argv(int argc, char *argv[]) {
break;
/************************************ Commands ***************************************/
OPTION_GROUP("Commands"):
OPTION_GROUP("Commands"): {}
OPTION_COMMON_HELP:
return help();