diff options
author | Lee Clagett <code@leeclagett.com> | 2020-03-25 03:02:28 -0400 |
---|---|---|
committer | Lee Clagett <code@leeclagett.com> | 2020-03-14 19:17:15 +0000 |
commit | 5de2295f3c215303527f649461bc2ed7113efc7c (patch) | |
tree | 36530e063fb84662f4bac49cf0a330eb7cc36f09 /tests/core_tests/tx_pool.h | |
parent | Merge pull request #6388 (diff) | |
download | monero-5de2295f3c215303527f649461bc2ed7113efc7c.tar.xz |
Correct key image check in tx_pool
Diffstat (limited to 'tests/core_tests/tx_pool.h')
-rw-r--r-- | tests/core_tests/tx_pool.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/core_tests/tx_pool.h b/tests/core_tests/tx_pool.h index 996c76698..eb71dcf79 100644 --- a/tests/core_tests/tx_pool.h +++ b/tests/core_tests/tx_pool.h @@ -77,6 +77,7 @@ class txpool_double_spend_base : public txpool_base std::unordered_set<crypto::hash> m_no_relay_hashes; std::unordered_map<crypto::hash, uint64_t> m_all_hashes; size_t m_no_new_index; + size_t m_failed_index; size_t m_new_timestamp_index; crypto::hash m_last_tx; @@ -86,6 +87,7 @@ public: txpool_double_spend_base(); bool mark_no_new(cryptonote::core& c, size_t ev_index, const std::vector<test_event_entry>& events); + bool mark_failed(cryptonote::core& c, size_t ev_index, const std::vector<test_event_entry>& events); bool mark_timestamp_change(cryptonote::core& c, size_t ev_index, const std::vector<test_event_entry>& events); //! Pause for 1 second, so that `receive_time` for tx meta changes (tx hidden from public rpc being updated) @@ -116,3 +118,12 @@ struct txpool_double_spend_local : txpool_double_spend_base bool generate(std::vector<test_event_entry>& events) const; }; + +struct txpool_double_spend_keyimage : txpool_double_spend_base +{ + txpool_double_spend_keyimage() + : txpool_double_spend_base() + {} + + bool generate(std::vector<test_event_entry>& events) const; +}; |