]> git.ipfire.org Git - pakfire.git/commitdiff
testsuite: Fix shadowed variables
authorMichael Tremer <michael.tremer@ipfire.org>
Thu, 9 Dec 2021 13:25:22 +0000 (13:25 +0000)
committerMichael Tremer <michael.tremer@ipfire.org>
Thu, 9 Dec 2021 13:25:22 +0000 (13:25 +0000)
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
tests/libpakfire/makefile.c
tests/libpakfire/parser.c

index 4ec9ef7960af4c23941c9d27efe43976b32785e3..75dac1c953190125d4cc2526eb8b45ff244183ab 100644 (file)
@@ -62,7 +62,7 @@ static int test_parse(const struct test* t) {
        int r = EXIT_FAILURE;
 
        while (*makefile) {
-               int r = snprintf(path, sizeof(path) - 1, "%s/%s", TEST_SRC_PATH, *makefile);
+               r = snprintf(path, sizeof(path) - 1, "%s/%s", TEST_SRC_PATH, *makefile);
                ASSERT(r >= 0);
 
                // Open file
index 56335fbef4d0238302a93beef535383ad9898142..9eff588758f5e827953370a8a4b1427ecda2c1ff 100644 (file)
@@ -120,7 +120,7 @@ static int test_parser_files(const struct test* t) {
        int r = EXIT_FAILURE;
 
        while (*file) {
-               int r = snprintf(path, sizeof(path) - 1, "%s/%s", TEST_SRC_PATH, *file);
+               r = snprintf(path, sizeof(path) - 1, "%s/%s", TEST_SRC_PATH, *file);
                ASSERT(r >= 0);
 
                // Create a new parser