Skip to content

Instantly share code, notes, and snippets.

@tilpner
Created April 4, 2016 20:14
Show Gist options
  • Save tilpner/492ae90e659f069f5ad22c5dab9207c4 to your computer and use it in GitHub Desktop.
Save tilpner/492ae90e659f069f5ad22c5dab9207c4 to your computer and use it in GitHub Desktop.
(use socket tcp6)
; Execute `nc -l -p 12345` in a terminal
; then run `csi -s timeout.scm`
(define s (tcp-connect "localhost" 12345))
(parameterize ((socket-receive-timeout 1000)
(tcp-read-timeout 1000))
(print (read-line s)))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment