aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2017-07-14Remove confusing MAX_BLOCK_BASE_SIZE.Gregory Maxwell
Some people keep thinking that MAX_BLOCK_BASE_SIZE is a separate size limit from the weight limit when it fact it is superfluous, and used in early tests before the witness data has been validated or just to compute worst case sizes. The size checks that use it would not behave any differently consensus wise if they were eliminated completely. Its correct value is not independently settable but is a function of the weight limit and weight formula. This patch just eliminates it and uses the scale factor as required to compute the worse case constants. It also moves the weight factor out of primitives into consensus, which is a more logical place for it.
2017-07-12Merge #10780: Simplify "!foo || (foo && bar)" as "!foo || bar"Pieter Wuille
1e3a3200a Simplify "!foo || (foo && bar)" as "!foo || bar" (practicalswift) Tree-SHA512: d5ce6d7a9f3741e7abe8542b840268aa683e276aac7587041d32385a4c1273e20c236bec7590e27540dde72defb3f879d4695822bb7bfdb092cc20d9aefa64c1
2017-07-12Merge #9804: Fixes subscript 0 (&var[0]) where should use (var.data()) instead.Pieter Wuille
30ac7688e Fix subscript[0] potential bugs in key.cpp (Jeremy Rubin) 4b1c0f2e2 Remove unnecessary branches in utilstrencodings string constructors. (Jeremy Rubin) e19db7b5a Fix subscript[0] in utilstrencodings.cpp (Jeremy Rubin) bc2e7fd98 Fix subscript[0] in streams.h (Jeremy Rubin) 4cac0d1e0 Fix subscript[0] in validation.cpp (Jeremy Rubin) ac658e55f Fix subscript[0] in torcontrol (Jeremy Rubin) b6856ebed Fix subscript[0] in netaddress.cpp (Jeremy Rubin) 361d95265 Fix subscript[0] in base58.cpp (Jeremy Rubin) 6896dbf16 Cleanup (safe, it was checked) subscript[0] in MurmurHash3 (and cleanup MurmurHash3 to be more clear). (Jeremy Rubin) 96f2119e6 Fix subscript[0] in compressor.cpp (Jeremy Rubin) 500710bd2 Fix 2 subscript[0] bugs in pubkey.cpp, and eliminate one extra size check (Jeremy Rubin) e0451e3e2 Fix subscript[0] bug in net.cpp if GetGroup returns a 0-sized vector (Jeremy Rubin) Tree-SHA512: 5b9103652cf8c615bd8f4f32b3573d291d6b67c39e0308ce00100bc6625f346e8e016b4c999f4f34f5c37ae059490a83c3b513deb21f838af785227d06e02362
2017-07-12Merge #10714: Avoid printing incorrect block indexing time due to ↵Pieter Wuille
uninitialized variable 959dd8781 Avoid printing incorrect block indexing time due to uninitialized variable (practicalswift) Tree-SHA512: a76e43c3ffa734ed5c7eadf363f345f268aa0e6ce775aba8f856fe3bbc82f240dc7c734c5ca3ac500a12eb41fae00623413e79f484d5acf809b6e400851d771d
2017-07-11Merge #10712: Add change output if necessary to reduce excess feeWladimir J. van der Laan
0f402b9 Fix rare edge case of paying too many fees when transaction has no change. (Alex Morcos) 253cd7e Only reserve key for scriptChange once in CreateTransaction (Alex Morcos) Pull request description: This is an alternative to #10333 See commit messages. The first commit is mostly code move, it just moves the change creation code out of the loop. @instagibbs Tree-SHA512: f16287ae0f0c6f09cf8b1f0db5880bb567ffa74a50898e3d1ef549ba592c6309ae1a9b251739f63a8bb622d48f03ce2dff9e7a57a6bac4afb4b95b0a86613ea8
2017-07-11Fix rare edge case of paying too many fees when transaction has no change.Alex Morcos
Due to the iterative process of selecting new coins in each loop a new fee is calculated that needs to be met each time. In the typical case if the most recent iteration of the loop produced a much smaller transaction and we have now gathered inputs with too many fees, we can just reduce the change. However in the case where there is no change output, it is possible to end up with a transaction which drastically overpays fees. This commit addresses that case, by creating a change output if the overpayment is large enough to support it, this is accomplished by rerunning the transaction creation loop without selecting new coins. Thanks to instagibbs for working on this as well
2017-07-11Only reserve key for scriptChange once in CreateTransactionAlex Morcos
This does not affect behavior but allows us to have access to an output to scriptChange even if we currently do not have change in the transaction.
2017-07-11Merge #10786: Add PR description to merge commit in github-merge.pyWladimir J. van der Laan
475c08c Add PR description to merge commit in github-merge.py (Pieter Wuille) Pull request description: There is often some context given in PR descriptions that is missing from commits, and it may be worthwhile to retain that information in our history in git. This PR adds that information to the merge commit when created through `github-merge.py`. We should also encourage people to provide as much information as possible in the PR commits themselves, but I believe that is an orthogonal issue. Individual commits don't need to have a description of the overall goal of a PR. Tree-SHA512: cbae46ec24ce911744e11a07e5d51895d3acc79659db306d8124304ef8e422bba99001ee2a741b08c92a5eb39d9c3f6b723622b20d6553ca5cfa0a8de866194c
2017-07-11Merge #10543: Change API to estimaterawfeeWladimir J. van der Laan
5e3b7b5 Improve error reporting for estimaterawfee (Alex Morcos) 1fafd70 Add function to report highest estimate target tracked per horizon (Alex Morcos) 9c85b91 Change API to estimaterawfee (Alex Morcos) Tree-SHA512: e624c6e7967e9e48abe49f5818bd674e5710e571cc093029d2f90d39fdfba3c1f30e83bf89f6dce97052b59a7d9636a64642ccfb26effd149c417d0afbed0c0b
2017-07-11Merge #10651: Verify binaries from bitcoincore.org and bitcoin.orgWladimir J. van der Laan
6270d62 Verify binaries from bitcoincore.org and bitcoin.org (Matt Corallo) Tree-SHA512: 39e99ce9be3e7c99d17b296749c0af53c867039bc95fd5b03572593c812817decea75e7296bb66e89ba460518210d84114b7bdc22465df621340319b47bd4303
2017-07-11Merge #10792: Replace MAX_OPCODE for OP_NOP10.Wladimir J. van der Laan
c8e29d7 Replace MAX_OPCODE for OP_NOP10. (Mark Friedenbach) Tree-SHA512: f6a4129db24fe3feb044acaec3b94194cc4fa909de3d0a45a664b32f886a7d8ab997c9cb6ff0870c4aee66d8e038cf0453dbbb518316829d15e84da9882f3e69
2017-07-11Merge #10190: [tests] mining functional tests (including regression test for ↵Wladimir J. van der Laan
submitblock) 11ba8e9 [tests] rename getblocktemplate_proposals.py to mining.py (John Newbery) b29dd41 [tests] add test for submit block (John Newbery) 9bf0d80 [tests] run successful test in getblocktemplate first (John Newbery) 82dc597 [tests] don't build blocks manually in getblocktemplate test (John Newbery) f82c709 [tests] clarify assertions in getblocktemplate test (John Newbery) 66c570a [tests] Don't build the coinbase manually in getblocktemplate test (John Newbery) 38b38cd [tests] getblocktemplate_proposals.py: add logging (John Newbery) 0a3a5ff [tests] Fix flake8 warnings in getblocktemplate tests (John Newbery) 32cffe6 [tests] Fix import order in getblocktemplate test (John Newbery) Tree-SHA512: a51a57314fa1c4c4b8a7896492ec6e677b6bed12387060def34a62e9dfbee7961f71bb5553fbd70028be61ae32eccf13fd255fa9651f908e9a5e64c28f43f00e
2017-07-11Merge #10589: More economical fee estimates for RBF and RPC options to controlWladimir J. van der Laan
f135923 Add RPC options for RBF, confirmation target, and conservative fee estimation. (Alex Morcos) f0bf33d Change default fee estimation mode. (Alex Morcos) e0738e3 remove default argument from estimateSmartFee (Alex Morcos) d507c30 Introduce a fee estimate mode. (Alex Morcos) cfaef69 remove default argument from GetMinimumFee (Alex Morcos) Tree-SHA512: 49c3a49a6893790a7e8b4e93a48f123dd5307af26c2017800683b76b4df8fc904ba73402917878676242c7440e3e04288d0c1ff3c2c907418724efc03cedab50
2017-07-11Merge #10676: document script-based return fields for validateaddressWladimir J. van der Laan
f2f1d0a document script-based return fields for validateaddress (Gregory Sanders) Tree-SHA512: 3310bb82b63ef20e46dd7ebcc9e15828cc7b6767ef19ddd869eeb5e4ee5b31ee307d21a44a9c81dbfe9d031bd48219e3ee1d330fc7b343d63d5365b68639c062
2017-07-11Replace MAX_OPCODE for OP_NOP10.Mark Friedenbach
That OP_NOP10 is the last executable opcode is a bit of a obscure trivia, and the MAX_OPCODE constant already exists. This merely standardizes use of MAX_OPCODE over OP_NOP10 where it makes sense and is more clear.
2017-07-11Merge #10179: Give CValidationInterface Support for calling notifications on ↵Wladimir J. van der Laan
the CScheduler Thread 1f668b6 Expose if CScheduler is being serviced, assert its not in EmptyQueue (Matt Corallo) 3192975 Flush CValidationInterface callbacks prior to destruction (Matt Corallo) 08096bb Support more than one CScheduler thread for serial clients (Matt Corallo) 2fbf2db Add default arg to CScheduler to schedule() a callback now (Matt Corallo) cda1429 Give CMainSignals a reference to the global scheduler (Matt Corallo) 3a19fed Make ValidationInterface signals-type-agnostic (Matt Corallo) ff6a834 Use TestingSetup to DRY qt rpcnestedtests (Matt Corallo) Tree-SHA512: fab91e34e30b080ed4d0a6d8c1214910e383c45440676e37be61d0bde6ae98d61e8903d22b846e95ba4e73a6ce788798350266feba246d8a2ab357e8523e4ac5
2017-07-10Expose if CScheduler is being serviced, assert its not in EmptyQueueMatt Corallo
2017-07-10Improve error reporting for estimaterawfeeAlex Morcos
2017-07-10Add function to report highest estimate target tracked per horizonAlex Morcos
2017-07-10Change API to estimaterawfeeAlex Morcos
Report results for all 3 possible time horizons instead of specifying time horizon as an argument.
2017-07-10Add PR description to merge commit in github-merge.pyPieter Wuille
2017-07-10Add RPC options for RBF, confirmation target, and conservative fee estimation.Alex Morcos
Add support for setting each of these attributes on a per RPC call basis to sendtoaddress, sendmany, fundrawtransaction (already had RBF), and bumpfee (already had RBF and conf target).
2017-07-10Merge #10747: [rpc] fix verbose argument for getblock in bitcoin-cliWladimir J. van der Laan
58e9864 [rpc] fix verbose argument for getblock in bitcoin-cli (John Newbery) Tree-SHA512: 7f176e1ddd9f3f7722ea0d268549629567ecf0c30bebf368824997566df0bfa01d31cf761abc9ca355e48c0bf0cb06d49d15a02b858999fcb7472dc7df2fbbf2
2017-07-09Simplify "!foo || (foo && bar)" as "!foo || bar"practicalswift
2017-07-08Fix subscript[0] potential bugs in key.cppJeremy Rubin
2017-07-08Remove unnecessary branches in utilstrencodings string constructors.Jeremy Rubin
2017-07-08Fix subscript[0] in utilstrencodings.cppJeremy Rubin
2017-07-08Fix subscript[0] in streams.hJeremy Rubin
2017-07-08Fix subscript[0] in validation.cppJeremy Rubin
2017-07-08Fix subscript[0] in torcontrolJeremy Rubin
2017-07-08Fix subscript[0] in netaddress.cppJeremy Rubin
2017-07-08Fix subscript[0] in base58.cppJeremy Rubin
2017-07-08Cleanup (safe, it was checked) subscript[0] in MurmurHash3 (and cleanup ↵Jeremy Rubin
MurmurHash3 to be more clear).
2017-07-08Fix subscript[0] in compressor.cppJeremy Rubin
2017-07-08Fix 2 subscript[0] bugs in pubkey.cpp, and eliminate one extra size checkJeremy Rubin
2017-07-08Fix subscript[0] bug in net.cpp if GetGroup returns a 0-sized vectorJeremy Rubin
2017-07-07Flush CValidationInterface callbacks prior to destructionMatt Corallo
Note that the CScheduler thread cant be running at this point, it has already been stopped with the rest of the init threadgroup. Thus, just calling any remaining loose callbacks during Shutdown() is sane.
2017-07-07Support more than one CScheduler thread for serial clientsMatt Corallo
This will be used by CValidationInterface soon. This requires a bit of work as we need to ensure that most of our callbacks happen in-order (to avoid synchronization issues in wallet) - we keep our own internal queue and push things onto it, scheduling a queue-draining function immediately upon new callbacks.
2017-07-07Add default arg to CScheduler to schedule() a callback nowMatt Corallo
2017-07-07Give CMainSignals a reference to the global schedulerMatt Corallo
...so that it can run some signals in the background later
2017-07-07Merge #10759: Fix multi_rpc test for hosts that dont default to utf8MarcoFalke
bc7d103 Fix multi_rpc test for hosts that dont default to utf8 (Matt Corallo) Tree-SHA512: 7644b1f50d4010a08aed5d1c87ab7326af9c109ac05dfbfc4bb6d5a19ace7997ef9cdd64d4301072f1106225de6d3aacccb17f53043b55ba61f5723c2b65af30
2017-07-07Merge #10761: [tests] fix replace_by_fee.pyMarcoFalke
301fd51 [tests] fix replace_by_fee.py (John Newbery) Tree-SHA512: 716ae20ab1f0a5fcb38160cb3a03f83f950f3020e3ed1ad0acf94d7aff71d34ab13c57d2bff83d3afcad206d98e8d1617c1a6b58bae47e2ed28f1f247ca8187d
2017-07-07Merge #10744: Use method name via __func__ macroMarcoFalke
9bbf600 Use method name from __func__ macro (darksh1ne) Tree-SHA512: da6d0714f458b538189bbc2b53252ba353dcc1ef15fa780cb7f690a034b58ab0dbaa3a89f83f044c746241ee265a70fc092449f1cc7be4f190775423fbca5fc5
2017-07-07[tests] fix replace_by_fee.pyJohn Newbery
fb915d5b183adb915c72bb11c6f3b418841e3512 changed the optIntoRbf field in fundrawtransaction to replaceable. This commit fixes up replace-by-fee.py to use the new option name.
2017-07-06Change default fee estimation mode.Alex Morcos
Fee estimates will default to be non-conservative if the transaction in question is opt-in-RBF.
2017-07-06remove default argument from estimateSmartFeeAlex Morcos
2017-07-06Introduce a fee estimate mode.Alex Morcos
GetMinimumFee now passes the conservative argument into estimateSmartFee. Call CalculateEstimateType(mode) before calling GetMinimumFee or estimateSmartFee to determine the value of this argument. CCoinControl can now be used to control this mode.
2017-07-06remove default argument from GetMinimumFeeAlex Morcos
2017-07-06Fix multi_rpc test for hosts that dont default to utf8Matt Corallo
Otherwise the utf8 written to bitcoin.conf throws an exception when read from get_auth_cookie
2017-07-06Merge #10698: Be consistent in calling transactions "replaceable" for Opt-In RBFWladimir J. van der Laan
73c942e Use "replaceable" instead of "rbfoptin" in bitcoin-tx. (Matt Corallo) fb915d5 Use "replaceable" instead of "optIntoRbf" in fundrawtransaction. (Matt Corallo) 928c681 Use "replaceable" instead of "optintorbf" in createrawtransaction. (Matt Corallo) Tree-SHA512: 8922451c00abb63aaa08b4a9e314e89c22233b32f207259fbc25367f7d5b67efbaccc7e2a4958c18611ad498da302296242860c7be965a0e996dcde3e89efa07