mirror of
https://github.com/aljazceru/lightning.git
synced 2025-12-19 07:04:22 +01:00
param: return type consistency
We were returning a pointer but expecting a bool. Signed-off-by: Mark Beckwith <wythe@intrig.com>
This commit is contained in:
committed by
Rusty Russell
parent
a79e64c0a0
commit
eb1a5b16c7
@@ -45,7 +45,7 @@ static bool make_callback(struct command *cmd,
|
||||
return def->cbx(cmd, def->name, buffer, tok, def->arg);
|
||||
}
|
||||
|
||||
static struct param *post_check(struct command *cmd, struct param *params)
|
||||
static bool post_check(struct command *cmd, struct param *params)
|
||||
{
|
||||
struct param *first = params;
|
||||
struct param *last = first + tal_count(params);
|
||||
@@ -56,11 +56,11 @@ static struct param *post_check(struct command *cmd, struct param *params)
|
||||
command_fail(cmd, JSONRPC2_INVALID_PARAMS,
|
||||
"missing required parameter: '%s'",
|
||||
first->name);
|
||||
return NULL;
|
||||
return false;
|
||||
}
|
||||
first++;
|
||||
}
|
||||
return params;
|
||||
return true;
|
||||
}
|
||||
|
||||
static bool parse_by_position(struct command *cmd,
|
||||
|
||||
Reference in New Issue
Block a user