anchor.diff:      PStats = [{Protocol, Count} || {Protocol,{_Stats,Count}} <- Stats],
       {reply, PStats, State};
   
  +handle_call({register_service, Protocol, Strategy},  _From, State) ->
  +    NewDict = handle_register_service(Protocol,
  +                                      Strategy,
  +                                      State#state.services),
  +    {reply, ok, State#state{services=NewDict}};
  +
  +handle_call({unregister_service, ProtocolId}, _From, State) ->
  +    NewDict = handle_unregister_service(ProtocolId, State#state.services),
  +    {reply, ok, State#state{services=NewDict}};
  +
   handle_call(_Unhandled, _From, State) ->
       ?TRACE(?debugFmt("Unhandled gen_server call: ~p", [_Unhandled])),
       {reply, {error, unhandled}, State}.
   
   handle_cast({register_service, Protocol, Strategy}, State) ->
  -    {{ProtocolId,_Revs},_Rest} = Protocol,
  -    NewDict = orddict:store(ProtocolId, {Protocol, Strategy}, State#state.services),
  +    NewDict = handle_register_service(Protocol,
  +                                      Strategy,
  +                                      State#state.services),
       {noreply, State#state{services=NewDict}};
  - 
  +
   handle_cast({unregister_service, ProtocolId}, State) ->
  -    NewDict = orddict:erase(ProtocolId, State#state.services),
  +    NewDict = handle_unregister_service(ProtocolId, State#state.services),
       {noreply, State#state{services=NewDict}};
   
   handle_cast({register_stats_fun, Fun}, State) ->
  
positive.code:                                 ?MODULE, SubProtocols),
      lager:info("Service manager: listening on ~s:~p", [IP, Port]),
      {ok, Pid}.
  
negative.code:             gen_server:start_link({local, ?SERVER}, ?MODULE, Args, Options)
      end.
  
  %% @doc Once a protocol specification is registered, it will be kept
  %% available by the Service Manager. Note that the callee is responsible
  %% for taking ownership of the socket via
  %% Transport:controlling_process(Socket, Pid).  Only the strategy of
  %% `round_robin' is supported; it's arg is ignored.
  -spec(register_service(hostspec(), service_scheduler_strategy()) -> ok).
  register_service(HostProtocol, Strategy) ->
      %% only one strategy is supported as yet
      {round_robin, _NB} = Strategy,
      gen_server:cast(?SERVER, {register_service, HostProtocol, Strategy}).
  
  %% @doc Blocking version of register_service.
  -spec sync_register_service(hostspec(), service_scheduler_strategy()) -> ok.
  sync_register_service(HostProtocol, Strategy) ->
      %% only one strategy is supported as yet
      {round_robin, _NB} = Strategy,
      gen_server:call(?SERVER, {register_service, HostProtocol, Strategy}).
  
  %% @doc Unregister the given protocol-id. Existing connections for this
  %% protocol are not killed. New connections for this protocol will not be
  