Re: [Rd] Detect a terminated pipe

2014-03-14 Thread Simon Urbanek
On Mar 14, 2014, at 11:03 AM, Kirill Müller wrote: > On 03/14/2014 03:54 PM, Simon Urbanek wrote: >> As far as R is concerned, the connection is open. In addition, pipes exist >> even without the process - you can close one end of a pipe and it will still >> exist (that’s what makes pipes usef

Re: [Rd] Detect a terminated pipe

2014-03-14 Thread Kirill Müller
On 03/14/2014 03:54 PM, Simon Urbanek wrote: As far as R is concerned, the connection is open. In addition, pipes exist even without the process - you can close one end of a pipe and it will still exist (that’s what makes pipes useful, actually, because you can choose to close arbitrary combin

Re: [Rd] Detect a terminated pipe

2014-03-14 Thread Simon Urbanek
On Mar 14, 2014, at 8:09 AM, Kirill Müller wrote: > Hi > > Is there a way to detect that the process that corresponds to a pipe has > ended? On my system (Ubuntu 13.04), I see > > > p <- pipe("true", "w"); Sys.sleep(1); system("ps -elf | grep true | grep -v > > grep"); isOpen(p) > [1] TRUE >