clarify need to wait on a subprocess
svn: r14468
This commit is contained in:
parent
a1cc8d30a1
commit
12b81e0cd7
|
@ -73,7 +73,11 @@ The @scheme[subprocess] procedure returns four values:
|
||||||
|
|
||||||
@bold{Important:} All ports returned from @scheme[subprocess] must be
|
@bold{Important:} All ports returned from @scheme[subprocess] must be
|
||||||
explicitly closed with @scheme[close-input-port] or
|
explicitly closed with @scheme[close-input-port] or
|
||||||
@scheme[close-output-port].
|
@scheme[close-output-port]. Similarly, waiting on the subprocess value
|
||||||
|
(using @scheme[subprocess-wait] or @scheme[sync]) ensures that the
|
||||||
|
operating system can release the subprocess; for example,
|
||||||
|
exiting without waiting on a subprocess under Unix risks leaving the
|
||||||
|
subprocess as a zombie.
|
||||||
|
|
||||||
The returned ports are @tech{file-stream ports} (see
|
The returned ports are @tech{file-stream ports} (see
|
||||||
@secref["file-ports"]), and they are placed into the management of
|
@secref["file-ports"]), and they are placed into the management of
|
||||||
|
@ -85,7 +89,9 @@ communication.}
|
||||||
|
|
||||||
@defproc[(subprocess-wait [subproc subprocess?]) void?]{
|
@defproc[(subprocess-wait [subproc subprocess?]) void?]{
|
||||||
|
|
||||||
Blocks until the process represented by @scheme[subproc] terminates.}
|
Blocks until the process represented by @scheme[subproc]
|
||||||
|
terminates. The @scheme[subproc] value also can be used with
|
||||||
|
@scheme[sync] and @scheme[sync/timeout].}
|
||||||
|
|
||||||
|
|
||||||
@defproc[(subprocess-status [subproc subprocess?])
|
@defproc[(subprocess-status [subproc subprocess?])
|
||||||
|
|
Loading…
Reference in New Issue
Block a user