use share chain's time instead of time.time() to decide when to switch over
authorForrest Voight <forrest@forre.st>
Sun, 26 Feb 2012 18:44:25 +0000 (13:44 -0500)
committerForrest Voight <forrest@forre.st>
Sun, 26 Feb 2012 18:44:25 +0000 (13:44 -0500)
p2pool/main.py

index a2fc6b9..418d8cf 100644 (file)
@@ -485,7 +485,7 @@ def main(args, net, datadir_path, merged_urls, worker_endpoint):
                     mm_data = ''
                     mm_later = []
                 
-                new = time.time() > net.SWITCH_TIME
+                new = tracker.shares[current_work.value['best_share_hash']].timestamp > net.SWITCH_TIME
                 
                 if new:
                     share_info, generate_tx = p2pool_data.new_generate_transaction(