anchor.diff:  		end,
   		case decrement_balance(Subscriber, Usage) of
   			{ok, OverUsed, false} when OverUsed =< 0 ->
  -				send_answer(SId, Subscriber, Balance, ?'DIAMETER_BASE_RESULT-CODE_SUCCESS',
  +				send_answer(Request, SId, Subscriber, Balance, ?'DIAMETER_BASE_RESULT-CODE_SUCCESS',
   						OHost, ORealm, ?CC_APPLICATION_ID, RequestType,
   						RequestNum, State);
   			{ok, _SufficientBalance, _Flags} ->
  -				send_answer(SId, Subscriber, Balance, ?'DIAMETER_BASE_RESULT-CODE_SUCCESS',
  +				send_answer(Request, SId, Subscriber, Balance, ?'DIAMETER_BASE_RESULT-CODE_SUCCESS',
   						OHost, ORealm, ?CC_APPLICATION_ID, RequestType,
   						RequestNum, State);
   			{error, not_found} ->
   				error_logger:warning_report(["diameter accounting subscriber not found",
   						{module, ?MODULE}, {subscriber, Subscriber},
   						{origin_host, OHost}]),
  -				send_error(SId, Subscriber, Balance, ?'DIAMETER_BASE_RESULT-CODE_UNABLE_TO_COMPLY',
  +				send_error(Request, SId, Subscriber, Balance, ?'DIAMETER_BASE_RESULT-CODE_UNABLE_TO_COMPLY',
   						OHost, ORealm, ?CC_APPLICATION_ID, RequestType,
   						RequestNum, State)
   		end
   	catch
   		_:_ ->
  -			send_error(SId, Subscriber, Balance, ?'DIAMETER_BASE_RESULT-CODE_UNABLE_TO_COMPLY',
  +			send_error(Request, SId, Subscriber, Balance, ?'DIAMETER_BASE_RESULT-CODE_UNABLE_TO_COMPLY',
   					OHost, ORealm, ?CC_APPLICATION_ID, RequestType,
   					RequestNum, State)
   	end;
   request1(?'DIAMETER_CC_APP_CC-REQUEST-TYPE_TERMINATION_REQUEST' = RequestType,
  -		_Request, SId, RequestNum, Subscriber, Balance, OHost, ORealm, State) ->
  +		Request, SId, RequestNum, Subscriber, Balance, OHost, ORealm, State) ->
   	F = fun() ->
   		case mnesia:read(subscriber, Subscriber, write) of
   			[#subscriber{disconnect = false} = Entry] ->
  
positive.code: 				Reply :: #diameter_cc_app_CCA{}.
  %% @doc Send CCA to Diameter client indicating a successful operation.
  %% @hidden
  send_answer(SId, Subscriber, Balance, ResultCode, OHost, ORealm, AuthAppId, RequestType,
  		RequestNum, #state{address = Address, port = Port} = State) ->
  	GrantedUnits = #'diameter_cc_app_Granted-Service-Unit'{'CC-Total-Octets' = Balance},
  	Reply = #diameter_cc_app_CCA{'Session-Id' = SId, 'Result-Code' = ResultCode,
  
negative.code: 					{subscriber, Subscriber}, {origin_host, OHost},
  					{origin_realm, ORealm},{session, SId}, {state, State},
  					{reason, Reason}]),
  			send_error(Request, SId, Subscriber, Balance, ?'DIAMETER_BASE_RESULT-CODE_UNABLE_TO_COMPLY',
  					OHost, ORealm, ?CC_APPLICATION_ID, RequestType,
  					RequestNum, State)
  	end.
  
  -spec send_answer(Request, SessionId, Subscriber, Balance, ResultCode, OriginHost, OriginRealm,
  		AuthAppId, RequestType, RequestNum, State) -> Result
  			when
  				Request :: #diameter_cc_app_CCR{},
  				SessionId :: string(),
  				Subscriber :: string() | binary(),
  				Balance :: integer(),
  