anchor.diff:  %% a local create_channel will spawn a channel process that will
   %% dispatch the message for us.
   processOut(State, M) -> processOut(State, M, undefined).
  -processOut(State, M=#channel_create{id=Id}, Cfg) ->
  +processOut(State, M, Cfg) -> processOut(State, M, Cfg, undefined).
  +processOut(State, M=#channel_create{id=Id}, Cfg, Data) ->
       case ets:info(?tid(State), size) > ?max_chans(State) of
   	true -> {State, maxChans(Id, ?max_chans(State))};
   	false ->
   	    {ok,Pid} = client_channel:new(self(),M,Cfg),
  -	    case ets:insert_new(?tid(State), #chan{id = Id, remote = Pid}) of
  +	    case ets:insert_new(?tid(State),
  +				#chan{id = Id, remote = Pid, data = Data}) of
   		true -> {State, []};
   		false -> {State, dupId(Id)}
   	    end
       end;
   
  -processOut(State, M=#channel_message{id=Id},_Cfg) ->
  +processOut(State, M=#channel_message{id=Id}, _Cfg, _Data) ->
       case ets:lookup_element(?tid(State), Id, 3) of
           badarg -> {State, noSuchChannel(Id)};
           Pid -> fire(Pid,M),
   	       {State, []}
       end;
   
  -processOut(State,M=#channel_close{id=Id},_Cfg) ->
  +processOut(State, M=#channel_close{id=Id}, _Cfg, _Data) ->
       case ets:lookup_element(?tid(State), Id, 3) of
           badarg ->
               ?lwarn("Attempt to close unknown channel: ~p",[Id]),
  
positive.code:                {State, []}
      end.
  
  processIn(State, From,M=#channel_create{id=Id}) ->
      case ets:insert_new(?tid(State), #chan{id = Id, remote = From}) of
          true -> {State, M};
          false -> dupId(From,Id),
                  State
      end;
  
  processIn(State, From, M=#channel_message{id=Id}) ->
      case ets:member(?tid(State), Id) of
          false ->
              ?lwarn("Unknown channel: ~p from: ~p",[Id,From]),
              State;
          true -> {State, M}
      end;
  processIn(State,_From,M=#channel_close{id=Id}) ->
      ets:delete(?tid(State), Id),
      {State, M}.
  
  
negative.code: -include("mmd.hrl").
  -include_lib("p6core/include/logger.hrl").
  -export([new/0, new/1]).
  -export([handleExit/3, processOut/2, processOut/3, processOut/4]).
  -export([processIn/3, processIn/4]).
  -export([sendAll/2]).
  -export([refToIds/2, removeRef/2]).
  
  