mirror of
https://github.com/sqlite/sqlite.git
synced 2025-11-09 14:21:03 +03:00
Fix a harmless compiler warning about variant types for a pointer function.
FossilOrigin-Name: 37ff0d8e7f91c32e8c53bb015280be47c66bf599281b640a8d3fd41335b55289
This commit is contained in:
10
src/json.c
10
src/json.c
@@ -602,7 +602,7 @@ static void jsonResult(JsonString *p){
|
||||
}else if( jsonForceRCStr(p) ){
|
||||
sqlite3RCStrRef(p->zBuf);
|
||||
sqlite3_result_text64(p->pCtx, p->zBuf, p->nUsed,
|
||||
(void(*)(void*))sqlite3RCStrUnref,
|
||||
sqlite3RCStrUnref,
|
||||
SQLITE_UTF8);
|
||||
}
|
||||
}
|
||||
@@ -1942,7 +1942,7 @@ static JsonParse *jsonParseCached(
|
||||
/* The input JSON was not found anywhere in the cache. We will need
|
||||
** to parse it ourselves and generate a new JsonParse object.
|
||||
*/
|
||||
bJsonRCStr = sqlite3ValueIsOfClass(pJson,(void(*)(void*))sqlite3RCStrUnref);
|
||||
bJsonRCStr = sqlite3ValueIsOfClass(pJson,sqlite3RCStrUnref);
|
||||
p = sqlite3_malloc64( sizeof(*p) + (bJsonRCStr ? 0 : nJson+1) );
|
||||
if( p==0 ){
|
||||
sqlite3_result_error_nomem(pCtx);
|
||||
@@ -3127,7 +3127,7 @@ static void jsonArrayCompute(sqlite3_context *ctx, int isFinal){
|
||||
}else if( isFinal ){
|
||||
sqlite3_result_text(ctx, pStr->zBuf, (int)pStr->nUsed,
|
||||
pStr->bStatic ? SQLITE_TRANSIENT :
|
||||
(void(*)(void*))sqlite3RCStrUnref);
|
||||
sqlite3RCStrUnref);
|
||||
pStr->bStatic = 1;
|
||||
}else{
|
||||
sqlite3_result_text(ctx, pStr->zBuf, (int)pStr->nUsed, SQLITE_TRANSIENT);
|
||||
@@ -3236,7 +3236,7 @@ static void jsonObjectCompute(sqlite3_context *ctx, int isFinal){
|
||||
}else if( isFinal ){
|
||||
sqlite3_result_text(ctx, pStr->zBuf, (int)pStr->nUsed,
|
||||
pStr->bStatic ? SQLITE_TRANSIENT :
|
||||
(void(*)(void*))sqlite3RCStrUnref);
|
||||
sqlite3RCStrUnref);
|
||||
pStr->bStatic = 1;
|
||||
}else{
|
||||
sqlite3_result_text(ctx, pStr->zBuf, (int)pStr->nUsed, SQLITE_TRANSIENT);
|
||||
@@ -3668,7 +3668,7 @@ static int jsonEachFilter(
|
||||
if( z==0 ) return SQLITE_OK;
|
||||
memset(&p->sParse, 0, sizeof(p->sParse));
|
||||
p->sParse.nJPRef = 1;
|
||||
if( sqlite3ValueIsOfClass(argv[0], (void(*)(void*))sqlite3RCStrUnref) ){
|
||||
if( sqlite3ValueIsOfClass(argv[0], sqlite3RCStrUnref) ){
|
||||
p->sParse.zJson = sqlite3RCStrRef((char*)z);
|
||||
}else{
|
||||
n = sqlite3_value_bytes(argv[0]);
|
||||
|
||||
Reference in New Issue
Block a user