You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@thrift.apache.org by Patrick Schlangen <p....@mac.com> on 2010/02/19 11:16:33 UTC

popen() / fork()

Hi,

is it safe to launch an external process by fork()/exec() or popen() from inside a TThreadedServer thread (from inside a service method implementation)?

Thanks in advance!

Patrick

Re: popen() / fork()

Posted by Rush Manbert <ru...@manbert.com>.
Hi Patrick,

I can't think of any limitations imposed because you're in a thread managed by the Thrift library. The threads are just POSIX, so whatever caveats there might be about spawning a child process in a pthread would apply, but nothing else.

Are you seeing problems?

- Rush

On Feb 19, 2010, at 2:16 AM, Patrick Schlangen wrote:

> Hi,
> 
> is it safe to launch an external process by fork()/exec() or popen() from inside a TThreadedServer thread (from inside a service method implementation)?
> 
> Thanks in advance!
> 
> Patrick