diff options
author | drh <> | 2021-10-04 18:21:14 +0000 |
---|---|---|
committer | drh <> | 2021-10-04 18:21:14 +0000 |
commit | 11a9ad566929d7c8112be6d14c6c25f346f4dc5a (patch) | |
tree | 43a6d28aa1cf496abe02d5013fa6d095734cbca3 /src/sqliteInt.h | |
parent | 1076130a5d844978948247fb89374a91e9edab13 (diff) | |
download | sqlite-11a9ad566929d7c8112be6d14c6c25f346f4dc5a.tar.gz sqlite-11a9ad566929d7c8112be6d14c6c25f346f4dc5a.zip |
Fix harmless static analyzer warnings in sessions, rtree, fts3 and fts5.
Add the -DSQLITE_OMIT_AUXILIARY_SAFETY_CHECKS compile-time option to cause
ALWAYS() and NEVER() macros to be omitted from the build.
FossilOrigin-Name: 1c67f957fc77e37ce8f0d447c41ca975e8e79a35d332739c24a633649b5b0387
Diffstat (limited to 'src/sqliteInt.h')
-rw-r--r-- | src/sqliteInt.h | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/sqliteInt.h b/src/sqliteInt.h index a7f830263..d941de07a 100644 --- a/src/sqliteInt.h +++ b/src/sqliteInt.h @@ -470,6 +470,14 @@ #endif /* +** Disable ALWAYS() and NEVER() (make them pass-throughs) for coverage +** and mutation testing +*/ +#if defined(SQLITE_COVERATE_TEST) || defined(SQLITE_MUTATION_TEST) +# define SQLITE_OMIT_AUXILIARY_SAFETY_CHECKS 1 +#endif + +/* ** The ALWAYS and NEVER macros surround boolean expressions which ** are intended to always be true or false, respectively. Such ** expressions could be omitted from the code completely. But they @@ -484,7 +492,7 @@ ** be true and false so that the unreachable code they specify will ** not be counted as untested code. */ -#if defined(SQLITE_COVERAGE_TEST) || defined(SQLITE_MUTATION_TEST) +#if defined(SQLITE_OMIT_AUXILIARY_SAFETY_CHECKS) # define ALWAYS(X) (1) # define NEVER(X) (0) #elif !defined(NDEBUG) |