Skip to content

Commit 512c36c

Browse files
authored
Merge pull request #16 from LIMXTEC/DEV_1
Dev 1
2 parents 701cf69 + 15bf246 commit 512c36c

27 files changed

+340
-670
lines changed

.travis.yml

-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ cache:
99
- $HOME/.ccache
1010
git:
1111
depth: false # full clone for git subtree check, this works around issue #12388
12-
1312
stages:
1413
- lint
1514
- test

configure.ac

100755100644
+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ AC_PREREQ([2.60])
33
define(_CLIENT_VERSION_MAJOR, 1)
44
define(_CLIENT_VERSION_MINOR, 9)
55
define(_CLIENT_VERSION_REVISION, 9)
6-
define(_CLIENT_VERSION_BUILD, 0)
6+
define(_CLIENT_VERSION_BUILD, 1)
77
define(_CLIENT_VERSION_IS_RELEASE, true)
88
define(_COPYRIGHT_YEAR, 2020)
99
define(_COPYRIGHT_HOLDERS,[The %s developers])

contrib/seeds/nodes_main.txt

+17-16
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,19 @@
11
# List of fixed seed nodes for mainnet
22

3-
80.211.195.230:9468
4-
194.182.84.184:9468
5-
81.2.239.169:9468
6-
80.211.219.25:9468
7-
185.28.101.48:9468
8-
80.211.139.4:9468
9-
80.211.0.105:9468
10-
94.177.217.18:9468
11-
[2001:15e8:110:42e6::1]:9468
12-
[2001:15e8:110:73b8::1]:9468
13-
[2001:15e8:110:7a9::1]:9468
14-
[2001:15e8:110:5a19::1]:9468
15-
[2001:15e8:110:2930::1]:9468
16-
[2a00:6d40:72:3404::1]:9468
17-
[2a00:6d40:72:6f69::1]:9468
18-
[2a00:6d40:60:b412::1]:9468
3+
4+
112.12.186.167:7951
5+
120.243.237.99:7951
6+
144.76.172.181:7951
7+
178.200.230.252:7951
8+
185.194.140.60:7951
9+
185.194.142.122:7951
10+
185.194.142.125:7951
11+
188.68.39.1:7951
12+
188.86.152.151:7951
13+
200.44.250.123:7951
14+
27.42.139.210:7951
15+
27.42.173.41:7951
16+
27.42.187.69:7951
17+
37.120.186.85:7951
18+
37.120.190.76:7951
19+
37.201.4.195:7951
+1
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
11
82bcf405f6db1d55b684a1f63a4aabad376cdad7
2+
9505C11C26DE91E28AED1ADB111707CDB9079D6A

contrib/verify-commits/trusted-keys

+1-4
Original file line numberDiff line numberDiff line change
@@ -1,4 +1 @@
1-
71A3B16735405025D447E8F274810B012346C9A6
2-
133EAC179436F14A5CF1B794860FEB804E669320
3-
32EE5C4C3FA15CCADB46ABE529D4BCB6416F53EC
4-
B8B3F1C0E58C15DB6A81D30C3648A882F4316B9B
1+
9505C11C26DE91E28AED1ADB111707CDB9079D6A

src/Makefile.am

+1-1
Original file line numberDiff line numberDiff line change
@@ -463,7 +463,7 @@ crypto_libbitcoin_crypto_shani_a_CPPFLAGS += -DENABLE_SHANI
463463
crypto_libbitcoin_crypto_shani_a_SOURCES = crypto/sha256_shani.cpp
464464

465465
# consensus: shared between all executables that validate any consensus rules.
466-
libbitcoin_consensus_a_CPPFLAGS = $(AM_CPPFLAGS) $(BITCOIN_INCLUDES)
466+
libbitcoin_consensus_a_CPPFLAGS = $(AM_CPPFLAGS) $(BITCOIN_INCLUDES) $(LIBTOOL_LDFLAGS)
467467
libbitcoin_consensus_a_CXXFLAGS = $(AM_CXXFLAGS) $(PIE_FLAGS)
468468
libbitcoin_consensus_a_SOURCES = \
469469
amount.h \

