aboutsummaryrefslogtreecommitdiff
path: root/src/wallet
AgeCommit message (Collapse)Author
2017-04-24Merge #9951: Wallet database handling abstractions/simplificationsWladimir J. van der Laan
911a480 wallet: Add comment describing the various classes in walletdb.h (Wladimir J. van der Laan) 69d2e9b wallet: Make IsDummy private in CWalletDBWrapper (Wladimir J. van der Laan) 3323281 wallet: CWalletDB CDB composition not inheritance (Wladimir J. van der Laan) be9e1a9 wallet: Reduce references to global bitdb environment (Wladimir J. van der Laan) 071c955 wallet: Get rid of fFileBacked (Wladimir J. van der Laan) 71afe3c wallet: Introduce database handle wrapper (Wladimir J. van der Laan) Tree-SHA512: e4e72953c61a2f6995d609a32f8ed8e18cab9a92bc9e193d46a1d1f06d9daa5c6da6fce2867d4e3ba4fc0439141901a3d35f246486f0fa8f59587786379dfcbd
2017-04-24Merge #9792: FastRandomContext improvements and switch to ChaCha20Wladimir J. van der Laan
4fd2d2f Add a FastRandomContext::randrange and use it (Pieter Wuille) 1632922 Switch FastRandomContext to ChaCha20 (Pieter Wuille) e04326f Add ChaCha20 (Pieter Wuille) 663fbae FastRandom benchmark (Pieter Wuille) c21cbe6 Introduce FastRandomContext::randbool() (Pieter Wuille) Tree-SHA512: 7fff61e3f6d6dc6ac846ca643d877b377db609646dd401a0e8f50b052c6b9bcd2f5fc34de6bbf28f04afd1724f6279ee163ead5f37d724fb782a00239f35db1d
2017-04-21wallet: Add comment describing the various classes in walletdb.hWladimir J. van der Laan
2017-04-20Merge #10181: Include cleanupWladimir J. van der Laan
1c897fc Missing includes (Jorge Timón) a1fd450 Trivial: Remove unneeded includes from .h: (Jorge Timón) Tree-SHA512: ada3e62cc2435e58172a88b380be371b717a05725956c15e5493b6e19fe2903e5e6e43fd22dc24699333a0e8a0c7b42eb1ae61b41cb4ba82495be18e2d4ef3c6
2017-04-20Merge #9942: Refactor CBlockPolicyEstimatorWladimir J. van der Laan
68af651 MOVEONLY: move TxConfirmStats to cpp (Alex Morcos) 2332f19 Initialize TxConfirmStats in constructor (Alex Morcos) 5ba81e5 Read and Write fee estimate file directly from CBlockPolicyEstimator (Alex Morcos) 14e10aa Call estimate(Smart)Fee directly from CBlockPolicyEstimator (Alex Morcos) dbb9e36 Give CBlockPolicyEstimator it's own lock (Alex Morcos) f6187d6 Make processBlockTx private. (Alex Morcos) ae7327b Make feeEstimator its own global instance of CBlockPolicyEstimator (Alex Morcos) Tree-SHA512: dbf3bd2b30822e609a35f3da519b62d23f8a50e564750695ddebd08553b4c01874ae3e07d792c6cc78cc377d2db33b951ffedc46ac7edaf5793f9ebb931713af
2017-04-20wallet: Make IsDummy private in CWalletDBWrapperWladimir J. van der Laan
This is only for use in the low-level functions, and CDB is already a friend class.
2017-04-20wallet: CWalletDB CDB composition not inheritanceWladimir J. van der Laan
CWalletDB now contains a CDB instead of inheriting from it. This makes it easier to replace the internal transaction with a different database, without leaking through internals.
2017-04-20wallet: Reduce references to global bitdb environmentWladimir J. van der Laan
2017-04-20wallet: Get rid of fFileBackedWladimir J. van der Laan
Instead, CWalletDB() with a dummy handle will just give you a no-op database in which writes always succeeds and reads always fail. CDB already had functionality for this, so just use that.
2017-04-20wallet: Introduce database handle wrapperWladimir J. van der Laan
Abstract database handle from explicit strFilename into CWalletDBWrapper. Also move CWallet::Backup to db.cpp - as it deals with representation details this is a database specific operation.
2017-04-19Merge #9827: Improve ScanForWalletTransactions return valueWladimir J. van der Laan
30abce7 Improve ScanForWalletTransactions return value (Russell Yanofsky) Tree-SHA512: 195028553b103052a842b6a37e67410118a20c32475b80f7fd22d6d8622f92eca1c2d84f291d1092bef2161d3187d91052799b533e1e265b7613d51955490b8d
2017-04-19Merge #10221: Stop treating coinbase outputs differently in GUI: show them ↵Jonas Schnelli
at 1conf 608bbcc [qt] Stop treating coinbase outputs differently: show them at 1conf (Matt Corallo) Tree-SHA512: 62ba10520da8b83cf8e97c86dec3ccdcca8b7bfae0174d1a4099d33aa5d11933cc7c248394bf67c2b105211cf7931955816c741957832e703211030c7f4f002f
2017-04-19Merge #10226: wallet: Use boost to more portably ensure -wallet specifies ↵Wladimir J. van der Laan
only a filename a4186dd wallet: Use boost to more portably ensure -wallet specifies only a filename (Luke Dashjr) Tree-SHA512: 6dfde31fa599638e5ec76489363e2fed97403be3e5762e4560dfc6ac261ce169a92b5a1b92bb34a893cc898e6073c81f74f49528e8df07e86273ddb37dd1ce80
2017-04-18wallet: Use boost to more portably ensure -wallet specifies only a filenameLuke Dashjr
2017-04-18Merge #10208: [wallet] Rescan abortabilityWladimir J. van der Laan
9141622 [rpc] Add abortrescan command to RPC interface. (Kalle Alm) 75a08e7 [wallet] Add support for aborting wallet transaction rescans. (Kalle Alm) Tree-SHA512: 18545a1dc48c6dc112993f971f3adc7c0341fa621186c6d70bef1052e1d127ca116c5769595d721a209d502ca2019f2ad33876fe35d2b17216393404607a6c76
2017-04-18[rpc] Add abortrescan command to RPC interface.Kalle Alm
2017-04-17Merge #10207: Clarify importprivkey help text ... example of blank label ↵MarcoFalke
without rescan c9e31c3 Clarify importprivkey help text with example of blank label without rescan Occasionally I waste a lot of time not remembering that the second parameter to importprivkey must be blank if you intend to stop rescan with "false" as the third parameter. (Warren Togami) Tree-SHA512: 23781e1d6fd59a9d06d6e12ad10e8ed6641947b3e4a1f66c8fdb5d44cbd8f291e8f2a5e686aa9f9ba5e4bab8ca688caa17244e837f651546055ddf7cc8e7df8f
2017-04-17[wallet] Add support for aborting wallet transaction rescans.Kalle Alm
2017-04-17[qt] Stop treating coinbase outputs differently: show them at 1confMatt Corallo
2017-04-17Merge #10178: Remove CValidationInterface::UpdatedTransactionWladimir J. van der Laan
9fececb Remove CValidationInterface::UpdatedTransaction (Matt Corallo) d89f8ad Make DisconnectBlock and ConnectBlock static in validation.cpp (Matt Corallo) Tree-SHA512: 146597b538c09c1e8071f4f88ffeba0645c6816f86030b142174bd298cc18ae09a400e6ca8de04d091e37b635f99f4c05982c09e6729691eb8ca6b8439ab97ca
2017-04-13Clarify importprivkey help text with example of blank label without rescanWarren Togami
Occasionally I waste a lot of time not remembering that the second parameter to importprivkey must be blank if you intend to stop rescan with "false" as the third parameter.
2017-04-13Remove CValidationInterface::UpdatedTransactionMatt Corallo
This removes another callback from block connection logic, making it easier to reason about the wallet-RPCs-returns-stale-info issue. UpdatedTransaction was previously used by the GUI to display coinbase transactions only after they have a block built on top of them. This worked fine for in most cases, but only worked due to a corner case if the user received a coinbase payout in a block immediately prior to restart. In that case, the normal process of caching the most recent coinbase transaction's hash would not work, and instead it would only work because of the on-load -checkblocks calling DisconnectBlock and ConnectBlock on the current tip. In order to make this more robust, a full mapWallet loop after the first block which is connected after restart was added.
2017-04-13Merge #10165: [Wallet] Refactoring by using CInputCoin instead of std::pairWladimir J. van der Laan
c37e32a [Wallet] Prevent CInputCoin to be in a null state (NicolasDorier) f597dcb [Wallet] Simplify code using CInputCoin (NicolasDorier) e78bc45 [Wallet] Decouple CInputCoin from CWalletTx (NicolasDorier) fd44ac1 [Wallet] Rename std::pair<const CWalletTx*, unsigned int> to CInputCoin (NicolasDorier) Tree-SHA512: d24361fc514a0566bce1c3953d766dfe4fece79c549cb4db2600695a4ce08e85caa61b7717812618e523a2f2a1669877dad2752ed079e2ed2d27249f9bc8590e
2017-04-13[Wallet] Prevent CInputCoin to be in a null stateNicolasDorier
2017-04-13[Wallet] Simplify code using CInputCoinNicolasDorier
2017-04-13[Wallet] Decouple CInputCoin from CWalletTxNicolasDorier
2017-04-13Missing includesJorge Timón
2017-04-11Make CWallet::SyncTransactions() interface friendlierJohn Newbery
2017-04-11AddToWalletIfInvolvingMe should test pIndex, not posInBlockJohn Newbery
2017-04-10Merge #9725: CValidationInterface CleanupsWladimir J. van der Laan
b1a6d4c Take a CTransactionRef in AddToWalletIfInvolvingMe to avoid a copy (Matt Corallo) 1c95e2f Use std::shared_ptr instead of boost::shared_ptr in ScriptForMining (Matt Corallo) 91f1e6c Remove dead-code tracking of requests for blocks we generated (Matt Corallo) acad82f Add override to functions using CValidationInterface methods (Matt Corallo) e6d5e6c Hold cs_wallet for whole block [dis]connection processing (Matt Corallo) 461e49f SyncTransaction->TxAddedToMempool/BlockConnected/Disconnected (Matt Corallo) f404334 Handle SyncTransaction in ActivateBestChain instead of ConnectTrace (Matt Corallo) a147687 Keep conflictedTxs in ConnectTrace per-block (Matt Corallo) d3167ba Handle conflicted transactions directly in ConnectTrace (Matt Corallo) 29e6e23 Make ConnectTrace::blocksConnected private, hide behind accessors (Matt Corallo) 822000c Add pblock to connectTrace at the end of ConnectTip, not start (Matt Corallo) f5e9a01 Include missing #include in zmqnotificationinterface.h (Matt Corallo) Tree-SHA512: 8893d47559da3b28d2ef7359768547cba8a4b43b6f891d80f5848f995a84b1517bfb0f706fdc8cd43f09a1350349eb440d9724a59363ab517dfcc4fcb31b2018
2017-04-10Call estimate(Smart)Fee directly from CBlockPolicyEstimatorAlex Morcos
2017-04-10Merge #10164: Wallet: reduce excess logic InMempool()Wladimir J. van der Laan
3491476 Wallet: reduce excess logic InMemPool() (Kewde) Tree-SHA512: 554ea2827cfd482281fae0ba3d0a7989dbfeace98a35462732ea08bf3cc94c9564a9ea8ca2fa9905b963367d0b56a490ef0d83ceb6731c8f06187de98b6a7f23
2017-04-08[Wallet] Rename std::pair<const CWalletTx*, unsigned int> to CInputCoinNicolasDorier
2017-04-07[trivial] Fix typo ("improssible" → "impossible")practicalswift
2017-04-07Merge #9681: Refactor Bumpfee, move core functionality to CWalletWladimir J. van der Laan
5f59d3e Improve CFeeBumper interface, add comments, make use of std::move (Jonas Schnelli) 0df22ed Cancel feebump is vErrors is not empty (Jonas Schnelli) 44cabe6 Use static calls for GetRequiredFee and GetMinimumFee, remove make_pair from emplace_back (Jonas Schnelli) bb78c15 Restore CalculateMaximumSignedTxSize function signature (Jonas Schnelli) 51ea44f Use "return false" instead assert() in CWallet::SignTransaction (Jonas Schnelli) bcc72cc Directly abort execution in FeeBumper::commit if wallet or tx is not available (Jonas Schnelli) 2718db0 Restore invalid fee check (must be > 0) (Jonas Schnelli) 0337a39 Refactor Bumpfee core functionality (Jonas Schnelli) d1a95e8 Bumpfee move request parameter interaction to the top (Jonas Schnelli) Tree-SHA512: 0e6d1f3322ed671fa2291e59ac9556ce4646bc78267edc6eedc46b0014b7b08aa83c30315358b911d82898847d4845634a18b67e253a7b699dcc852eb2652c07
2017-04-07Take a CTransactionRef in AddToWalletIfInvolvingMe to avoid a copyMatt Corallo
2017-04-07Use std::shared_ptr instead of boost::shared_ptr in ScriptForMiningMatt Corallo
2017-04-07Remove dead-code tracking of requests for blocks we generatedMatt Corallo
2017-04-07Hold cs_wallet for whole block [dis]connection processingMatt Corallo
This simplifies fixing the wallet-returns-stale-info issue as we now hold cs_wallet across an entire block instead of only per-tx.
2017-04-07SyncTransaction->TxAddedToMempool/BlockConnected/DisconnectedMatt Corallo
This simplifies fixing the wallet-returns-stale-info issue as we can now hold cs_wallet across an entire block instead of only per-tx (though we only actually do so in the next commit). This change also removes the NOT_IN_BLOCK constant in favor of only passing the CBlockIndex* parameter to SyncTransactions when a new block is being connected, instead of also when a block is being disconnected. This change adds a parameter to BlockConnectedDisconnected which lists the transactions which were removed from mempool due to confliction as a result of this operation. While its somewhat of a shame to make block-validation-logic generate a list of mempool changes to be included in its generated callbacks, fixing this isnt too hard. Further in this change-set, CValidationInterface starts listening to mempool directly, placing it in the middle and giving it a bit of logic to know how to route notifications from block-validation, mempool, etc (though not listening for conflicted-removals yet).
2017-04-07Wallet: reduce excess logic InMemPool()Kewde
removed the excess logic, return directly instead of using if-statement.
2017-04-03Use fsbridge for fopen and freopenWladimir J. van der Laan
Abstracts away how a path is opened to a `FILE*`. Reduces the number of places where path is converted to a string for anything else but printing.
2017-04-03Replace uses of boost::filesystem with fsWladimir J. van der Laan
Step two in abstracting away boost::filesystem. To repeat this, simply run: ``` git ls-files \*.cpp \*.h | xargs sed -i 's/boost::filesystem/fs/g' ```
2017-04-03Replace includes of boost/filesystem.h with fs.hWladimir J. van der Laan
This is step one in abstracting the use of boost::filesystem.
2017-04-02Improve CFeeBumper interface, add comments, make use of std::moveJonas Schnelli
2017-04-02Cancel feebump is vErrors is not emptyJonas Schnelli
2017-04-02Use static calls for GetRequiredFee and GetMinimumFee, remove make_pair from ↵Jonas Schnelli
emplace_back
2017-04-02Restore CalculateMaximumSignedTxSize function signatureJonas Schnelli
2017-04-02Use "return false" instead assert() in CWallet::SignTransactionJonas Schnelli
2017-04-02Directly abort execution in FeeBumper::commit if wallet or tx is not availableJonas Schnelli