MCPcopy Create free account
hub / github.com/ElementsProject/lightning / json_to_u32

Function json_to_u32

common/json_parse_simple.c:91–103  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

89}
90
91bool json_to_u32(const char *buffer, const jsmntok_t *tok, u32 *num)
92{
93 uint64_t u64;
94
95 if (!json_to_u64(buffer, tok, &u64))
96 return false;
97 *num = u64;
98
99 /* Just in case it doesn't fit. */
100 if (*num != u64)
101 return false;
102 return true;
103}
104
105bool json_to_bool(const char *buffer, const jsmntok_t *tok, bool *b)
106{

Callers 6

json_to_outpointFunction · 0.70
param_u32Function · 0.70
estimatefees_callbackFunction · 0.50
handle_notifyFunction · 0.50
mainFunction · 0.50

Calls 1

json_to_u64Function · 0.70

Tested by 1

mainFunction · 0.40