Commit Graph

3530 Commits

Author SHA1 Message Date
Federico Gimenez
cf453789c8 update go version for example test run in readme 2017-12-04 13:05:15 -06:00
David Hill
b13f5dfbda travis: add ineffassign linter 2017-12-01 09:14:04 -05:00
Donald Adu-Poku
2d0d42401c txscript: Correct nulldata standardness check. 2017-12-01 01:24:17 +00:00
Dave Collins
084e903479
Sync upstream through 07e1e30. 2017-11-30 17:20:41 -06:00
Maninder Lall
ad33b0e3d3 multi: Handle detected data race conditions
All instances of data race are related to accessing
KnownAddress elements, except for peer.go where its
related to closure.

Following are the changes:
- Add KnownAddress.mtx (sync.Mutex) and used same to
 sync access points
- For peer.go, pass local copy to the closure
2017-12-01 01:54:41 +05:30
Donald Adu-Poku
66bf35020a rpc: Add localaddr and relaytxes to getpeerinfo 2017-11-29 22:21:17 +00:00
jolan
664ccfcc63 rpcserver: skip generating certs when nolisten set 2017-11-28 12:47:26 -06:00
Dave Collins
c75eb02ae7
Sync upstream through 403aaf5. 2017-11-28 12:14:01 -06:00
Donald Adu-Poku
06468ffcfa rpcserver: avoid nested decodescript p2sh addrs 2017-11-28 17:46:41 +00:00
Josh Rickmar
238bef1c80 txscript: Require SHA256 secret hashes for atomic swaps 2017-11-28 10:03:42 -05:00
detailyang
aed4179709 doc: tiny fix url (#928) 2017-11-27 08:35:31 -06:00
Alex Yocom-Piatt
d4172fb0eb Bump for v1.1.2 2017-11-20 18:53:16 -06:00
jolan
520214505e chaincfg: update checkpoints for 1.1.2 release 2017-11-20 18:53:00 -06:00
David Hill
20686cd775 travis: add gosimple linter 2017-11-20 18:49:55 -06:00
Samarth Hattangady
4f023d7260 bloom: Fix link in README.
The link in the dcrd/bloom/README.md page led to a 'Not Found' page on
GoDoc. The link has now been changed.
2017-11-21 00:40:56 +05:30
Josh Rickmar
e145193483 peer: Avoid goroutine leaking during handshake timeout. 2017-11-03 12:54:58 -04:00
Matheus Degiovani
2310b4c096 stake: Add IsStakeSubmission (#907)
* Add IsStakeSubmissionTxOut test

* Simplify test

* Remove mtx argument

* Fix formatting

* Fix comment
2017-11-01 13:36:34 -04:00
detailyang
3f3174c987 rpcserver: nil pointer dereference when submit orphan block 2017-10-26 21:21:50 +08:00
David Hill
f903c700a4 blockchain: remove unused file 2017-10-17 17:52:21 -05:00
David Hill
6df741c633 blockchain: removed unused funcs and vars 2017-10-17 17:52:21 -05:00
shweini
ad08e6ab30 multi: Add NoSplitTransaction to purchaseticket. 2017-10-17 17:46:01 -05:00
David Hill
d27429061b rpcserver: check for error in getwork request. (#898)
This checks the error for UpdateBlockTime.
2017-10-13 14:23:11 -04:00
David Hill
ca452564b3 Use upstream jrick/bitset (#899)
... since no local changes exist.
2017-10-13 09:47:26 -04:00
David Hill
7b9c4fa09c tests: make lockfile test work locally (#894) 2017-10-12 15:24:04 -04:00
David Hill
f586e66427 bloom: workaround go vet issue in example (#895) 2017-10-12 14:43:22 -04:00
Josh Rickmar
65001cd49e hdkeychain: Move to github.com/decred/dcrd/hdkeychain
This change moves the hdkeychain package outside of the dcrutil
directory into its own top-level package.  This change is being made
since hdkeychain only depends on dcrutil's address code, and if the
rpctest integration tests are ever moved outside of the dcrd repo,
hdkeychain will no longer be required to remain in dcrd to avoid a
cyclic dependency.
2017-10-12 08:31:54 -05:00
Nicola Larosa
29616d9d28 bloom: Add missing import to examples. 2017-10-12 07:06:55 -05:00
Dave Collins
83dd384ce7
hdkeychain: Work around go vet issue with examples. 2017-10-11 22:08:33 -05:00
Josh Rickmar
6842aa006d Merge remaining dcrutil code into a dcrd package.
This merge commit adds the following code from the
github.com/decred/dcrutil package into a new
github.com/decred/dcrd/dcrutil package:

* Address handling
* Amount type
* AppDataDir func
* bitflags functions
* Block wrapper type
* Hash160 func
* Tx wrapper type
* WIF type

as well as all tests for this code.

The old github.com/decred/dcrutil/hdkeychain package has also been
merged and moved to github.com/decred/dcrd/dcrutil/hdkeychain.

dcrd packages have been updated to use the new packages and the dep
files have been updated for this change.
2017-10-11 22:06:36 -04:00
Josh Rickmar
8564843206 Import dcrutil repo under dcrutil directory. 2017-10-11 21:29:08 -04:00
David Hill
f1ca8cbd48 travis: test Gopkg.lock (#889) 2017-10-11 18:45:23 -04:00
Dave Collins
80861cacf4
rpcclient: Remove docker info from README.md.
This information no longer applies since the rpcclient was merged into
dcrd proper.
2017-10-11 14:53:36 -05:00
Dave Collins
9db06d4a68
Improve gitignore.
This syncs the .gitignore file with the upstream btcd project since it
shouldn't have been completely changed to begin with.  While here, it
also adds the Decred-specific binaries.
2017-10-11 14:52:00 -05:00
Josh Rickmar
c394c7bd19 Copy github.com/decred/dcrutil/bloom to bloom package.
Use this new bloom package rather than relying on the bloom package
from the dcrutil repo.

Some minor source code changes have been made to conform to the dcrd
linter requirements.
2017-10-11 15:36:57 -04:00
Dave Collins
a4d4179143
rpcclient: Merge dcrrpcclient repo. 2017-10-11 14:25:50 -05:00
Dave Collins
db84c7d0e0
Import dcrrpcclient repo into rpcclient directory.
This commit contains the entire dcrrpcclient repository along with
several changes needed to move all of the files into the rpcclient
directory in order to prepare it for merging.  This does NOT update dcrd
or any of the other packages to use the new location as that will be
done separately.

- All import paths in the old dcrrpcclient files have been changed to
  the new location
- All references to dcrrpcclient as the package name have been changed to
  rpcclient
2017-10-11 14:22:32 -05:00
David Hill
50c2884646 certgen: Add doc.go and README.md (#883) 2017-10-11 11:32:50 -04:00
David Hill
20ae0c1d6d dep: sync third-party deps 2017-10-10 18:30:47 -05:00
Josh Rickmar
27981a5a7d Move self signed certificate code into certgen package.
Use this package instead of relying on dcrutil certificate generation
functions.
2017-10-10 17:23:38 -04:00
David Hill
81e3f0983d gometalinter: run on subpkgs too (#878) 2017-10-10 17:20:40 -04:00
Josh Rickmar
ad851fbca8 Use new github.com/decred/base58 package. 2017-10-10 15:45:53 -04:00
Dave Collins
9a448b7c17
coinset: Remove package.
This removes the entire coinset package since it is not used by anything
and, even if something similar to it were desired, it's only related
specifically to wallet functionality in terms of coin selection so
therefore it really should go in the wallet repo.

This is part of an overall effort to rework the layout of the dcrutil
repo to remove unused code and cyclic dependencies.
2017-10-10 12:31:55 -05:00
David Hill
343df217cb Drop glide, use dep.
This updates the third-party deps as well.
2017-10-09 17:49:38 -04:00
David Hill
b7a37a3ca2 gofmt 2017-10-09 17:01:46 -04:00
Josh Rickmar
56d3c92e1a Use context for request-scoped cancellation during Connect. 2017-10-09 13:03:15 -04:00
Jason Zavaglia
65cd08cc75 blockchain.stake: ticket expiry perf improvement.
Change tickettreap to allow for efficient queries by min blockheight,
allowing for O(1) ticket expiry.

This allows for a very significant performance increase as previously
the same query required an iteration of 40,000 or so items while
processing each block.

Remove tickettreap.Mutable - it is not used, and it is difficult to
maintain with the other changes made to the treapNode class used by
Immutable.
2017-10-04 22:55:43 -05:00
Jason Zavaglia
4cbd3b738d blockchain.stake: treap index perf improvement.
Fix O(n) lookups-by-position into being O(ln n) in liveTickets.
This reduces the time to handle a new block by around a third.

Update memory-usage calculations to be more accurate, and have
extra testing.
2017-10-04 22:55:43 -05:00
Donald Adu-Poku
ebee51fbcb config: add --nofilelogging option. 2017-10-04 14:44:13 -05:00
Jonathan Chappelow
1eef90fb73 rpcserver: Fix empty ssgen verbose results. 2017-10-04 04:53:56 -05:00
David Hill
efe7aaf4a0 Drop glide, use dep. (#92) 2017-09-28 16:11:01 -04:00