mirror of
https://github.com/aljazceru/lightning.git
synced 2025-12-24 01:24:26 +01:00
common/json: move declaration into correct header.
Reported-by: @ZmnSCPxj Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
@@ -11,6 +11,7 @@
|
||||
#define JSMN_STRICT 1
|
||||
# include <external/jsmn/jsmn.h>
|
||||
|
||||
struct json_escaped;
|
||||
struct json_result;
|
||||
struct short_channel_id;
|
||||
|
||||
@@ -80,6 +81,12 @@ struct json_result *new_json_result(const tal_t *ctx);
|
||||
*/
|
||||
void json_add_string(struct json_result *result, const char *fieldname, const char *value);
|
||||
|
||||
/* '"fieldname" : "value"' or '"value"' if fieldname is NULL. String must
|
||||
* already be JSON escaped as necessary. */
|
||||
void json_add_escaped_string(struct json_result *result,
|
||||
const char *fieldname,
|
||||
const struct json_escaped *esc TAKES);
|
||||
|
||||
/* '"fieldname" : literal' or 'literal' if fieldname is NULL*/
|
||||
void json_add_literal(struct json_result *result, const char *fieldname,
|
||||
const char *literal, int len);
|
||||
|
||||
Reference in New Issue
Block a user