OK so apparently fork() followed by setsid() is causing Qt to die.
Let's see if it is only one of them or both
1) Without fork()
calibre-debug -c "from calibre.gui2.main import main; import os, sys; os.setsid(); main()"
2) Without setsid()
calibre-debug -c "from calibre.gui2.main import main; import os, sys; os.fork() != 0 and sys.exit(0); main()"
Do either of these two crash?
OK so apparently fork() followed by setsid() is causing Qt to die.
Let's see if it is only one of them or both
1) Without fork()
calibre-debug -c "from calibre.gui2.main import main; import os, sys; os.setsid(); main()"
2) Without setsid()
calibre-debug -c "from calibre.gui2.main import main; import os, sys; os.fork() != 0 and sys.exit(0); main()"
Do either of these two crash?