Browse code

ims_charging: fixed check result code at mscc level (#1504)

* ims_charging: fixed check result code at mscc level

according to RFC 4006 the Result-Code in Multiple-Services-Credit-Control AVP is optional.
resume_on_initial_ccr() stops proceeding CCA if no Result-Code in MSCC and goes to error1 even though
the Result-Code on CCR itself is 2001 (SUCCESSFUL)

* ims_charging: fixed check result code at mscc level

according to RFC 4006 the Result-Code in Multiple-Services-Credit-Control AVP is optional.
resume_on_initial_ccr() stops proceeding CCA if no Result-Code in MSCC and goes to error1 even though
the Result-Code on CCR itself is 2001 (SUCCESSFUL)

yuri-r authored on 24/04/2018 10:39:07 • Daniel-Constantin Mierla committed on 24/04/2018 10:39:07
Showing 1 changed files
... ...
@@ -1361,7 +1361,7 @@ static void resume_on_initial_ccr(int is_timeout, void *param, AAAMessage *cca,
1361 1361
 	create_cca_fui_avps(fui_action, redirecturi);
1362 1362
 	
1363 1363
 	/* check result code at mscc level */
1364
-	if (ro_cca_data->mscc->resultcode != 2001) {
1364
+	if (ro_cca_data->mscc->resultcode && ro_cca_data->mscc->resultcode != 2001) {
1365 1365
 		LM_DBG("CCA failure at MSCC level with resultcode [%d]\n", ro_cca_data->mscc->resultcode);
1366 1366
 		error_code = RO_RETURN_FALSE;
1367 1367
         goto error1;