diff options
Diffstat (limited to 'Tests')
-rw-r--r-- | Tests/RunCMake/exit_code.c | 3 | ||||
-rw-r--r-- | Tests/RunCMake/pseudo_cppcheck.c | 3 |
2 files changed, 4 insertions, 2 deletions
diff --git a/Tests/RunCMake/exit_code.c b/Tests/RunCMake/exit_code.c index 3eba019..9fa8eca 100644 --- a/Tests/RunCMake/exit_code.c +++ b/Tests/RunCMake/exit_code.c @@ -21,7 +21,8 @@ int main(int argc, const char* argv[]) } if (strcmp(str, substring_success) == 0) { return EXIT_SUCCESS; - } else if (strcmp(str, substring_failure) == 0) { + } + if (strcmp(str, substring_failure) == 0) { return EXIT_FAILURE; } fprintf(stderr, "Failed to find string '%s' in '%s'\n", substring_success, diff --git a/Tests/RunCMake/pseudo_cppcheck.c b/Tests/RunCMake/pseudo_cppcheck.c index 5b1531b..e80620c 100644 --- a/Tests/RunCMake/pseudo_cppcheck.c +++ b/Tests/RunCMake/pseudo_cppcheck.c @@ -11,7 +11,8 @@ int main(int argc, char* argv[]) fprintf(stdout, "stdout from bad command line arg '-bad'\n"); fprintf(stderr, "stderr from bad command line arg '-bad'\n"); return 1; - } else if (strcmp(argv[i], "-error") == 0) { + } + if (strcmp(argv[i], "-error") == 0) { // The real cppcheck allows to set the exitcode with --error-exitcode result = 5; } |