aboutsummaryrefslogtreecommitdiff
path: root/src/uint256.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/uint256.h')
-rw-r--r--src/uint256.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/uint256.h b/src/uint256.h
index 7dbb3f83bb..c19d82ceb5 100644
--- a/src/uint256.h
+++ b/src/uint256.h
@@ -203,7 +203,7 @@ public:
{
// prefix operator
int i = 0;
- while (--pn[i] == -1 && i < WIDTH-1)
+ while (--pn[i] == (uint32_t)-1 && i < WIDTH-1)
i++;
return *this;
}
@@ -370,9 +370,10 @@ public:
return sizeof(pn);
}
- uint64_t Get64(int n=0) const
+ uint64_t GetLow64() const
{
- return pn[2*n] | (uint64_t)pn[2*n+1] << 32;
+ assert(WIDTH >= 2);
+ return pn[0] | (uint64_t)pn[1] << 32;
}
// unsigned int GetSerializeSize(int nType=0, int nVersion=PROTOCOL_VERSION) const