Commit 9e0e61509d7bd78edbdac15b53bc8a6e9187043e

Con Kolivas 2012-10-03T01:14:35

We should be testing for id_val, not id in parse stratum response.

1
2
3
4
5
6
7
8
9
10
11
12
13
diff --git a/cgminer.c b/cgminer.c
index a2c3392..f0df284 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) && !id)) {
+	    (err_val && !json_is_null(err_val) && !id_val)) {
 		char *ss;
 
 		if (err_val)