Skip to content

Commit

Permalink
devtools/bolt12-cli: fix decoding of unknown fields.
Browse files Browse the repository at this point in the history
We had known vs unknown backwards ("it's OK to be odd!")

Signed-off-by: Rusty Russell <[email protected]>
  • Loading branch information
rustyrussell committed Jul 23, 2024
1 parent c342f20 commit 6d6716c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion devtools/bolt12-cli.c
Original file line number Diff line number Diff line change
Expand Up @@ -399,7 +399,7 @@ static bool print_extra_fields(const struct tlv_field *fields)
for (size_t i = 0; i < tal_count(fields); i++) {
if (fields[i].meta)
continue;
if (fields[i].numtype % 2) {
if (fields[i].numtype % 2 == 0) {
printf("UNKNOWN EVEN field %"PRIu64": %s\n",
fields[i].numtype,
tal_hexstr(tmpctx, fields[i].value, fields[i].length));
Expand Down

0 comments on commit 6d6716c

Please sign in to comment.