Commit 01aadda25cf9080bb3b02d974c0c38b2bc39563f

Con Kolivas 2011-08-14T11:24:38

Simply set the time of day when the work is decoded.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
diff --git a/main.c b/main.c
index 2588351..59c6ad4 100644
--- a/main.c
+++ b/main.c
@@ -766,6 +766,7 @@ static bool work_decode(const json_t *val, struct work *work)
 	}
 
 	memset(work->hash, 0, sizeof(work->hash));
+	gettimeofday(&work->tv_staged, NULL);
 
 	return true;
 
@@ -1582,8 +1583,6 @@ static void *stage_thread(void *userdata)
 		}
 
 		test_work_current(work);
-		if (!work->cloned && !work->clone)
-			gettimeofday(&work->tv_staged, NULL);
 
 		if (opt_debug)
 			applog(LOG_DEBUG, "Pushing work to getwork queue");