Commit bb0a200fc02a6ce16333d8b86c5aa0dc84e8732b

Kano 2013-09-03T22:10:52

miner.php mcast ignore duplicate replies

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
diff --git a/miner.php b/miner.php
index fdb9e52..f692440 100644
--- a/miner.php
+++ b/miner.php
@@ -451,9 +451,12 @@ function getrigs()
 				$mdes = '';
 
 			if (strlen($mdes) > 0)
-				$rigs[] = "$ip:$rp:$mdes";
+				$rig = "$ip:$rp:$mdes";
 			else
-				$rigs[] = "$ip:$rp";
+				$rig = "$ip:$rp";
+
+			if (!in_array($rig, $rigs))
+				$rigs[] = $rig;
 		}
 	}
 	if ((microtime(true) - $stt) >= $mcasttimeout)