Skip to content

Commit

Permalink
fixup! sphinx: Check the payload size at construction and in createonion
Browse files Browse the repository at this point in the history
  • Loading branch information
cdecker committed Jan 9, 2020
1 parent 2e90e09 commit 8f1d56b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lightningd/pay.c
Original file line number Diff line number Diff line change
Expand Up @@ -1462,7 +1462,7 @@ static struct command_result *json_createonion(struct command *cmd,

if (sphinx_path_payloads_size(sp) > ROUTING_INFO_SIZE)
return command_fail(
cmd, LIGHTNINGD,
cmd, JSONRPC2_INVALID_PARAMS,
"Payloads exceed maximum onion packet size.");

packet = create_onionpacket(cmd, sp, &shared_secrets);
Expand Down

0 comments on commit 8f1d56b

Please sign in to comment.