Skip to content

Commit

Permalink
Add stuff
Browse files Browse the repository at this point in the history
  • Loading branch information
whitj00 committed May 7, 2015
1 parent c2b09c9 commit 6b4ad4b
Show file tree
Hide file tree
Showing 4 changed files with 103 additions and 3 deletions.
83 changes: 83 additions & 0 deletions CHANGELOG.md
@@ -0,0 +1,83 @@
# Change Log

## [fund](https://github.com/opalcoin/opalcoin/tree/fund) (2015-03-24)

[Full Changelog](https://github.com/opalcoin/opalcoin/compare/v1.3.2...fund)

**Closed issues:**

- BlackCoin residues [\#25](https://github.com/OpalCoin/OpalCoin/issues/25)

**Merged pull requests:**

- Add alias system [\#24](https://github.com/OpalCoin/OpalCoin/pull/24) ([whitj00](https://github.com/whitj00))

- Add alias system [\#23](https://github.com/OpalCoin/OpalCoin/pull/23) ([whitj00](https://github.com/whitj00))

## [v1.3.2](https://github.com/opalcoin/opalcoin/tree/v1.3.2) (2015-02-09)

[Full Changelog](https://github.com/opalcoin/opalcoin/compare/v1.3.1...v1.3.2)

**Merged pull requests:**

- Multisigfix [\#22](https://github.com/OpalCoin/OpalCoin/pull/22) ([whitj00](https://github.com/whitj00))

- qt5 [\#21](https://github.com/OpalCoin/OpalCoin/pull/21) ([whitj00](https://github.com/whitj00))

- v1.3.1 [\#20](https://github.com/OpalCoin/OpalCoin/pull/20) ([whitj00](https://github.com/whitj00))

## [v1.3.1](https://github.com/opalcoin/opalcoin/tree/v1.3.1) (2015-01-03)

[Full Changelog](https://github.com/opalcoin/opalcoin/compare/v1.1...v1.3.1)

**Closed issues:**

- Can't find db\_cxx.h [\#17](https://github.com/OpalCoin/OpalCoin/issues/17)

**Merged pull requests:**

- v1.3.1 [\#19](https://github.com/OpalCoin/OpalCoin/pull/19) ([whitj00](https://github.com/whitj00))

- Update README [\#16](https://github.com/OpalCoin/OpalCoin/pull/16) ([Danz0r77](https://github.com/Danz0r77))

- Files [\#18](https://github.com/OpalCoin/OpalCoin/pull/18) ([SparkMasterTape](https://github.com/SparkMasterTape))

## [v1.1](https://github.com/opalcoin/opalcoin/tree/v1.1) (2014-10-11)

**Closed issues:**

- Dock Icon is still Oynxcoin Branding [\#2](https://github.com/OpalCoin/OpalCoin/issues/2)

**Merged pull requests:**

- Merge Stealth into Master [\#15](https://github.com/OpalCoin/OpalCoin/pull/15) ([whitj00](https://github.com/whitj00))

- Merge master into stealth [\#14](https://github.com/OpalCoin/OpalCoin/pull/14) ([whitj00](https://github.com/whitj00))

- Stealth [\#13](https://github.com/OpalCoin/OpalCoin/pull/13) ([whitj00](https://github.com/whitj00))

- Update .travis.yml [\#12](https://github.com/OpalCoin/OpalCoin/pull/12) ([whitj00](https://github.com/whitj00))

- Change Icon and Name [\#11](https://github.com/OpalCoin/OpalCoin/pull/11) ([whitj00](https://github.com/whitj00))

- Add Bittrex Trading In Wallet [\#10](https://github.com/OpalCoin/OpalCoin/pull/10) ([whitj00](https://github.com/whitj00))

- Merge Opacity [\#8](https://github.com/OpalCoin/OpalCoin/pull/8) ([whitj00](https://github.com/whitj00))

- Revert "Merge Opacity" [\#7](https://github.com/OpalCoin/OpalCoin/pull/7) ([whitj00](https://github.com/whitj00))

- Merge Opacity [\#6](https://github.com/OpalCoin/OpalCoin/pull/6) ([coolcash](https://github.com/coolcash))

- Revert "Add Encrypted Messaging to Opalcoin" [\#3](https://github.com/OpalCoin/OpalCoin/pull/3) ([coolcash](https://github.com/coolcash))

- Add Encrypted Messaging to Opalcoin [\#1](https://github.com/OpalCoin/OpalCoin/pull/1) ([whitj00](https://github.com/whitj00))

- Add In-Wallet Trading \(OpalEx\) to opalcoin [\#9](https://github.com/OpalCoin/OpalCoin/pull/9) ([whitj00](https://github.com/whitj00))

- Add Opacity Encrypted Messaging to Opalcoin [\#5](https://github.com/OpalCoin/OpalCoin/pull/5) ([whitj00](https://github.com/whitj00))

- Update bitcoingui.cpp [\#4](https://github.com/OpalCoin/OpalCoin/pull/4) ([kitaco](https://github.com/kitaco))



\* *This Change Log was automatically generated by [github_changelog_generator](https://github.com/skywinder/Github-Changelog-Generator)*
2 changes: 1 addition & 1 deletion opalcoin-qt.pro
Expand Up @@ -41,7 +41,7 @@ UI_DIR = build
OPENSSL_LIB_PATH=/usr/local/opt/openssl/lib

MINIUPNPC_INCLUDE_PATH=/usr/local/opt/miniupnpc/include
MINIUPNPC_LIB_PATH=/usr/local/Cellar/miniupnpc/1.8.20131007/lib
MINIUPNPC_LIB_PATH=/usr/local/Cellar/miniupnpc/1.9.20141027/lib

QRENCODE_INCLUDE_PATH=/usr/local/opt/qrencode/include
QRENCODE_LIB_PATH=/usr/local/opt/qrencode/lib
Expand Down
20 changes: 18 additions & 2 deletions src/main.cpp
Expand Up @@ -2198,6 +2198,13 @@ bool ProcessBlock(CNode* pfrom, CBlock* pblock)
return error("ProcessBlock() : block with too little %s", pblock->IsProofOfStake()? "proof-of-stake" : "proof-of-work");
}
}
// Be more aggressive with blockchain download. Send new getblocks() message after connection
// to new node if waited longer than MAX_TIME_SINCE_BEST_BLOCK.
int64_t TimeSinceBestBlock = GetTime() - nTimeBestReceived;
if (TimeSinceBestBlock > MAX_TIME_SINCE_BEST_BLOCK) {
printf("INFO: Waiting %"PRId64" sec which is too long. Sending GetBlocks(0)\n", TimeSinceBestBlock);
pfrom->PushGetBlocks(pindexBest, uint256(0));
}

// ppcoin: ask for pending sync-checkpoint if any
if (!IsInitialBlockDownload())
Expand Down Expand Up @@ -3116,7 +3123,7 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv,
// Send the rest of the chain
if (pindex)
pindex = pindex->pnext;
int nLimit = 500;
int nLimit = 1500;
printf("getblocks %d to %s limit %d\n", (pindex ? pindex->nHeight : -1), hashStop.ToString().substr(0,20).c_str(), nLimit);
for (; pindex; pindex = pindex->pnext)
{
Expand Down Expand Up @@ -3268,8 +3275,17 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv,
CInv inv(MSG_BLOCK, hashBlock);
pfrom->AddInventoryKnown(inv);

if (ProcessBlock(pfrom, &block))
if (ProcessBlock(pfrom, &block)) {
mapAlreadyAskedFor.erase(inv);
} else {
// Be more aggressive with blockchain download. Send getblocks() message after
// an error related to new block download.
int64_t TimeSinceBestBlock = GetTime() - nTimeBestReceived;
if (TimeSinceBestBlock > MAX_TIME_SINCE_BEST_BLOCK) {
printf("INFO: Waiting %"PRId64" sec which is too long. Sending GetBlocks(0)\n", TimeSinceBestBlock);
pfrom->PushGetBlocks(pindexBest, uint256(0));
}
}
if (block.nDoS) pfrom->Misbehaving(block.nDoS);
}

Expand Down
1 change: 1 addition & 0 deletions src/main.h
Expand Up @@ -43,6 +43,7 @@ static const int64_t MAX_MONEY = 15000248 * COIN; //Does not reflect actual tota
static const int64_t COIN_YEAR_REWARD = 5 * CENT; // 5% per year
static const int64_t MAX_MINT_PROOF_OF_STAKE = 0.05 * COIN; // 5% Annual PoS Interest
static const int MODIFIER_INTERVAL_SWITCH = 15000;
static const int MAX_TIME_SINCE_BEST_BLOCK = 5; // how many seconds to wait before sending next PushGetBlocks()

inline bool MoneyRange(int64_t nValue) { return (nValue >= 0 && nValue <= MAX_MONEY); }
// Threshold for nLockTime: below this value it is interpreted as block number, otherwise as UNIX timestamp.
Expand Down

0 comments on commit 6b4ad4b

Please sign in to comment.