diff options
| author | Marcos Mayorga <[email protected]> | 2017-04-28 09:03:51 +0100 |
|---|---|---|
| committer | Marcos Mayorga <[email protected]> | 2017-04-28 09:33:34 +0100 |
| commit | 4fbae77929e6344bc49ab60af10a9c5ff21d2cdf (patch) | |
| tree | e748d9c4ec4684ac8d88d624b712f9ecf0571741 /src | |
| parent | Merge #10075: Remove unused C++ code not covered by unit tests (diff) | |
| download | discoin-4fbae77929e6344bc49ab60af10a9c5ff21d2cdf.tar.xz discoin-4fbae77929e6344bc49ab60af10a9c5ff21d2cdf.zip | |
Improved efficiency in COutPoint constructors
Diffstat (limited to 'src')
| -rw-r--r-- | src/primitives/transaction.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/primitives/transaction.h b/src/primitives/transaction.h index d413e8b08..505903030 100644 --- a/src/primitives/transaction.h +++ b/src/primitives/transaction.h @@ -22,8 +22,8 @@ public: uint256 hash; uint32_t n; - COutPoint() { SetNull(); } - COutPoint(uint256 hashIn, uint32_t nIn) { hash = hashIn; n = nIn; } + COutPoint(): n((uint32_t) -1) { } + COutPoint(const uint256& hashIn, uint32_t nIn): hash(hashIn), n(nIn) { } ADD_SERIALIZE_METHODS; |