diff options
author | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2022-03-23 10:48:13 +0100 |
---|---|---|
committer | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2022-03-23 11:50:18 +0100 |
commit | 5980d463048f25411c55da2f6387cdc8eaeef4c8 (patch) | |
tree | e5c32417015bfd67d326d278b1cd7dac3ada39de /src/test/test-mount-util.c | |
parent | Merge pull request #22629 from nishalkulkarni/oomd_service_result (diff) | |
download | systemd-5980d463048f25411c55da2f6387cdc8eaeef4c8.tar.xz systemd-5980d463048f25411c55da2f6387cdc8eaeef4c8.zip |
strv: declare iterator of FOREACH_STRING() in the loop
Same idea as 03677889f0ef42cdc534bf3b31265a054b20a354.
No functional change intended. The type of the iterator is generally changed to
be 'const char*' instead of 'char*'. Despite the type commonly used, modifying
the string was not allowed.
I adjusted the naming of some short variables for clarity and reduced the scope
of some variable declarations in code that was being touched anyway.
Diffstat (limited to 'src/test/test-mount-util.c')
-rw-r--r-- | src/test/test-mount-util.c | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/src/test/test-mount-util.c b/src/test/test-mount-util.c index 74d352268e..7e06fc419c 100644 --- a/src/test/test-mount-util.c +++ b/src/test/test-mount-util.c @@ -128,7 +128,6 @@ TEST(mount_flags_to_string) { TEST(bind_remount_recursive) { _cleanup_(rm_rf_physical_and_freep) char *tmp = NULL; _cleanup_free_ char *subdir = NULL; - const char *p; if (geteuid() != 0 || have_effective_cap(CAP_SYS_ADMIN) <= 0) { (void) log_tests_skipped("not running privileged"); |