Browse Source

bitcoind: peer argument to bitcoind_sendrawtx is unused

This was a bit misleading, and we were passing in NULL sometimes
anyway. Removed unused argument.
ppa-0.6.1
Christian Decker 8 years ago
committed by Rusty Russell
parent
commit
28030c3d6b
  1. 3
      daemon/bitcoind.c
  2. 7
      daemon/bitcoind.h
  3. 4
      daemon/chaintopology.c

3
daemon/bitcoind.c

@ -286,8 +286,7 @@ static void process_sendrawtx(struct bitcoin_cli *bcli)
cb(bcli->bitcoind, *bcli->exitstatus, msg, bcli->cb_arg);
}
void bitcoind_sendrawtx_(struct peer *peer,
struct bitcoind *bitcoind,
void bitcoind_sendrawtx_(struct bitcoind *bitcoind,
const char *hextx,
void (*cb)(struct bitcoind *bitcoind,
int exitstatus, const char *msg, void *),

7
daemon/bitcoind.h

@ -52,15 +52,14 @@ void bitcoind_estimate_fee_(struct bitcoind *bitcoind,
u64), \
(arg))
void bitcoind_sendrawtx_(struct peer *peer,
struct bitcoind *bitcoind,
void bitcoind_sendrawtx_(struct bitcoind *bitcoind,
const char *hextx,
void (*cb)(struct bitcoind *bitcoind,
int exitstatus, const char *msg, void *),
void *arg);
#define bitcoind_sendrawtx(peer_, bitcoind_, hextx, cb, arg) \
bitcoind_sendrawtx_((peer_), (bitcoind_), (hextx), \
#define bitcoind_sendrawtx(bitcoind_, hextx, cb, arg) \
bitcoind_sendrawtx_((bitcoind_), (hextx), \
typesafe_cb_preargs(void, void *, \
(cb), (arg), \
struct bitcoind *, \

4
daemon/chaintopology.c

@ -193,7 +193,7 @@ static void broadcast_remainder(struct bitcoind *bitcoind,
}
/* Broadcast next one. */
bitcoind_sendrawtx(NULL, bitcoind, txs->txs[txs->cursor],
bitcoind_sendrawtx(bitcoind, txs->txs[txs->cursor],
broadcast_remainder, txs);
}
@ -284,7 +284,7 @@ void broadcast_tx(struct chain_topology *topo,
if (topo->dev_no_broadcast)
broadcast_done(topo->bitcoind, 0, "dev_no_broadcast", otx);
else
bitcoind_sendrawtx(peer, topo->bitcoind, otx->hextx,
bitcoind_sendrawtx(topo->bitcoind, otx->hextx,
broadcast_done, otx);
}

Loading…
Cancel
Save