Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/master' into 0.15
Browse files Browse the repository at this point in the history
  • Loading branch information
h4x3rotab committed Sep 19, 2018
2 parents 99c1224 + 2991e65 commit 939de3e
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 6 deletions.
2 changes: 1 addition & 1 deletion configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ dnl require autoconf 2.60 (AS_ECHO/AS_ECHO_N)
AC_PREREQ([2.60])
define(_CLIENT_VERSION_MAJOR, 0)
define(_CLIENT_VERSION_MINOR, 15)
define(_CLIENT_VERSION_REVISION, 1)
define(_CLIENT_VERSION_REVISION, 2)
define(_CLIENT_VERSION_BUILD, 0)
define(_CLIENT_VERSION_IS_RELEASE, true)
define(_COPYRIGHT_YEAR, 2018)
Expand Down
2 changes: 1 addition & 1 deletion src/pow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ unsigned int GetNextWorkRequired(const CBlockIndex* pindexLast, const CBlockHead
bool postfork = nHeight >= params.BTGHeight;

if (postfork == false) {
// Original Bitcion PoW.
// Original Bitcoin PoW.
return BitcoinGetNextWorkRequired(pindexLast, pblock, params);
}
else if (nHeight < params.BTGHeight + params.BTGPremineWindow) {
Expand Down
6 changes: 3 additions & 3 deletions src/qt/locale/bitcoin_ar.ts
Original file line number Diff line number Diff line change
Expand Up @@ -63,11 +63,11 @@
</message>
<message>
<source>These are your Bitcoin addresses for sending payments. Always check the amount and the receiving address before sending coins.</source>
<translation>هذه هي عناوين Bitcion التابعة لك من أجل إرسال الدفعات. تحقق دائما من المبلغ و عنوان المرسل المستقبل قبل إرسال العملات</translation>
<translation>هذه هي عناوين Bitcoin التابعة لك من أجل إرسال الدفعات. تحقق دائما من المبلغ و عنوان المرسل المستقبل قبل إرسال العملات</translation>
</message>
<message>
<source>These are your Bitcoin addresses for receiving payments. It is recommended to use a new receiving address for each transaction.</source>
<translation>هذه هي عناوين Bitcion التابعة لك من أجل إستقبال الدفعات. ينصح استخدام عنوان جديد من أجل كل صفقة</translation>
<translation>هذه هي عناوين Bitcoin التابعة لك من أجل إستقبال الدفعات. ينصح استخدام عنوان جديد من أجل كل صفقة</translation>
</message>
<message>
<source>&amp;Copy Address</source>
Expand Down Expand Up @@ -2052,4 +2052,4 @@
<translation>خطأ</translation>
</message>
</context>
</TS>
</TS>
2 changes: 1 addition & 1 deletion src/validation.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2868,7 +2868,7 @@ bool CheckBlock(const CBlock& block, CValidationState& state, const Consensus::P

// Check transactions
for (const auto& tx : block.vtx)
if (!CheckTransaction(*tx, state, false))
if (!CheckTransaction(*tx, state, true))
return state.Invalid(false, state.GetRejectCode(), state.GetRejectReason(),
strprintf("Transaction check failed (tx hash %s) %s", tx->GetHash().ToString(), state.GetDebugMessage()));

Expand Down
11 changes: 11 additions & 0 deletions test/functional/invalidblockrequest.py
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,17 @@ def get_tests(self):
yield TestInstance([[block2, RejectResult(16, b'bad-txns-duplicate')], [block2_orig, True]])
height += 1


# Check transactions for duplicate inputs
self.log.info("Test duplicate input block.")

block2_orig.vtx[2].vin.append(block2_orig.vtx[2].vin[0])
block2_orig.vtx[2].rehash()
block2_orig.hashMerkleRoot = block2_orig.calc_merkle_root()
block2_orig.rehash()
block2_orig.solve()
yield TestInstance([[block2_orig, RejectResult(16, b'bad-txns-inputs-duplicate')]])

'''
Make sure that a totally screwed up block is not valid.
'''
Expand Down

0 comments on commit 939de3e

Please sign in to comment.