Encode reversed hex for txid in listfunds

This commit is contained in:
Andrew Chow 2017-12-12 15:32:32 -05:00 committed by Rusty Russell
parent 19116b6561
commit f792e236eb

View File

@ -456,7 +456,7 @@ static void json_listfunds(struct command *cmd, const char *buffer,
json_array_start(response, "outputs");
for (int i = 0; i < tal_count(utxos); i++) {
json_object_start(response, NULL);
json_add_hex(response, "txid", &utxos[i]->txid,
json_add_hex_reversed(response, "txid", &utxos[i]->txid,
sizeof(struct sha256_double));
json_add_num(response, "output", utxos[i]->outnum);
json_add_u64(response, "value", utxos[i]->amount);