mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-02-16 10:29:00 +00:00
Merge commit 'd710ed5' into 0.6.0.x
This commit is contained in:
commit
0eca21c5fa
@ -1903,7 +1903,7 @@ FILE* AppendBlockFile(unsigned int& nFileRet)
|
||||
if (fseek(file, 0, SEEK_END) != 0)
|
||||
return NULL;
|
||||
// FAT32 file size max 4GB, fseek and ftell max 2GB, so we must stay under 2GB
|
||||
if (ftell(file) < 0x7F000000 - MAX_SIZE)
|
||||
if (ftell(file) < (long)(0x7F000000 - MAX_SIZE))
|
||||
{
|
||||
nFileRet = nCurrentBlockFile;
|
||||
return file;
|
||||
|
||||
@ -393,6 +393,7 @@ typedef std::map<uint256, std::pair<CTxIndex, CTransaction> > MapPrevTx;
|
||||
class CTransaction
|
||||
{
|
||||
public:
|
||||
static const int CURRENT_VERSION=1;
|
||||
int nVersion;
|
||||
std::vector<CTxIn> vin;
|
||||
std::vector<CTxOut> vout;
|
||||
@ -418,7 +419,7 @@ public:
|
||||
|
||||
void SetNull()
|
||||
{
|
||||
nVersion = 1;
|
||||
nVersion = CTransaction::CURRENT_VERSION;
|
||||
vin.clear();
|
||||
vout.clear();
|
||||
nLockTime = 0;
|
||||
@ -828,6 +829,7 @@ class CBlock
|
||||
{
|
||||
public:
|
||||
// header
|
||||
static const int CURRENT_VERSION=1;
|
||||
int nVersion;
|
||||
uint256 hashPrevBlock;
|
||||
uint256 hashMerkleRoot;
|
||||
@ -869,7 +871,7 @@ public:
|
||||
|
||||
void SetNull()
|
||||
{
|
||||
nVersion = 1;
|
||||
nVersion = CBlock::CURRENT_VERSION;
|
||||
hashPrevBlock = 0;
|
||||
hashMerkleRoot = 0;
|
||||
nTime = 0;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user