Changeset 277:c94e4ea39f97 in freeDiameter
- Timestamp:
- Apr 23, 2010, 2:33:26 PM (14 years ago)
- Branch:
- default
- Phase:
- public
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
extensions/app_radgw/rgwx_acct.c
r275 r277 52 52 struct rgwp_config { 53 53 struct { 54 struct dict_object * Accounting_Record_Number; /* Accounting-Record-Number */ 54 55 struct dict_object * Accounting_Record_Type; /* Accounting-Record-Type */ 55 56 struct dict_object * Acct_Application_Id; /* Acct-Application-Id */ … … 175 176 176 177 /* Resolve all dictionary objects we use */ 178 CHECK_FCT( fd_dict_search( fd_g_config->cnf_dict, DICT_AVP, AVP_BY_NAME, "Accounting-Record-Number", &new->dict.Accounting_Record_Number, ENOENT) ); 177 179 CHECK_FCT( fd_dict_search( fd_g_config->cnf_dict, DICT_AVP, AVP_BY_NAME, "Accounting-Record-Type", &new->dict.Accounting_Record_Type, ENOENT) ); 178 180 CHECK_FCT( fd_dict_search( fd_g_config->cnf_dict, DICT_AVP, AVP_BY_NAME, "Acct-Application-Id", &new->dict.Acct_Application_Id, ENOENT) ); … … 288 290 int send_str=0; 289 291 uint32_t str_cause=0; 292 uint32_t e2eid = 0; 290 293 application_id_t auth_appl=0; 291 294 int got_id = 0; … … 428 431 CHECK_FCT( fd_msg_avp_setvalue ( avp, &value ) ); 429 432 CHECK_FCT( fd_msg_avp_add ( *diam_fw, MSG_BRW_LAST_CHILD, avp) ); 433 434 /* save the end to end id */ 435 e2eid = header->msg_eteid; 430 436 } 431 437 … … 736 742 CHECK_FCT( fd_msg_avp_setvalue ( avp, &value ) ); 737 743 CHECK_FCT( fd_msg_avp_add ( *diam_fw, MSG_BRW_LAST_CHILD, avp) ); 744 745 /* While here, we also add the Accouting-Record-Number AVP. 746 We don't have a dedicated counter nor a state, so we just use the Diameter message End-to-end id here, which fits the conditions on the value. */ 747 CHECK_FCT( fd_msg_avp_new ( cs->dict.Accounting_Record_Number, 0, &avp ) ); 748 value.u32 = e2eid; 749 CHECK_FCT( fd_msg_avp_setvalue ( avp, &value ) ); 750 CHECK_FCT( fd_msg_avp_add ( *diam_fw, MSG_BRW_LAST_CHILD, avp) ); 751 738 752 break; 739 753
Note: See TracChangeset
for help on using the changeset viewer.