src/Makefile.qt.include

+2
Original file line numberDiff line numberDiff line change
@@ -405,6 +405,8 @@ RES_IMAGES = \
405405
qt/res/images/megacoin_logo_horizontal.png \
406406
qt/res/images/megacoin_main_hgB.png
407407

408+
RES_CSS = qt/res/css/megacoin_main.css
409+
408410
RES_MOVIES = $(wildcard $(srcdir)/qt/res/movies/spinner-*.png)
409411

410412
BITCOIN_RC = qt/res/bitcoin-qt-res.rc

src/arith_uint256.h

+17-18
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
// Copyright (c) 2009-2010 Satoshi Nakamoto
2-
// Copyright (c) 2009-2018 The Bitcoin Core developers
32
// Copyright (c) 2019 Megacoin developers
43
// Distributed under the MIT software license, see the accompanying
54
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
@@ -291,27 +290,27 @@ arith_uint256 UintToArith256(const uint256 &);
291290

292291
// Megacoin
293292
/** 512-bit unsigned integer */
294-
class arith_uint512
293+
class arith_uint512
295294
{
296295
protected:
297-
enum { WIDTH = 512 / 32 };
298-
uint32_t pn[WIDTH];
296+
enum { WIDTH = 512 / 32 };
297+
uint32_t pn[WIDTH];
299298

300299
public:
301-
arith_uint512()
302-
{
303-
for (int i = 0; i < WIDTH; i++)
304-
pn[i] = 0;
305-
}
306-
307-
arith_uint256 trim256() const
308-
{
309-
arith_uint256 ret;
310-
for (unsigned int i = 0; i < arith_uint256::WIDTH; i++) {
311-
ret.pn[i] = pn[i];
312-
}
313-
return ret;
314-
}
300+
arith_uint512()
301+
{
302+
for (int i = 0; i < WIDTH; i++)
303+
pn[i] = 0;
304+
}
305+
306+
arith_uint256 trim256() const
307+
{
308+
arith_uint256 ret;
309+
for (unsigned int i = 0; i < arith_uint256::WIDTH; i++) {
310+
ret.pn[i] = pn[i];
311+
}
312+
return ret;
313+
}
315314
};
316315

317316
#endif // MEGACOIN_ARITH_UINT256_H

src/chainparams.cpp

