Commit b6a23d0027827002dc1273c6b63f9f9980df332a

Con Kolivas 2012-07-13T11:39:34

bitforce_get_result returns -1 on error now.

1
2
3
4
5
6
7
8
9
10
11
12
13
diff --git a/driver-bitforce.c b/driver-bitforce.c
index 93461c7..3189229 100644
--- a/driver-bitforce.c
+++ b/driver-bitforce.c
@@ -500,7 +500,7 @@ static int64_t bitforce_scanhash(struct thr_info *thr, struct work *work, int64_
 	if (ret)
 		ret = bitforce_get_result(thr, work);
 
-	if (!ret) {
+	if (ret == -1) {
 		ret = 0;
 		applog(LOG_ERR, "BFL%i: Comms error", bitforce->device_id);
 		bitforce->device_last_not_well = time(NULL);