diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/json.c | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/src/json.c b/src/json.c index 217c1070c..0ce68f1fc 100644 --- a/src/json.c +++ b/src/json.c @@ -733,10 +733,12 @@ static void jsonReturnJson( sqlite3_result_error_nomem(pCtx); return; } - jsonInit(&s, pCtx); - jsonRenderNode(pParse, pNode, &s); - jsonResult(&s); - sqlite3_result_subtype(pCtx, JSON_SUBTYPE); + if( pParse->nErr==0 ){ + jsonInit(&s, pCtx); + jsonRenderNode(pParse, pNode, &s); + jsonResult(&s); + sqlite3_result_subtype(pCtx, JSON_SUBTYPE); + } } /* @@ -2705,6 +2707,11 @@ static void jsonReplaceNode( } break; } + case SQLITE_BLOB: { + sqlite3_result_error(pCtx, "JSON cannot hold BLOB values", -1); + p->nErr++; + break; + } } } |