diff options
-rw-r--r-- | tclcompat.tcl | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/tclcompat.tcl b/tclcompat.tcl index 9496f46..262aae8 100644 --- a/tclcompat.tcl +++ b/tclcompat.tcl @@ -146,6 +146,12 @@ proc popen {cmd {mode r}} { if {$cmd eq "pid"} { return $pids } + if {$cmd eq "close"} { + $f close + # And wait for the child processes to complete + foreach p $pids { os.wait $p } + return + } tailcall $f $cmd {*}$args } } on error {error opts} { |