]> git.ipfire.org Git - thirdparty/tornado.git/commit
When forking multiple processes, properly initialize the random seed 138/head
authorAlberto García Hierro <alberto@garciahierro.com>
Mon, 13 Sep 2010 18:10:23 +0000 (20:10 +0200)
committerAlberto García Hierro <alberto@garciahierro.com>
Mon, 13 Sep 2010 18:30:52 +0000 (20:30 +0200)
commita352f5ed45e2c8647e87fecd9e9612f85aa45336
treec2b6d2ad169172f2e21931d369178220d60aca6f
parent98e4344fe66663d690003b39af3ac5808e499623
When forking multiple processes, properly initialize the random seed

Avoid seeding the random module with the same value in all processes.
If available, use the same method used by random.py, otherwise
generate a seed using the current time in milliseconds and the pid.
tornado/httpserver.py