Commit graph

5 commits

Author SHA1 Message Date
Roy Lee
45627c7a6a [lbry] rename btcd to lbcd
Co-authored-by: Brannon King <countprimes@gmail.com>
2022-05-23 23:53:30 -07:00
David de Kloet
c5751b75a9 wire: Treat NetAddress more like immutable
Replace assignments to individual fields of wire.NetAddress with
creating the entire object at once, as one would do if the type was
immutable.

In some places this replaces the creation of a NetAddress with a
high-precision timestamp with a call to a 'constructor' that converts
the timestamp to single second precision. For consistency, the tests
have also been changed to use single-precision timestamps.

Lastly, the number of allocations in readNetAddress have been reduced by
reading the services directly into the NetAddress instead of first into
a temporary variable.
2016-12-06 20:48:02 +01:00
Dave Collins
aa53c14a19
addrmgr/btcd: Updates for staticcheck results.
This makes two modifications based on the results of staticcheck.

The first is to use a simplified zero value for the time in the addrmgr
package tests.

The second is check any errors when opening a directory while attempting
to perform old version upgrades.
2016-11-03 11:29:08 -05:00
Dave Collins
6e402deb35 Relicense to the btcsuite developers.
This commit relicenses all code in this repository to the btcsuite
developers.
2015-05-01 12:00:56 -05:00
Daniel Krawisz
c0b57def7f Added tests for addrmgr.KnownAddress
Adjusted tests in response to redefinition of KnownAddress.chance
2015-04-21 19:10:39 -05:00