Browse Source

Bugfix: Free stratum nonce1 before replacing it with new value on reconnect

Luke Dashjr 13 years ago
parent
commit
c86db0734f
1 changed files with 1 additions and 0 deletions
  1. 1 0
      util.c

+ 1 - 0
util.c

@@ -1100,6 +1100,7 @@ bool initiate_stratum(struct pool *pool)
 		goto out;
 	}
 
+	free(pool->nonce1);
 	pool->nonce1 = strdup(json_string_value(json_array_get(res_val, 1)));
 	if (!pool->nonce1) {
 		applog(LOG_WARNING, "Failed to get nonce1 in initiate_stratum");