diff options
author | Arnold D. Robbins <arnold@skeeve.com> | 2016-04-06 06:00:28 +0300 |
---|---|---|
committer | Arnold D. Robbins <arnold@skeeve.com> | 2016-04-06 06:00:28 +0300 |
commit | 62342b5ad8522da5cbc0623f2b645c48b31c2838 (patch) | |
tree | 71cef270090969e33b68825dfa003efc25ff5602 /doc/gawktexi.in | |
parent | 525d6122c57db7b5f193b1fc22dc680a44f6c962 (diff) | |
parent | 43a645fe05c57576d9d41a7f3b18bb55b1dbdc3e (diff) | |
download | egawk-62342b5ad8522da5cbc0623f2b645c48b31c2838.tar.gz egawk-62342b5ad8522da5cbc0623f2b645c48b31c2838.tar.bz2 egawk-62342b5ad8522da5cbc0623f2b645c48b31c2838.zip |
Merge branch 'master' into feature/cmake
Diffstat (limited to 'doc/gawktexi.in')
-rw-r--r-- | doc/gawktexi.in | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/doc/gawktexi.in b/doc/gawktexi.in index e43d7137..f47c8459 100644 --- a/doc/gawktexi.in +++ b/doc/gawktexi.in @@ -26944,6 +26944,24 @@ As a side note, the assignment @samp{LC_ALL=C} in the @command{sort} command ensures traditional Unix (ASCII) sorting from @command{sort}. This is not strictly necessary here, but it's good to know how to do this. +Be careful when closing the @code{"from"} end of a two-way pipe; in this +case @command{gawk} waits for the child process to exit, which may cause +your program to hang. (Thus, this particular feature is of much less +use in practice than being able to close the @code{"to"} end.) + +@quotation CAUTION +Normally, +it is a fatal error to write to the @code{"to"} end of a two-way +pipe which has been closed, and it is also a fatal error to read +from the @code{"from"} end of a two-way pipe that has been closed. + +You may set @code{PROCINFO["@var{command}", "NONFATAL"]} to +make such operations become nonfatal, in which case you then need +to check @code{ERRNO} after each @code{print}, @code{printf}, +or @code{getline}. +@xref{Nonfatal}, for more information. +@end quotation + @cindex @command{gawk}, @code{PROCINFO} array in @cindex @code{PROCINFO} array, and communications via ptys You may also use pseudo-ttys (ptys) for |