aboutsummaryrefslogtreecommitdiff
path: root/ext/misc/json1.c
diff options
context:
space:
mode:
authordrh <drh@noemail.net>2018-05-16 12:19:11 +0000
committerdrh <drh@noemail.net>2018-05-16 12:19:11 +0000
commitdd7460f0fd4232b9838a321a4655965af18bb551 (patch)
tree17130358fca19d2f5f2a00ae6dedf2e9ca0f395f /ext/misc/json1.c
parenta44005af4f37148190e15f77d6702018a78c1718 (diff)
downloadsqlite-dd7460f0fd4232b9838a321a4655965af18bb551.tar.gz
sqlite-dd7460f0fd4232b9838a321a4655965af18bb551.zip
Correct output for the fullkey column of json_each() when the total JSON
input is a simple value, not an array or object. FossilOrigin-Name: b45b18850c59f22a163ee482f529f578a8798f96d0e26b5a061d336d480a1540
Diffstat (limited to 'ext/misc/json1.c')
-rw-r--r--ext/misc/json1.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/misc/json1.c b/ext/misc/json1.c
index c1d2334a1..735e3c94a 100644
--- a/ext/misc/json1.c
+++ b/ext/misc/json1.c
@@ -2118,7 +2118,7 @@ static int jsonEachColumn(
}
if( p->eType==JSON_ARRAY ){
jsonPrintf(30, &x, "[%d]", p->iRowid);
- }else{
+ }else if( p->eType==JSON_OBJECT ){
jsonPrintf(pThis->n, &x, ".%.*s", pThis->n-2, pThis->u.zJContent+1);
}
}