Ensure coverage info is not empty. This seems to be caused by a change in lcov. Originally detected in Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1144176
diff --git a/test cases/common/1 trivial/trivial.c b/test cases/common/1 trivial/trivial.c index 96612d4..7737f74 100644 --- a/test cases/common/1 trivial/trivial.c +++ b/test cases/common/1 trivial/trivial.c
@@ -1,6 +1,11 @@ #include<stdio.h> -int main(void) { +int main(int argc, char **argv) { + // Have a non-elidable branch to make sure coverage info is not empty. + if(argc > 1) { + printf("A command line argument was passed to the program.\n"); + (void)argv; + } printf("Trivial test is working.\n"); return 0; }
diff --git a/test cases/common/243 escape++/test.c b/test cases/common/243 escape++/test.c index 9b6bdc2..4a82fd3 100644 --- a/test cases/common/243 escape++/test.c +++ b/test cases/common/243 escape++/test.c
@@ -1,3 +1,9 @@ -int main(void) { +#include <stdio.h> + +int main(int argc, char **argv) { + if(argc > 1) { + printf("A command line argument was passed to this program.\n"); + (void)argv; + } return 0; }