remove_dust: don't ever create dust outputs.

This behavior will be specified in BOLT #3.

Closes: #14

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
Rusty Russell
2016-05-02 16:06:56 +09:30
parent 7614e513bd
commit a150bd191a
4 changed files with 45 additions and 0 deletions

12
remove_dust.h Normal file
View File

@@ -0,0 +1,12 @@
#ifndef LIGHTNING_REMOVE_DUST_H
#define LIGHTNING_REMOVE_DUST_H
#include "config.h"
#include "bitcoin/tx.h"
/* Remove all dust outputs from tx */
void remove_dust(struct bitcoin_tx *tx, int *map);
/* Less than this is dust. */
#define DUST_THRESHOLD 546
#endif /* LIGHTNING_REMOVE_DUST_H */