File tree Expand file tree Collapse file tree 2 files changed +3
-1
lines changed Expand file tree Collapse file tree 2 files changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -78,6 +78,7 @@ bytes dev::ipfsHash(string _data)
78
78
79
79
cout << toHex (blockData) << endl;
80
80
cout << toHex (blockData.size ()) << endl;
81
+ cout << " Hash: " << toHex (picosha2::hash256 (std::move (blockData))) << endl;
81
82
// Multihash: sha2-256, 256 bits
82
83
bytes hash = bytes{0x12 , 0x20 } + picosha2::hash256 (std::move (blockData));
83
84
return hash;
Original file line number Diff line number Diff line change @@ -45,7 +45,8 @@ BOOST_AUTO_TEST_CASE(test_small)
45
45
BOOST_AUTO_TEST_CASE (test_medium)
46
46
{
47
47
// 131000 works, 131071 does not.
48
- size_t length = 131000 ;// 131071;
48
+ // TODO it seems to be an error in the sha2 library, though.
49
+ size_t length = 131071 ;// 131071;
49
50
string data;
50
51
data.resize (length, 0 );
51
52
BOOST_REQUIRE_EQUAL (data.size (), length);
You can’t perform that action at this time.
0 commit comments