anchor.diff:      end.
   
   %% Called when we're done and the socket can still be reused
  --spec checkin(host(), port_number(), SSL::boolean(), Socket::port()) -> ok.
  +-spec checkin(host(), port_number(), SSL::boolean(), Socket::socket()) -> ok.
   checkin(Host, Port, Ssl, Socket) ->
       case find_lb({Host,Port,Ssl}) of
           {error, undefined} ->
  
positive.code:             ets:delete(Tid, Pid)
      end.
  
  -spec remove_socket(port(), #state{}) -> #state{}.
  remove_socket(Socket, S = #state{ssl=Ssl, free=Free}) ->
      lhttpc_sock:close(Socket, Ssl),
      S#state{free=drop_and_cancel(Socket,Free)}.
  
  -spec drop_and_cancel(port(), [{port(), reference()}]) -> [{port(), reference()}].
  drop_and_cancel(_, []) -> [];
  drop_and_cancel(Socket, [{Socket, TimerRef} | Rest]) ->
      cancel_timer(TimerRef, Socket),
  
negative.code: -export_types([host/0, port_number/0, max_connections/0, connection_timeout/0]).
  -type host() :: inet:ip_address()|string().
  -type port_number() :: 1..65535.
  -type socket() :: gen_tcp:socket() | ssl:sslsocket().
  -type max_connections() :: pos_integer().
  -type connection_timeout() :: timeout().
  
  