Commit 36c6da8ad430187abee3c58850e05ebfe6071e57

Con Kolivas 2013-10-27T00:46:19

Reinstate block solve testing.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
diff --git a/cgminer.c b/cgminer.c
index 8034880..f4cb7d6 100644
--- a/cgminer.c
+++ b/cgminer.c
@@ -6092,6 +6092,14 @@ static void update_work_stats(struct thr_info *thr, struct work *work)
 {
 	work->share_diff = share_diff(work);
 
+	if (unlikely(work->share_diff >= current_diff)) {
+		work->block = true;
+		work->pool->solved++;
+		found_blocks++;
+		work->mandatory = true;
+		applog(LOG_NOTICE, "Found block for pool %d!", work->pool->pool_no);
+	}
+
 	mutex_lock(&stats_lock);
 	total_diff1 += work->device_diff;
 	thr->cgpu->diff1 += work->device_diff;