﻿id	summary	reporter	owner	description	type	status	milestone	component	version	severity	resolution	keywords	cc
2116	random() is not random	davegrave@…		"There seems to be a bug if you use random() in multiple simultanously running instances of your compiled scripts. They return identically random numbers. I attached main script and stdout3.au3 which has to be compiled.

Main script calls stdout3.exe three times and communicates via stdout/stdin with the 3 workers.

Tried several things to fix it, like setting srandom(timerinit()) seed on each worker and doing short sleeps between the start commands in main.au3. Even with big sleeps (800ms) there are returned identical random numbers from worker threads.

Console Output looks like this:


{{{
thread started 1
thread started 2
thread started 3
I am working (4430)! 1
I am working (4430)! 2
I am working (4430)! 3
}}}

Problem can be solved by using the threadident variable for random range (see _random() in stdout3 script). Another workaround is to use srandom(@MSEC) inside the stdout3.au3, but it results sometimes in 2 identical random thread results."	Bug	closed		AutoIt	3.3.6.1	None	No Bug		
