mirror of
https://github.com/ElementsProject/lightning.git
synced 2025-01-18 05:12:45 +01:00
json: remove unused json_get_arr parameter.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
parent
af8e4ed2b9
commit
a4346b56f6
@ -157,8 +157,7 @@ const jsmntok_t *json_get_member(const char *buffer, const jsmntok_t tok[],
|
|||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
const jsmntok_t *json_get_arr(const char *buffer, const jsmntok_t tok[],
|
const jsmntok_t *json_get_arr(const jsmntok_t tok[], size_t index)
|
||||||
size_t index)
|
|
||||||
{
|
{
|
||||||
const jsmntok_t *t, *end;
|
const jsmntok_t *t, *end;
|
||||||
|
|
||||||
@ -195,7 +194,7 @@ const jsmntok_t *json_delve(const char *buffer,
|
|||||||
case '[':
|
case '[':
|
||||||
if (tok->type != JSMN_ARRAY)
|
if (tok->type != JSMN_ARRAY)
|
||||||
return tal_free(key);
|
return tal_free(key);
|
||||||
tok = json_get_arr(buffer, tok, atol(key));
|
tok = json_get_arr(tok, atol(key));
|
||||||
if (!tok)
|
if (!tok)
|
||||||
return tal_free(key);
|
return tal_free(key);
|
||||||
/* Must be terminated */
|
/* Must be terminated */
|
||||||
|
@ -56,8 +56,7 @@ const jsmntok_t *json_get_member(const char *buffer, const jsmntok_t tok[],
|
|||||||
const char *label);
|
const char *label);
|
||||||
|
|
||||||
/* Get index'th array member. */
|
/* Get index'th array member. */
|
||||||
const jsmntok_t *json_get_arr(const char *buffer, const jsmntok_t tok[],
|
const jsmntok_t *json_get_arr(const jsmntok_t tok[], size_t index);
|
||||||
size_t index);
|
|
||||||
|
|
||||||
/* Guide is a string with . for members, [] around indexes. */
|
/* Guide is a string with . for members, [] around indexes. */
|
||||||
const jsmntok_t *json_delve(const char *buffer,
|
const jsmntok_t *json_delve(const char *buffer,
|
||||||
|
Loading…
Reference in New Issue
Block a user