blob: 106e44673c6838e178ca36614b9e5b2510cf1eac (
plain)
1
2
3
4
5
6
7
8
|
BEGIN {
# We use "&&" and not ";" so it works with Windows shells as well.
cmd = "cat - 1>&2 && sleep 2"
printf "%s\n", "test1" |& cmd
close(cmd, "to")
printf "%s\n", "test2" |& cmd
print ERRNO
}
|