# HG changeset patch # User Rob Mahurin # Date 1251265859 14400 # Node ID f5c28d8f5147006b7047dc21614b273330c8fbb8 # Parent b8db3595f706ad559ec4c5e803764d4e4228cf4a syscalls.cc: Recommend waitpid() in popen2() documentation. diff --git a/src/ChangeLog b/src/ChangeLog --- a/src/ChangeLog +++ b/src/ChangeLog @@ -2,6 +2,10 @@ * data.cc (Ffmod): Reverse order of args. +2009-08-26 Rob Mahurin + + * syscalls.cc: Recommend waitpid() in popen2() documentation. + 2009-08-25 John W. Eaton * graphics.cc (gnuplot_backend::send_quit): Wait for gnuplot process. diff --git a/src/syscalls.cc b/src/syscalls.cc --- a/src/syscalls.cc +++ b/src/syscalls.cc @@ -252,11 +252,16 @@ endif\n\ until (done)\n\ fclose (out);\n\ - @print{} are\n\ - @print{} some\n\ +waitpid (pid);\n\ + @print{} these\n\ @print{} strings\n\ - @print{} these\n\ + @print{} some\n\ + @print{} are\n\ @end example\n\ +\n\ +Note that @code{popen2}, unlike @code{popen}, will not \"reap\" the\n\ +child process. If you don't use @code{waitpid} to check the child's\n\ +exit status, it will linger until Octave exits. @end deftypefn") { octave_value_list retval;