mirror of
https://github.com/aljazceru/lightning.git
synced 2025-12-19 15:14:23 +01:00
features: add 'feature_bit_sub', which will subtract/unset bits
Given a two sets of featurebits, unset the featurebits in the first set that are set in the second set
This commit is contained in:
@@ -32,6 +32,10 @@ void towire_feature_set(u8 **pptr, const struct feature_set *fset);
|
||||
bool feature_set_or(struct feature_set *a,
|
||||
const struct feature_set *b TAKES);
|
||||
|
||||
/* a - b, or returns false if features not already in a */
|
||||
bool feature_set_sub(struct feature_set *a,
|
||||
const struct feature_set *b TAKES);
|
||||
|
||||
/* Returns -1 if we're OK with all these offered features, otherwise first
|
||||
* unsupported (even) feature. */
|
||||
int features_unsupported(const struct feature_set *our_features,
|
||||
|
||||
Reference in New Issue
Block a user