anchor.diff:  handle_recv({ok, load_stream, Bulk}, S) ->
       gen_server:cast(self(), {save_rdb, Bulk}),
       {noreply, S#state{state=payload}}; % Next state will be 'payload'
  -handle_recv({error, Error}, S) ->
  -    {stop, socket_err, {S, Error}}.
  +handle_recv({error, Reason}, S) ->
  +    {stop, socket_err, {S, Reason}}.
   
   
   initial() ->
  
positive.code: handle_info({loading, eof}, State) ->
      io:format("rdb synchronization completed ~n"),
      {noreply, State};
  %%Generic
  handle_info(Msg, State) ->
      io:format("Generic info: '~p' '~p'~n",[Msg, State]),
      {noreply, State}.
  
negative.code: %% RDB LOAD
  handle_cast({load_rdb, Pid}, S = #state{state=payload}) ->
      io:format("load_rdb data -> ~p ~n", [Pid]),
      ok = rdb_load(Pid), % Fixme, rdb_load parse can be '{error, Reason}'
      gen_server:cast(self(), replication), % Move this to eof handle_info
      {noreply, S#state{state=stream}};
  
  %% Stream replication
  handle_cast(replication, S = #state{socket=Sock, state=stream}) ->
      io:format("receive stream ~n"),
      inet:setopts(Sock, [{active,once}]),
      io:format("foo ~n"),
      {noreply, S};
  
  %% Generic
  