29 Aug
2008
29 Aug
'08
1:47 p.m.
On Fri, 29 Aug 2008 13:35:24 -0000, glyph@divmod.com wrote:
On 09:06 am, gabriel.rossetti@arimaz.com wrote:
[snip] Should I just use python's fock() instead? Is it safe with Twisted?
[snip]
Using fork() in Python has a lot of confusing issues associated with it unless you're going to exec() immediately afterwards. You probably want to stick to one of these other approaches.
You also need to do some other stuff before you call fork(), like close file descriptors and disable garbage collection. And then re-enable it in the parent after the fork(). There's probably even some more things that are necessary that no one has realized yet. Jean-Paul