On Tue, Jan 20, 2009 at 8:12 AM, Norman Khine <[email protected]> wrote:
> Is this a safe way to generate random sound files on a web server?
>
>>>> from os import popen
>>>> merge = popen('sox uppercase-b.wav uppercase-a.wav merge.wav')

I'm not sure but you may have to read from merge to allow the process
to complete. You might want to use os.system() or one of the
subprocess replacements:
http://docs.python.org/library/subprocess.html#subprocess-replacements

if your webserver allows multiple simultaneous connections, and you
are going to serve merge.wav to a client, make sure you use different
names for each connection so they don't collide.

Kent
_______________________________________________
Tutor maillist  -  [email protected]
http://mail.python.org/mailman/listinfo/tutor

Reply via email to