Skip to content

tcp-client does not time out after remote abandons connection #20

@dedbox

Description

@dedbox

In the following example, cli should emit EOF on final recv:

tcp.rkt> (define svc (tcp-service sexp-codec 0 4 #t #f))
tcp.rkt> (svc 'address)
'("::" 33183 "0.0.0.0" 0)
tcp.rkt> (define cli (sexp-codec (tcp-client "localhost" 33183)))
tcp.rkt> (give cli 'x)
#t
tcp.rkt> (recv svc)
'("::1" 33183 "::1" 59664)
'x
tcp.rkt> (give svc '("::1" 33183 "::1" 59664) 'y)
#t
tcp.rkt> (recv cli)
'y
tcp.rkt> (stop svc)
tcp.rkt> (recv cli)         ;;; never returns
  C-c C-c; user break

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions