Skip to content

Commit

Permalink
stratum: fix for auxpow result:null on success
Browse files Browse the repository at this point in the history
Some auxpow coins return error:null, result:null on success and are not reported correctly.

I have not found a coin which returns this on failure.
  • Loading branch information
lavajumper authored and tpruvot committed Feb 25, 2019
1 parent 47ec59b commit f701887
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions stratum/coind_submit.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,9 @@ bool coind_submitgetauxblock(YAAMP_COIND *coind, const char *hash, const char *b

json_value *json_result = json_get_object(json, "result");
bool b = json_result && json_result->type == json_boolean && json_result->u.boolean;
// some auxpow coins return error:null, result: null on success
if(!b)
b=json_result && json_result->type == json_null;

json_value_free(json);
return b;
Expand Down

0 comments on commit f701887

Please sign in to comment.