Browse Source

Bugfix: When a stratum connection is interrupted, ensure all work/shares for it are considered stale

Luke Dashjr 13 years ago
parent
commit
b7baf168d0
1 changed files with 4 additions and 0 deletions
  1. 4 0
      miner.c

+ 4 - 0
miner.c

@@ -5477,6 +5477,10 @@ static void *stratum_thread(void *userdata)
 			pool->getfail_occasions++;
 			total_go++;
 
+			// Make any pending work/shares stale
+			pool->submit_old = false;
+			++pool->work_restart_id;
+
 			/* If the socket to our stratum pool disconnects, all
 			 * tracked submitted shares are lost and we will leak
 			 * the memory if we don't discard their records. */