diff options
author | drh <drh@noemail.net> | 2016-02-11 15:37:18 +0000 |
---|---|---|
committer | drh <drh@noemail.net> | 2016-02-11 15:37:18 +0000 |
commit | df3a907eccf70577725c4dd62120221e9d0ff11c (patch) | |
tree | f40c5cc86973059d406b0c56372bf3ef496a4c11 /ext/misc/json1.c | |
parent | 8988aeef607f1b39e1176d148d8ac786049a3c92 (diff) | |
download | sqlite-df3a907eccf70577725c4dd62120221e9d0ff11c.tar.gz sqlite-df3a907eccf70577725c4dd62120221e9d0ff11c.zip |
Add JSON1 and FTS5 to the set of extensions subject to close compiler warning
analysis. Fix some warnings in each. More (harmless) warnings still exist
in FTS5.
FossilOrigin-Name: cfe2eb88b504f5e9b1351022036641b1ac4c3e78
Diffstat (limited to 'ext/misc/json1.c')
-rw-r--r-- | ext/misc/json1.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/ext/misc/json1.c b/ext/misc/json1.c index 3c63b6e94..99d299c29 100644 --- a/ext/misc/json1.c +++ b/ext/misc/json1.c @@ -31,7 +31,11 @@ SQLITE_EXTENSION_INIT1 #include <stdlib.h> #include <stdarg.h> -#define UNUSED_PARAM(X) (void)(X) +/* Mark a function parameter as unused, to suppress nuisance compiler +** warnings. */ +#ifndef UNUSED_PARAM +# define UNUSED_PARAM(X) (void)(X) +#endif #ifndef LARGEST_INT64 # define LARGEST_INT64 (0xffffffff|(((sqlite3_int64)0x7fffffff)<<32)) @@ -1552,6 +1556,7 @@ static void jsonArrayStep( sqlite3_value **argv ){ JsonString *pStr; + UNUSED_PARAM(argc); pStr = (JsonString*)sqlite3_aggregate_context(ctx, sizeof(*pStr)); if( pStr ){ if( pStr->zBuf==0 ){ @@ -1597,6 +1602,7 @@ static void jsonObjectStep( JsonString *pStr; const char *z; u32 n; + UNUSED_PARAM(argc); pStr = (JsonString*)sqlite3_aggregate_context(ctx, sizeof(*pStr)); if( pStr ){ if( pStr->zBuf==0 ){ |