Browse Source

Merge commit '492c7765e' into bfgminer

Luke Dashjr 4 years ago
parent
commit
a30f7aace8
1 changed files with 2 additions and 2 deletions
  1. 2 2
      util.c

+ 2 - 2
util.c

@@ -2914,9 +2914,9 @@ out: ;
 		char * const idstr = json_dumps_ANY(j_id, 0);
 		char buf[0x80];
 		if (unlikely(emsg))
-			snprintf(buf, sizeof(buf), "{\"id\":%s,\"result\":true,\"error\":null}", idstr);
-		else
 			snprintf(buf, sizeof(buf), "{\"id\":%s,\"result\":null,\"error\":[-1,\"%s\",null]}", idstr, emsg);
+		else
+			snprintf(buf, sizeof(buf), "{\"id\":%s,\"result\":true,\"error\":null}", idstr);
 		free(idstr);
 		stratum_send(pool, buf, strlen(buf));
 	}