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

Function param_u16

common/json_param.c:552–562  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

550}
551
552struct command_result *param_u16(struct command *cmd, const char *name,
553 const char *buffer, const jsmntok_t *tok,
554 uint16_t **num)
555{
556 *num = tal(cmd, uint16_t);
557 if (json_to_u16(buffer, tok, *num))
558 return NULL;
559
560 return command_fail_badparam(cmd, name, buffer, tok,
561 "should be an unsigned 16 bit integer");
562}
563
564struct command_result *param_u32(struct command *cmd, const char *name,
565 const char *buffer, const jsmntok_t *tok,

Callers

nothing calls this directly

Calls 2

json_to_u16Function · 0.70
command_fail_badparamFunction · 0.70

Tested by

no test coverage detected