From 0626f6c4a77c4afb5aaf77624fd0c881e8dc61c2 Mon Sep 17 00:00:00 2001 From: CryptoManiac Date: Mon, 25 Apr 2016 23:14:05 +0300 Subject: [PATCH] Remove unused function. --- src/hash.h | 21 +-------------------- 1 files changed, 1 insertions(+), 20 deletions(-) diff --git a/src/hash.h b/src/hash.h index cdd9dbb..7d884c6 100644 --- a/src/hash.h +++ b/src/hash.h @@ -67,8 +67,7 @@ public: template -inline uint256 Hash(const T1 p1begin, const T1 p1end, - const T2 p2begin, const T2 p2end) +inline uint256 Hash(const T1 p1begin, const T1 p1end, const T2 p2begin, const T2 p2end) { static unsigned char pblank[1]; uint256 hash1; @@ -82,24 +81,6 @@ inline uint256 Hash(const T1 p1begin, const T1 p1end, return hash2; } -template -inline uint256 Hash(const T1 p1begin, const T1 p1end, - const T2 p2begin, const T2 p2end, - const T3 p3begin, const T3 p3end) -{ - static unsigned char pblank[1]; - uint256 hash1; - SHA256_CTX ctx; - SHA256_Init(&ctx); - SHA256_Update(&ctx, (p1begin == p1end ? pblank : (unsigned char*)&p1begin[0]), (p1end - p1begin) * sizeof(p1begin[0])); - SHA256_Update(&ctx, (p2begin == p2end ? pblank : (unsigned char*)&p2begin[0]), (p2end - p2begin) * sizeof(p2begin[0])); - SHA256_Update(&ctx, (p3begin == p3end ? pblank : (unsigned char*)&p3begin[0]), (p3end - p3begin) * sizeof(p3begin[0])); - SHA256_Final(hash1.begin(), &ctx); - uint256 hash2; - SHA256(hash1.begin(), hash1.size(), hash2.begin()); - return hash2; -} - template uint256 SerializeHash(const T& obj, int nType=SER_GETHASH, int nVersion=PROTOCOL_VERSION) { -- 1.7.1