Generic FunctionPackage: exclToCDocOverviewCGDocRelNotesFAQIndexPermutedIndex
Allegro CL version 10.1
Unrevised from 10.0 to 10.1.
10.0 version

stream-input-timeout

Arguments: simple-stream

This generic function returns the input timeout limit for simple-stream, which may be nil (no limit) or a positive integer noting how many seconds to wait for input before erroring because there is no input on the stream. See also the related stream-output-timeout.

Timeouts may be particularly useful for socket streams. The example is for demonstration only and is not recommended:

;; For demonstration only. Do not try this at home!
cl-user(3): (setf (stream-input-timeout *standard-output*) 3)

3
cl-user(4):  ;; we do not type anything and we get an error:
Error: #<stream-error @ #x10000e35692>
  [condition type: stream-error]

Restart actions (select using :continue):
 0: Return to Top Level (an "abort" restart).
 1: Abort entirely from this (lisp) process.
[1] cl-user(5): ;; repeated errors:
Error: #<stream-error @ #x10000e35692>
  [condition type: stream-error]

Restart actions (select using :continue):
 0: Return to Debug Level 1 (an "abort" restart).
 1: Return to Top Level (an "abort" restart).
 2: Abort entirely from this (lisp) process.
[2] cl-user(6): (setf (stream-input-timeout *standard-output*) nil)
    ;; we set the value back.

nil
[2] cl-user(7): :res
cl-user(8):  ;; no more errors.

Copyright (c) 1998-2022, Franz Inc. Lafayette, CA., USA. All rights reserved.
This page was not revised from the 10.0 page.
Created 2019.8.20.

ToCDocOverviewCGDocRelNotesFAQIndexPermutedIndex
Allegro CL version 10.1
Unrevised from 10.0 to 10.1.
10.0 version