]> git.ipfire.org Git - thirdparty/kmod.git/commit
testsuite: Fix build with gcc < 15 master
authorLucas De Marchi <lucas.de.marchi@gmail.com>
Fri, 11 Jul 2025 15:53:53 +0000 (10:53 -0500)
committerLucas De Marchi <lucas.de.marchi@gmail.com>
Mon, 14 Jul 2025 03:18:34 +0000 (22:18 -0500)
commit695fd084a727cf76f51b129b67d5a4be1d6db32e
tree3370a24ec7ffd3f5c9e70ad48e89c090673bef9c
parent5d845ab29ac2c335d3061eae050f5d8686b73980
testsuite: Fix build with gcc < 15

Variable declaration inside a switch case works with gcc 15, but fails
pretty much everywhere else with a message like below:

../testsuite/init_module.c: In function â€˜syscall’:
../testsuite/init_module.c:343:3: error: a label can only be part of a statement and a declaration is not a statement
  343 |   const char *args;
      |   ^~~~~

Add an empty statement to fix it.

Signed-off-by: Lucas De Marchi <lucas.de.marchi@gmail.com>
Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
Link: https://github.com/kmod-project/kmod/pull/390
testsuite/init_module.c