gen_tcp bug?

Luke Gorrie <>
Mon Aug 9 18:17:22 CEST 2004

"Bernardo Paroli" <> writes:

>  I have noticed that when a conecction is established and if I
> disconnect the network cable and connect this 30 seconds later the
> gen_tcp:send function locks infinitely but it doesn't fail(this lock
> happens at prim_inet:send/2).
> Why does this happen ? Why doesn't the gen_tpc:send/2 function fail?

How long do you wait before giving up?

Generally if you have an outage for N seconds then it will take TCP up
to N*2 seconds to retransmit and recover. So you should wait at least
a minute after putting the plug back in.


More information about the erlang-questions mailing list