Exclude a few lines from lcov coverage stats:
- "fail" branches in selftests
- "should never happen" errors in SSL
- cipher_xxx() failures in SSL
- some things that fail only if malloc() fails
- some things that fail only if fread/fwrite()/ftell() fails
(after fopen() succeeded)
- some things that fail only if a parameter is invalid, but the parameter was
actually validated earlier
- generated code in library/error.c
diff --git a/scripts/data_files/error.fmt b/scripts/data_files/error.fmt
index bd6ef01..5d6f795 100644
--- a/scripts/data_files/error.fmt
+++ b/scripts/data_files/error.fmt
@@ -62,7 +62,9 @@
// High level error codes
//
// BEGIN generated code
+ // LCOV_EXCL_START
HIGH_LEVEL_CODE_CHECKS
+ // LCOV_EXCL_STOP
// END generated code
if( strlen( buf ) == 0 )
@@ -93,7 +95,9 @@
// Low level error codes
//
// BEGIN generated code
+ // LCOV_EXCL_START
LOW_LEVEL_CODE_CHECKS
+ // LCOV_EXCL_STOP
// END generated code
if( strlen( buf ) != 0 )