cleanup: make 'u8 *features' and 'struct feature_set *fset' more explicit.

It's almost always "their_features" and "our_features" respectively, so
make those names clear.

Suggested-by: @cdecker
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
Rusty Russell
2020-04-03 10:33:59 +10:30
parent 28e3ffc66b
commit 2f1502abf4
31 changed files with 134 additions and 116 deletions

View File

@@ -135,7 +135,7 @@ static struct io_plan *peer_write_postclose(struct io_conn *conn,
struct io_plan *peer_exchange_initmsg(struct io_conn *conn,
struct daemon *daemon,
const struct feature_set *fset,
const struct feature_set *our_features,
const struct crypto_state *cs,
const struct node_id *id,
const struct wireaddr_internal *addr)
@@ -182,8 +182,8 @@ struct io_plan *peer_exchange_initmsg(struct io_conn *conn,
* Finally, we agreed that bits below 13 could be put in both, but
* from now on they'll all go in initfeatures. */
peer->msg = towire_init(NULL,
fset->bits[GLOBAL_INIT_FEATURE],
fset->bits[INIT_FEATURE],
our_features->bits[GLOBAL_INIT_FEATURE],
our_features->bits[INIT_FEATURE],
tlvs);
status_peer_io(LOG_IO_OUT, &peer->id, peer->msg);
peer->msg = cryptomsg_encrypt_msg(peer, &peer->cs, take(peer->msg));