andy dougherty uloqorhilafayetteedu wed 10 oct 2007 wncryptorg wrote andy dougherty via rt wrote im trying track problem ipccmdruncmd loses output cmd prints stderr doesnt print anything stdout ive traced problem following bit code ipccmdpm sub _open3_run following loop note loop exits last whenever stdout processing kidout complete whether stderr processing complete case ready kidout kiderror kidout empty completely skips reading kiderror yet comment appears deliberate dont know anyone looks like thinko could ask theorbtwo think still active least perlmonks id figure use perlmonks imagine probably old account somewhere fix think easiest approach spirit existing code replace c block loops read remaining data stderr breaking ive attached fix essentially problem turns stderr stdout arrive order one completed even available hence wait perlcurrentlibipccmdpm 20061128 114404000000000 0500 perlandylibipccmdpm 20071011 081944000000000 0400 4376 4378 add epxlicit break statement code courtesy theorbtwo londonpm stdout_done 0 stderr_done 0 outer ready selectorcan_read h ready 4579 45912 would print anyway wed provide bogus information _out_handler buf len h kidout _err_handler buf len h kiderror child process done printing last outer h kidout len 0 wait till child process done printing stdout stderr stdout_done 1 h kidout len 0 stderr_done 1 h kiderror len 0 last outer stdout_done stderr_done andy dougherty uloqorhilafayetteedu wed 06 aug 2008 025413 0400 patch perl 46293 ipccmd lose stderr