mirror of
https://github.com/SELinuxProject/selinux
synced 2024-12-11 16:44:59 +00:00
9d85aa60d1
On Ubuntu 20.04, when building with clang -Werror -Wextra-semi-stmt
(which is not the default build configuration), the compiler reports:
../cil/src/cil_binary.c:4293:22: error: empty expression statement
has no effect; remove unnecessary ';' to silence this warning
[-Werror,-Wextra-semi-stmt]
mix(k->target_class);
^
../cil/src/cil_binary.c:4294:21: error: empty expression statement
has no effect; remove unnecessary ';' to silence this warning
[-Werror,-Wextra-semi-stmt]
mix(k->target_type);
^
../cil/src/cil_binary.c:4295:21: error: empty expression statement
has no effect; remove unnecessary ';' to silence this warning
[-Werror,-Wextra-semi-stmt]
mix(k->source_type);
^
../cil/src/cil_binary.c:4296:19: error: empty expression statement
has no effect; remove unnecessary ';' to silence this warning
[-Werror,-Wextra-semi-stmt]
mix(k->specified);
^
Use a do { ... } while (0) construction to silence this warning.
Moreover the same warning appears when using two semicolons to end a
statement. Remove such occurrences, like what was already done in commit
|
||
---|---|---|
.. | ||
policies | ||
.gitignore | ||
debug.c | ||
debug.h | ||
helpers.c | ||
helpers.h | ||
libsepol-tests.c | ||
Makefile | ||
test-common.c | ||
test-common.h | ||
test-cond.c | ||
test-cond.h | ||
test-deps.c | ||
test-deps.h | ||
test-downgrade.c | ||
test-downgrade.h | ||
test-expander-attr-map.c | ||
test-expander-attr-map.h | ||
test-expander-roles.c | ||
test-expander-roles.h | ||
test-expander-users.c | ||
test-expander-users.h | ||
test-expander.c | ||
test-expander.h | ||
test-linker-cond-map.c | ||
test-linker-cond-map.h | ||
test-linker-roles.c | ||
test-linker-roles.h | ||
test-linker-types.c | ||
test-linker-types.h | ||
test-linker.c | ||
test-linker.h |