Skip to content

Commit

Permalink
Makefile: update bolts a0bbe47b0278b4f152dbaa4f5fab2562413a217c
Browse files Browse the repository at this point in the history
"BOLT 04: remove associated data from test vector"

(We actually use merge point).

Signed-off-by: Rusty Russell <[email protected]>
  • Loading branch information
rustyrussell committed Apr 7, 2023
1 parent dfa6c0c commit f26b116
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 10 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ CCANDIR := ccan

# Where we keep the BOLT RFCs
BOLTDIR := ../bolts/
DEFAULT_BOLTVERSION := b38156b9510c0562cf50f8758a64602cc0315c19
DEFAULT_BOLTVERSION := a0bbe47b0278b4f152dbaa4f5fab2562413a217c
# Can be overridden on cmdline.
BOLTVERSION := $(DEFAULT_BOLTVERSION)

Expand Down
9 changes: 5 additions & 4 deletions common/sphinx.c
Original file line number Diff line number Diff line change
Expand Up @@ -694,10 +694,11 @@ struct onionreply *create_onionreply(const tal_t *ctx,

/* BOLT #4:
* The _erring node_:
* - SHOULD set `pad` such that the `failure_len` plus `pad_len`
* is equal to 256.
* - Note: this value is 118 bytes longer than the longest
* currently-defined message.
* - MUST set `pad` such that the `failure_len` plus `pad_len`
* is at least 256.
* - SHOULD set `pad` such that the `failure_len` plus `pad_len` is equal
* to 256. Deviating from this may cause older nodes to be unable to parse
* the return message.
*/
const u16 onion_reply_size = IFDEV(dev_onion_reply_length, 256);

Expand Down
8 changes: 4 additions & 4 deletions lightningd/htlc_set.c
Original file line number Diff line number Diff line change
Expand Up @@ -137,9 +137,9 @@ void htlc_set_add(struct lightningd *ld,
else {
/* BOLT #4:
*
* if it supports `basic_mpp`:
* otherwise, if it supports `basic_mpp`:
* ...
* - otherwise, if the total `amount_msat` of this HTLC set is
* - otherwise, if the total `amt_to_forward` of this HTLC set is
* less than `total_msat`:
* ...
* - MUST require `payment_secret` for all HTLCs in the set.
Expand Down Expand Up @@ -199,7 +199,7 @@ void htlc_set_add(struct lightningd *ld,
);

/* BOLT #4:
* - if the total `amount_msat` of this HTLC set is equal to or greater than
* - if the total `amt_to_forward` of this HTLC set is equal to or greater than
* `total_msat`:
* - SHOULD fulfill all HTLCs in the HTLC set
*/
Expand All @@ -211,7 +211,7 @@ void htlc_set_add(struct lightningd *ld,
}

/* BOLT #4:
* - otherwise, if the total `amount_msat` of this HTLC set is less than
* - otherwise, if the total `amt_to_forward` of this HTLC set is less than
* `total_msat`:
* - MUST NOT fulfill any HTLCs in the HTLC set
*...
Expand Down
2 changes: 1 addition & 1 deletion lightningd/pay.c
Original file line number Diff line number Diff line change
Expand Up @@ -1029,7 +1029,7 @@ send_payment_core(struct lightningd *ld,

/* BOLT #4:
*
* - MUST NOT send another HTLC if the total `amount_msat` of the HTLC
* - MUST NOT send another HTLC if the total `amt_to_forward` of the HTLC
* set is already greater or equal to `total_msat`.
*/
/* We don't do this for single 0-value payments (sendonion does this) */
Expand Down

0 comments on commit f26b116

Please sign in to comment.