mirror of
https://github.com/ElementsProject/lightning.git
synced 2025-01-18 05:12:45 +01:00
json: Add the json interface for struct sha256
This commit is contained in:
parent
23bfdc307f
commit
a9e346a1f4
@ -472,3 +472,9 @@ void json_add_secret(struct json_stream *response, const char *fieldname,
|
||||
{
|
||||
json_add_hex(response, fieldname, secret, sizeof(struct secret));
|
||||
}
|
||||
|
||||
void json_add_sha256(struct json_stream *result, const char *fieldname,
|
||||
const struct sha256 *hash)
|
||||
{
|
||||
json_add_hex(result, fieldname, hash, sizeof(*hash));
|
||||
}
|
||||
|
@ -214,4 +214,7 @@ void json_add_timeabs(struct json_stream *result, const char *fieldname,
|
||||
void json_add_time(struct json_stream *result, const char *fieldname,
|
||||
struct timespec ts);
|
||||
|
||||
void json_add_sha256(struct json_stream *result, const char *fieldname,
|
||||
const struct sha256 *hash);
|
||||
|
||||
#endif /* LIGHTNING_LIGHTNINGD_JSON_H */
|
||||
|
Loading…
Reference in New Issue
Block a user