From b043f8cc0f59c22b147b11eafbdec9619586b73a Mon Sep 17 00:00:00 2001 From: sowle Date: Tue, 26 Nov 2019 12:13:56 +0300 Subject: [PATCH] wallet: getting rid of unused code --- src/wallet/wallet2.cpp | 33 --------------------------------- src/wallet/wallet2.h | 1 - 2 files changed, 34 deletions(-) diff --git a/src/wallet/wallet2.cpp b/src/wallet/wallet2.cpp index cd4c4535..258e5668 100644 --- a/src/wallet/wallet2.cpp +++ b/src/wallet/wallet2.cpp @@ -3089,39 +3089,6 @@ bool wallet2::get_contracts(escrow_contracts_container& contracts) return true; } //---------------------------------------------------------------------------------------------------- -bool wallet2::get_fake_offers(std::list& offers, uint64_t amount) -{ - - for (uint64_t i = 0; i != amount; i++) - { - bc_services::offer_details od; - od.offer_type = rand() % 4; - od.amount_primary = rand(); - od.amount_target = rand(); - od.bonus = get_random_rext(10); - od.target = get_random_rext(10); - od.location_country = get_random_rext(6); - od.location_city = get_random_rext(10); - od.contacts = get_random_rext(20); - od.comment = get_random_rext(30); - od.payment_types = get_random_rext(10); - od.deal_option = get_random_rext(10); - od.category = get_random_rext(4); - od.expiration_time = 3; - - crypto::hash tx_id = crypto::rand(); - offers.push_back(bc_services::offer_details_ex()); - bc_services::offer_details_ex& odl = offers.back(); - static_cast(odl) = od; - odl.timestamp = m_core_runtime_config.get_core_time(); - odl.index_in_tx = 0; - odl.tx_hash = tx_id; - odl.stopped = false; - odl.fee = 10000; - } - return true; -} -//---------------------------------------------------------------------------------------------------- void wallet2::build_escrow_release_templates(crypto::hash multisig_id, uint64_t fee, currency::transaction& tx_release_template, diff --git a/src/wallet/wallet2.h b/src/wallet/wallet2.h index e1fd1d63..47107893 100644 --- a/src/wallet/wallet2.h +++ b/src/wallet/wallet2.h @@ -698,7 +698,6 @@ namespace tools bool reset_password(const std::string& pass); bool is_password_valid(const std::string& pass); bool get_actual_offers(std::list& offers); - bool get_fake_offers(std::list& offers, uint64_t amount); bool process_contract_info(wallet_public::wallet_transfer_info& wti, const std::vector& decrypted_attach); bool handle_proposal(wallet_public::wallet_transfer_info& wti, const bc_services::proposal_body& prop); void accept_proposal(const crypto::hash& contract_id, uint64_t b_acceptance_fee, currency::transaction* p_acceptance_tx = nullptr);