diff options
author | redfish | 2023-09-03 01:14:55 -0400 |
---|---|---|
committer | redfish | 2023-09-03 01:14:55 -0400 |
commit | c3623c2a4e33f084e2b57507395cc7bd66ce0ea0 (patch) | |
tree | bf77d9a7e51e8a781c053199614b9c9f1ebadecb /b1b51490058bbc693eca8ef7abd69dc022446201-cast-nHeight-to-int32_t-to-match-the-VarIntMode-expe.patch | |
parent | 11be479003083a62aea7fca0e4e13f0df3f1655e (diff) | |
download | aur-bitcoin-unlimited.tar.gz |
replace varint patch with commit from upstream
Do what the upstream did.
Diffstat (limited to 'b1b51490058bbc693eca8ef7abd69dc022446201-cast-nHeight-to-int32_t-to-match-the-VarIntMode-expe.patch')
-rw-r--r-- | b1b51490058bbc693eca8ef7abd69dc022446201-cast-nHeight-to-int32_t-to-match-the-VarIntMode-expe.patch | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/b1b51490058bbc693eca8ef7abd69dc022446201-cast-nHeight-to-int32_t-to-match-the-VarIntMode-expe.patch b/b1b51490058bbc693eca8ef7abd69dc022446201-cast-nHeight-to-int32_t-to-match-the-VarIntMode-expe.patch new file mode 100644 index 000000000000..06f3253009f1 --- /dev/null +++ b/b1b51490058bbc693eca8ef7abd69dc022446201-cast-nHeight-to-int32_t-to-match-the-VarIntMode-expe.patch @@ -0,0 +1,27 @@ +From b1b51490058bbc693eca8ef7abd69dc022446201 Mon Sep 17 00:00:00 2001 +From: Griffith <probablyaplebeian@protonmail.com> +Date: Tue, 9 May 2023 09:42:46 -0700 +Subject: [PATCH] cast nHeight to int32_t to match the VarIntMode expected + type/value + +--- + src/undo.h | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/src/undo.h b/src/undo.h +index 2b17fbbae..2941de6cf 100644 +--- a/src/undo.h ++++ b/src/undo.h +@@ -27,7 +27,8 @@ public: + template <typename Stream> + void Serialize(Stream &s) const + { +- ::Serialize(s, VARINT(txout->nHeight * 2 + (txout->fCoinBase ? 1 : 0), VarIntMode::NONNEGATIVE_SIGNED)); ++ ::Serialize( ++ s, VARINT(((int32_t)txout->nHeight) * 2 + (txout->fCoinBase ? 1 : 0), VarIntMode::NONNEGATIVE_SIGNED)); + if (txout->nHeight > 0) + { + // Required to maintain compatibility with older undo format. +-- +2.42.0 + |