]> git.bitcoin.ninja Git - rust-lightning/commit
Generalize with_known_relevant_init_flags
authorJeffrey Czyz <jkczyz@gmail.com>
Wed, 22 Apr 2020 23:52:11 +0000 (16:52 -0700)
committerJeffrey Czyz <jkczyz@gmail.com>
Wed, 29 Apr 2020 18:11:51 +0000 (11:11 -0700)
commit4bd2c974a2c96a2ce98a4055a72b2b3c687e78bc
treee97f95312fd0e5cf4dec036ed6e35cb66e46aedf
parent65ff1bf0beaeb33397c5024d278a65a780fc8ffd
Generalize with_known_relevant_init_flags

Converting from InitFeatures to other Features is accomplished using
Features::with_known_relevant_init_flags. Define a more general
to_context method which converts from Features of one Context to
another.

Additionally, ensure the source context only has known flags before
selecting flags for the target context.
lightning/src/ln/features.rs
lightning/src/ln/functional_tests.rs
lightning/src/ln/router.rs