It would have been helpful to see the contents of execEggplant. Is it really using exec? If so, the child's pid should be the same as the thing that exec'd it. >> Sorry. I should be more clear. My code uses ` ` (backward qoute?), which >> is the same as system(), I think. So it is not exec(), open(). execEggplant is a command that executes eggplant with a Eggplant script path as parameter. I also pipe the error to output.
$execEggplant = "runscript an_eggplant_script_path 2>$1" ## just from my memory. I don't have the script on hand right now. The reason I doesn't use exec is because I want to catch the output from Eggplant (it write its log to err). If I use exec(), then I wouldn't be able to see the output from that process. I have no experience with open() and took a look at it, and it doesn't seem to work for my case. I have used pid+1 for quite a few days now and it seems to work without any problem. But I still feel it is not the right thing to do. ted << If you use open(), the return value of open will be the pid of the pipe opened. If you use system(), you may be out of luck; I don't know. ...or is it the case that execEggplant exec's some script which then, itself runs Eggplant? In that case, you will have to roll your own IPC. -- rjbs
