Skip to content

Commit

Permalink
txfilter: Expose the txfilter_add_scriptpubkey function
Browse files Browse the repository at this point in the history
Signed-off-by: Christian Decker <[email protected]>
  • Loading branch information
cdecker committed Jan 8, 2018
1 parent e4e9e22 commit 2a3c9e9
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion lightningd/txfilter.c
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ struct txfilter *txfilter_new(const tal_t *ctx)
return filter;
}

static void txfilter_add_scriptpubkey(struct txfilter *filter, u8 *script)
void txfilter_add_scriptpubkey(struct txfilter *filter, u8 *script)
{
size_t count = tal_count(filter->scriptpubkeys);
tal_resize(&filter->scriptpubkeys, count + 1);
Expand Down
5 changes: 5 additions & 0 deletions lightningd/txfilter.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,4 +28,9 @@ void txfilter_add_derkey(struct txfilter *filter, u8 derkey[PUBKEY_DER_LEN]);
*/
bool txfilter_match(const struct txfilter *filter, const struct bitcoin_tx *tx);

/**
* txfilter_add_scriptpubkey -- Add a serialized scriptpubkey to the filter
*/
void txfilter_add_scriptpubkey(struct txfilter *filter, u8 *script);

#endif /* LIGHTNING_LIGHTNINGD_TXFILTER_H */

0 comments on commit 2a3c9e9

Please sign in to comment.