| 387 | } |
| 388 | |
| 389 | void bitcoind_sendrawtx_(const tal_t *ctx, |
| 390 | struct bitcoind *bitcoind, |
| 391 | const char *id_prefix, |
| 392 | const char *hextx, |
| 393 | bool allowhighfees, |
| 394 | void (*cb)(struct bitcoind *bitcoind, |
| 395 | bool success, const char *msg, void *), |
| 396 | void *cb_arg) |
| 397 | { |
| 398 | struct jsonrpc_request *req; |
| 399 | struct sendrawtx_call *call = tal(ctx, struct sendrawtx_call); |
| 400 | |
| 401 | call->bitcoind = bitcoind; |
| 402 | call->cb = cb; |
| 403 | call->cb_arg = cb_arg; |
| 404 | log_debug(bitcoind->log, "sendrawtransaction: %s", hextx); |
| 405 | |
| 406 | req = jsonrpc_request_start(call, "sendrawtransaction", |
| 407 | id_prefix, |
| 408 | bitcoind->log, |
| 409 | NULL, sendrawtx_callback, |
| 410 | call); |
| 411 | json_add_string(req->stream, "tx", hextx); |
| 412 | json_add_bool(req->stream, "allowhighfees", allowhighfees); |
| 413 | jsonrpc_request_end(req); |
| 414 | bitcoin_plugin_send(bitcoind, req); |
| 415 | } |
| 416 | |
| 417 | /* `getrawblockbyheight` |
| 418 | * |
nothing calls this directly
no test coverage detected