From ead48f7d92888013f1f7450aad1bc70d0a9d4e55 Mon Sep 17 00:00:00 2001 From: moneromooo-monero Date: Sat, 9 Dec 2017 11:24:38 +0000 Subject: [PATCH] core: fix input ordering from v7 --- src/cryptonote_core/cryptonote_tx_utils.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/cryptonote_core/cryptonote_tx_utils.cpp b/src/cryptonote_core/cryptonote_tx_utils.cpp index 20697520f..4afa669fd 100644 --- a/src/cryptonote_core/cryptonote_tx_utils.cpp +++ b/src/cryptonote_core/cryptonote_tx_utils.cpp @@ -281,7 +281,7 @@ namespace cryptonote std::sort(ins_order.begin(), ins_order.end(), [&](const size_t i0, const size_t i1) { const txin_to_key &tk0 = boost::get(tx.vin[i0]); const txin_to_key &tk1 = boost::get(tx.vin[i1]); - return memcmp(&tk0.k_image, &tk1.k_image, sizeof(tk0.k_image)) < 0; + return memcmp(&tk0.k_image, &tk1.k_image, sizeof(tk0.k_image)) > 0; }); tools::apply_permutation(ins_order, [&] (size_t i0, size_t i1) { std::swap(tx.vin[i0], tx.vin[i1]);