message: Reuse vector hashing code for uint256
diff: @@ -282,16 +282,8 @@ void CRollingBloomFilter::insert(const std::vector<unsigned char>& vKey)
  void CRollingBloomFilter::insert(const uint256& hash)
  {
  - if (nInsertions == 0) {
  - b1.clear();
  - } else if (nInsertions == nBloomSize / 2) {
  - b2.clear();
  - }
  - b1.insert(hash);
  - b2.insert(hash);
  - if (++nInsertions == nBloomSize) {
  - nInsertions = 0;
  - }
  + std::vector<unsigned char> data(hash.begin(), hash.end());
  + insert(data);
  }
  bool CRollingBloomFilter::contains(const std::vector<unsigned char>& vKey) const
  @@ -304,10 +296,8 @@ bool CRollingBloomFilter::contains(const std::vector<unsigned char>& vKey) const
  bool CRollingBloomFilter::contains(const uint256& hash) const
  {
  - if (nInsertions < nBloomSize / 2) {
  - return b2.contains(hash);
  - }
  - return b1.contains(hash);
  + std::vector<unsigned char> data(hash.begin(), hash.end());
  + return contains(data);
  }
  void CRollingBloomFilter::clear()
  