anchor.diff:              lists:member(Sock#socket.tcp_state, TcpStates) ];
   sockets_in_state(S, TcpState) ->
     sockets_in_state(S, [TcpState]).
  -  
  +
   
   get_socket(S, Id) ->
     lists:keyfind(Id, #socket.id, S#state.sockets).
  
positive.code: do_close_callouts(S, [Id]) ->
    Sock = get_socket(S, Id),
    case Sock#socket.tcp_state of
      close_wait -> 
        ?APPLY(sent_fin, [Id]),
        ?SET(Id, tcp_state, last_ack);
      established -> 
        ?APPLY(sent_fin, [Id]),
        ?SET(Id, tcp_state, fin_wait_1);
      _ ->
  
negative.code:       false
    end.
  
  close_adapt(S, [_, Id]) ->
    case get_socket(S, Id) of
      #socket{socket = Socket} ->
        [Socket, Id];
  