From: Lucas De Marchi Date: Sat, 7 Sep 2024 00:15:04 +0000 (+0100) Subject: Drop empty statements X-Git-Tag: v34~404 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=73ffc00a048665d8b30585639ff28e8742ba49ba;p=thirdparty%2Fkmod.git Drop empty statements The double ';;' were clearly a mistake and clang-format only makes it worse if we try running it. Remove the mistake before mass-converting the source code. Signed-off-by: Lucas De Marchi Link: https://github.com/kmod-project/kmod/pull/114 --- diff --git a/libkmod/libkmod-config.c b/libkmod/libkmod-config.c index 6b137a51..343183f3 100644 --- a/libkmod/libkmod-config.c +++ b/libkmod/libkmod-config.c @@ -1221,7 +1221,7 @@ static struct kmod_config_iter *kmod_config_iter_new(const struct kmod_ctx* ctx, KMOD_EXPORT struct kmod_config_iter *kmod_config_get_blacklists(const struct kmod_ctx *ctx) { if (ctx == NULL) - return NULL;; + return NULL; return kmod_config_iter_new(ctx, CONFIG_TYPE_BLACKLIST); } @@ -1229,7 +1229,7 @@ KMOD_EXPORT struct kmod_config_iter *kmod_config_get_blacklists(const struct kmo KMOD_EXPORT struct kmod_config_iter *kmod_config_get_install_commands(const struct kmod_ctx *ctx) { if (ctx == NULL) - return NULL;; + return NULL; return kmod_config_iter_new(ctx, CONFIG_TYPE_INSTALL); } @@ -1237,7 +1237,7 @@ KMOD_EXPORT struct kmod_config_iter *kmod_config_get_install_commands(const stru KMOD_EXPORT struct kmod_config_iter *kmod_config_get_remove_commands(const struct kmod_ctx *ctx) { if (ctx == NULL) - return NULL;; + return NULL; return kmod_config_iter_new(ctx, CONFIG_TYPE_REMOVE); } @@ -1245,7 +1245,7 @@ KMOD_EXPORT struct kmod_config_iter *kmod_config_get_remove_commands(const struc KMOD_EXPORT struct kmod_config_iter *kmod_config_get_aliases(const struct kmod_ctx *ctx) { if (ctx == NULL) - return NULL;; + return NULL; return kmod_config_iter_new(ctx, CONFIG_TYPE_ALIAS); } @@ -1253,7 +1253,7 @@ KMOD_EXPORT struct kmod_config_iter *kmod_config_get_aliases(const struct kmod_c KMOD_EXPORT struct kmod_config_iter *kmod_config_get_options(const struct kmod_ctx *ctx) { if (ctx == NULL) - return NULL;; + return NULL; return kmod_config_iter_new(ctx, CONFIG_TYPE_OPTION); } @@ -1261,7 +1261,7 @@ KMOD_EXPORT struct kmod_config_iter *kmod_config_get_options(const struct kmod_c KMOD_EXPORT struct kmod_config_iter *kmod_config_get_softdeps(const struct kmod_ctx *ctx) { if (ctx == NULL) - return NULL;; + return NULL; return kmod_config_iter_new(ctx, CONFIG_TYPE_SOFTDEP); } @@ -1269,7 +1269,7 @@ KMOD_EXPORT struct kmod_config_iter *kmod_config_get_softdeps(const struct kmod_ KMOD_EXPORT struct kmod_config_iter *kmod_config_get_weakdeps(const struct kmod_ctx *ctx) { if (ctx == NULL) - return NULL;; + return NULL; return kmod_config_iter_new(ctx, CONFIG_TYPE_WEAKDEP); } diff --git a/testsuite/test-testsuite.c b/testsuite/test-testsuite.c index 42c88e25..9ef19cc4 100644 --- a/testsuite/test-testsuite.c +++ b/testsuite/test-testsuite.c @@ -54,7 +54,7 @@ static int testsuite_rootfs_fopen(const struct test *t) fp = fopen(MODULE_DIRECTORY "/a", "r"); if (fp == NULL) - return EXIT_FAILURE;; + return EXIT_FAILURE; n = fscanf(fp, "%s", s); if (n != 1)