21.18. Function EXT:STREAM-HANDLES

The function (EXT:STREAM-HANDLES stream) returns two values:

  1. The OS file descriptor for the input side of the stream, or NIL if the stream is an output-only STREAM or if there is no file descriptor associated with it.
  2. The OS file descriptor for the output side of the stream, or NIL if the stream is an input-only STREAM or if there is no file descriptor associated with it.

Warning

It is dangerous to CLOSE the file descriptors returned by this function. This may lead to EBADF OS ERRORs and, eventually, segmentation faults. Always use CLOSE on the original Lisp streams instead.


These notes document CLISP version 2.49.93+Last modified: 2018-02-19