| 169 | } |
| 170 | |
| 171 | struct txwatch *watch_tx(const tal_t *ctx, |
| 172 | struct chain_topology *topo, |
| 173 | struct channel *channel, |
| 174 | const struct bitcoin_tx *tx, |
| 175 | enum watch_result (*cb)(struct lightningd *ld, |
| 176 | struct channel *channel, |
| 177 | const struct bitcoin_txid *, |
| 178 | const struct bitcoin_tx *, |
| 179 | unsigned int depth)) |
| 180 | { |
| 181 | struct bitcoin_txid txid; |
| 182 | |
| 183 | bitcoin_txid(tx, &txid); |
| 184 | /* FIXME: Save populate txwatch->tx here, too! */ |
| 185 | return watch_txid(ctx, topo, channel, &txid, cb); |
| 186 | } |
| 187 | |
| 188 | struct txowatch *watch_txo(const tal_t *ctx, |
| 189 | struct chain_topology *topo, |
no test coverage detected