anchor.diff:      {reply, ok, State}.
   
   handle_cast(accept, #state{lsock=LSock}=State) ->
  -?Log(" handle_cast(accept conn ~p~n", [LSock]),
  +    ?Log("accept conn ~p~n", [LSock]),
       {ok, Sock} = gen_tcp:accept(LSock),
       {ok,Pid} = gen_server:start(?MODULE, [Sock, true], []),
       ok = gen_tcp:controlling_process(Sock, Pid),
  
positive.code:         {ok, ListenIf} when is_integer(ListenPort) ->
              case gen_tcp:listen(ListenPort, [binary, {packet, 0}, {active, false}, {ip, ListenIf}]) of
                  {ok, LSock} ->
                      ?Log(" ~p started imem_server ~p @ ~p~n", [self(), LSock, {ListenIf, ListenPort}]),
                      gen_server:cast(self(), accept),
                      {ok, #state{lsock=LSock}};
                  Reason ->
                      ?Log(" ~p [ERROR] imem_server not started ~p~n", [self(), Reason]),
                      {ok, #state{}}
              end;
          _ ->
  
negative.code:             handle_info({tcp,Sock,binary_part(NewBuf, {TSize, RestSize})}, State#state{buf= <<>>})
      end;
  handle_info({tcp_closed, _Sock}, State) ->
      ?Log("handle_info closed ~p~n", [_Sock]),
  	{stop, sock_close, State};
  handle_info(Info, State) ->
      ?Log("handle_info unknown ~p~n", [Info]),
  	{noreply, State}.
  
  terminate(_Reason, #state{csock=undefined}) -> ok;
  terminate(_Reason, #state{csock=Sock}) ->
      ?Log("~p closing tcp ~p~n", [self(), Sock]),
      gen_tcp:close(Sock).
  
  code_change(_OldVsn, State, _Extra) ->
  