int expected = 1024; // Cut off to avoid DoS attack
while (expected < shutdown.length()) {
if (random == null)
- random = new Random(System.currentTimeMillis());
+ random = new Random();
expected += (random.nextInt() % 1024);
}
while (expected > 0) {
public static final int BITS_PER_BYTE = 8;
protected static SecureRandom secrand = null;
- protected static Random rand = new Random(System.currentTimeMillis());
+ protected static Random rand = new Random();
static {
secrand = new SecureRandom();
secrand.setSeed(rand.nextLong());
public static class LoadMessage extends ByteMessage {
public static byte[] outdata = new byte[size];
- public static Random r = new Random(System.currentTimeMillis());
+ public static Random r = new Random();
public static int getMessageSize (LoadMessage msg) {
return msg.getMessage().length;
}
dataModel.getValueAt(-1,-1);
}
- public static Random random = new Random(System.currentTimeMillis());
+ public static Random random = new Random();
public static String random(int count, int start, int end, boolean letters, boolean numbers,
char[] chars ) {
if (count == 0) {
public int length;
public byte[] data;
public byte key;
- public static Random r = new Random(System.currentTimeMillis());
+ public static Random r = new Random();
public static Data createRandomData() {
int i = r.nextInt();
i = ( i % 127 );
public byte[] data;
public byte key;
public boolean hasNr = false;
- public static Random r = new Random(System.currentTimeMillis());
+ public static Random r = new Random();
public static Data createRandomData() {
return createRandomData(ChannelReceiver.MAX_UDP_SIZE);
}
public byte[] data;
public byte key;
public boolean error = false;
- public static Random r = new Random(System.currentTimeMillis());
+ public static Random r = new Random();
public static Data createRandomData(boolean error) {
int i = r.nextInt();
i = ( i % 127 );
public byte[] data;
public byte key;
public boolean hasNr = false;
- public static Random r = new Random(System.currentTimeMillis());
+ public static Random r = new Random();
public static Data createRandomData() {
return createRandomData(ChannelReceiver.MAX_UDP_SIZE);
}
}
public static class TestMsg implements Serializable {
- static Random r = new Random(System.currentTimeMillis());
+ static Random r = new Random();
HashMap<Integer, ArrayList<Object>> map =
new HashMap<Integer, ArrayList<Object>>();
public TestMsg() {