Skip to content

Commit

Permalink
test errorCode lucasjones#4
Browse files Browse the repository at this point in the history
  • Loading branch information
avtc committed Mar 6, 2018
1 parent 08678b5 commit 49fdf0e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/main.cc
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ void get_block_id(const Nan::FunctionCallbackInfo<v8::Value>& info) {
int errorCode = 0;

block b = AUTO_VAL_INIT(b);
if (!parse_and_validate_block_from_blob(input, b, b.major_version >= mergedMiningBlockVersion, &errorCode))
if (!parse_and_validate_block_from_blob(input, b, b.major_version >= mergedMiningBlockVersion, errorCode))
return THROW_ERROR_EXCEPTION("Failed to parse block" + std::to_string(errorCode));

crypto::hash block_id;
Expand Down Expand Up @@ -183,7 +183,7 @@ void construct_block_blob(const Nan::FunctionCallbackInfo<v8::Value>& info) {
int errorCode = 0;

block b = AUTO_VAL_INIT(b);
if (!parse_and_validate_block_from_blob(block_template_blob, b, b.major_version >= mergedMiningBlockVersion, &errorCode))
if (!parse_and_validate_block_from_blob(block_template_blob, b, b.major_version >= mergedMiningBlockVersion, errorCode))
return THROW_ERROR_EXCEPTION("Failed to parse block" + std::to_string(errorCode));

b.nonce = nonce;
Expand Down

0 comments on commit 49fdf0e

Please sign in to comment.