anchor.diff:  				RequestType :: integer(),
   				RequestNum :: integer(),
   				State :: state(),
  -				Result :: {reply, Reply, State},
  +				Result :: {Reply, State},
   				Reply :: #diameter_cc_app_CCA{}.
   %% @doc Send CCA to DIAMETER client indicating a operation faliure.
   %% @hidden
  -send_error(Request, SId, _Subscriber, _Balance, ResultCode, OHost, ORealm, AuthAppId, RequestType,
  +generate_diameter_error(Request, SId, _Subscriber, _Balance, ResultCode, OHost, ORealm, AuthAppId, RequestType,
   		RequestNum, #state{address = Address, port = Port} = State) ->
   	Reply = #diameter_cc_app_CCA{'Session-Id' = SId, 'Result-Code' = ResultCode,
   			'Origin-Host' = OHost, 'Origin-Realm' = ORealm,
  
positive.code: 			'CC-Request-Number' = RequestNum, 'Granted-Service-Unit' = GrantedUnits},
  	Server = {Address, Port},
  	ok = ocs_log:acct_log(diameter, Server, accounting_event_type(RequestType), Request),
  	{reply, Reply, State}.
  
  -spec send_error(Request, SessionId, Subscriber, Balance, ResultCode, OriginHost, OriginRealm,
  		AuthAppId, RequestType, RequestNum, State) -> Result
  			when
  				Request ::#diameter_cc_app_CCR{},
  
negative.code: 				AuthAppId :: integer(),
  				RequestType :: integer(),
  				RequestNum :: integer(),
  				Result :: {Reply, State},
  				State :: state(),
  				Reply :: #diameter_cc_app_CCA{}.
  %% @doc Send CCA to DIAMETER client indicating a successful operation.
  %% @hidden
  generate_diameter_answer(Request, 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,
  