Merge branch 'master' of git://tinc-vpn.org/tinc into 1.1
authorGuus Sliepen <guus@tinc-vpn.org>
Sun, 26 Feb 2012 15:27:13 +0000 (16:27 +0100)
committerGuus Sliepen <guus@tinc-vpn.org>
Sun, 26 Feb 2012 15:27:13 +0000 (16:27 +0100)
1  2 
src/net_packet.c

@@@ -137,9 -136,12 +137,12 @@@ static void send_mtu_probe_handler(int 
                        len = 64;
                
                memset(packet.data, 0, 14);
 -              RAND_pseudo_bytes(packet.data + 14, len - 14);
 +              randomize(packet.data + 14, len - 14);
                packet.len = len;
-               packet.priority = i < 3 ? 0 : -1;
+               if(i >= 3 && n->mtuprobes <= 10)
+                       packet.priority = -1;
+               else
+                       packet.priority = 0;
  
                ifdebug(TRAFFIC) logger(LOG_INFO, "Sending MTU probe length %d to %s (%s)", len, n->name, n->hostname);