From 78ed4f1c4a8130497ff656a93e99e15979ee14db Mon Sep 17 00:00:00 2001 From: Jim Radford Date: Mon, 19 Aug 2013 16:07:28 -0700 Subject: [PATCH] curl_json plugin: don't complain about not finding expected maps in arrays The arrays may have mixed maps and scalars. I'm looking at you Solr. --- src/curl_json.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/curl_json.c b/src/curl_json.c index 511863e3..b7eaf399 100644 --- a/src/curl_json.c +++ b/src/curl_json.c @@ -229,7 +229,7 @@ static int cj_cb_number (void *ctx, buffer[sizeof (buffer) - 1] = 0; if ((key == NULL) || !CJ_IS_KEY (key)) { - if (key != NULL) + if (key != NULL && !db->state[db->depth].in_array/*can be inhomogeneous*/) NOTICE ("curl_json plugin: Found \"%s\", but the configuration expects" " a map.", buffer); cj_cb_inc_array_index (ctx, /* update_key = */ 0); -- 2.11.0