+4-1
Original file line numberDiff line numberDiff line change
@@ -118,12 +118,14 @@ class CMainParams : public CChainParams {
118118
consensus.vDeployments[Consensus::DEPLOYMENT_TESTDUMMY].bit = 28;
119119
consensus.vDeployments[Consensus::DEPLOYMENT_TESTDUMMY].nStartTime = 1525132800; // 05/01/2018 @ 12:00am (UTC)
120120
consensus.vDeployments[Consensus::DEPLOYMENT_TESTDUMMY].nTimeout = 1746057600; // 05/01/2025 @ 12:00am (UTC)
121+
consensus.vDeployments[Consensus::DEPLOYMENT_TESTDUMMY].nHeight = 1280000;
121122

122123
// Deployment of BIP68, BIP112, and BIP113.
123124
consensus.vDeployments[Consensus::DEPLOYMENT_CSV].bit = 0;
124125
consensus.vDeployments[Consensus::DEPLOYMENT_CSV].nStartTime = 1525132800; // 05/01/2018 @ 12:00am (UTC)
125126
consensus.vDeployments[Consensus::DEPLOYMENT_CSV].nTimeout = 1746057600; // 05/01/2025 @ 12:00am (UTC)
126-
127+
consensus.vDeployments[Consensus::DEPLOYMENT_CSV].nHeight = 1280000;
128+
127129
// FXTC TODO:
128130
// Dash
129131
// Deployment of DIP0001
@@ -139,6 +141,7 @@ class CMainParams : public CChainParams {
139141
consensus.vDeployments[Consensus::DEPLOYMENT_SEGWIT].bit = 1;
140142
consensus.vDeployments[Consensus::DEPLOYMENT_SEGWIT].nStartTime = 1525132800; // 05/01/2018 @ 12:00am (UTC)
141143
consensus.vDeployments[Consensus::DEPLOYMENT_SEGWIT].nTimeout = 1746057600; // 05/01/2025 @ 12:00am (UTC)
144+
consensus.vDeployments[Consensus::DEPLOYMENT_SEGWIT].nHeight = 1280000;
142145

143146
// The best chain should have at least this much work.
144147
consensus.nMinimumChainWork = uint256S("0x00000000000000000000000000000000000000000000000005dfab1790ba9fdd"); // Megacoin

src/consensus/consensus.h

+4
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,10 @@ static const int COINBASE_MATURITY = 100;
2121
static const int COINBASE_MATURITY_2 = 4032; // One Week
2222
/**Algoswitch Megacoin */
2323
static const unsigned int HASH_FORK_TIME_1 = 1588842000; //05/07/2020 @ 9:00am (UTC)
24+
static const unsigned int HASH_FORK_TIME_2 = 1591131463;
25+
static const unsigned int SKIPP_NBITS = 1257000;
26+
static const unsigned int UNEXPECTED_WITNESS = 1500000;
27+
static const unsigned int FORK_MATURITY_2 = 1260800; //Not used
2428

2529
static const int WITNESS_SCALE_FACTOR = 4;
2630

src/consensus/params.h

+1
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ struct BIP9Deployment {
4242
int64_t nStartTime;
4343
/** Timeout/expiry MedianTime for the deployment attempt. */
4444
int64_t nTimeout;
45+
int64_t nHeight;
4546

4647
// Dash
4748
/** The number of past blocks (including the block under consideration) to be taken into account for locking in a fork. */

src/consensus/tx_verify.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -228,7 +228,7 @@ bool Consensus::CheckTxInputs(const CTransaction& tx, CValidationState& state, c
228228
// if (coin.IsCoinBase() && nSpendHeight - coin.nHeight < COINBASE_MATURITY) {
229229
// MEC BEGIN
230230
// BTX BEGIN
231-
if (AHeight < 1253800)
231+
if (AHeight < 1260800)
232232
{
233233
if (coin.IsCoinBase() && nSpendHeight - coin.nHeight < COINBASE_MATURITY)
234234
{
@@ -239,7 +239,7 @@ bool Consensus::CheckTxInputs(const CTransaction& tx, CValidationState& state, c
239239
}
240240
else
241241
{
242-
if (coin.IsCoinBase() && nSpendHeight - coin.nHeight < (!sporkManager.IsSporkActive(SPORK_MEGACOIN_15_COINBASE_MATURITY_STAGE_2)? COINBASE_MATURITY : COINBASE_MATURITY_2 ))
242+
if (coin.IsCoinBase() && nSpendHeight - coin.nHeight < COINBASE_MATURITY_2 )
243243
{
244244
return state.Invalid(false,
245245
REJECT_INVALID, "bad-txns-premature-spend-of-coinbase",

src/crypto/gost_streebog.h

+3-3
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,8 @@
3333
* @author Mish <[email protected]>
3434
*/
3535

36-
#ifndef SPH_GOST_H__
37-
#define SPH_GOST_H__
36+
#ifndef MEGACOIN_CRYPTO_GOST_STREEBOG_H
37+
#define MEGACOIN_CRYPTO_GOST_STREEBOG_H
3838

3939
#ifdef __cplusplus
4040
extern "C"{
@@ -182,4 +182,4 @@ void sph_gost512_addbits_and_close(
182182
}
183183
#endif
184184

185-
#endif
185+
#endif //MEGACOIN_CRYPTO_GOST_STREEBOG_H

0 commit comments

Comments
 (0)