Commit 925d01922b94e541bcdfbdc342b9670f6b12fe55

Con Kolivas 2012-10-02T14:12:34

If a share result has an error code but still has an id, it is likely a reject, not an error.

1
2
3
4
5
6
7
8
9
10
11
12
13
diff --git a/cgminer.c b/cgminer.c
index 3824a50..bda5159 100644
--- a/cgminer.c
+++ b/cgminer.c
@@ -4079,7 +4079,7 @@ static bool parse_stratum_response(char *s)
 	id_val = json_object_get(val, "id");
 
 	if ((!res_val || !id_val) || (json_is_null(res_val) || json_is_null(id_val)) ||
-	    (err_val && !json_is_null(err_val))) {
+	    (err_val && !json_is_null(err_val) && !id)) {
 		char *ss;
 
 		if (err_val)