Skip to content

Commit

Permalink
cfgt: updated to use xavp long value field
Browse files Browse the repository at this point in the history
  • Loading branch information
miconda committed Nov 22, 2022
1 parent 74f0c54 commit 96a174a
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions src/modules/cfgt/cfgt_json.c
Expand Up @@ -121,8 +121,8 @@ void _cfgt_get_obj_xavp_val(sr_xavp_t *avp, srjson_doc_t *jdoc, srjson_t **jobj)
return;
}
break;
case SR_XTYPE_INT:
*jobj = srjson_CreateNumber(jdoc, avp->val.v.i);
case SR_XTYPE_LONG:
*jobj = srjson_CreateNumber(jdoc, avp->val.v.l);
if(*jobj == NULL) {
LM_ERR("cannot create json object\n");
return;
Expand All @@ -139,10 +139,6 @@ void _cfgt_get_obj_xavp_val(sr_xavp_t *avp, srjson_doc_t *jdoc, srjson_t **jobj)
result = snprintf(
_pv_xavp_buf, 128, "%lu", (long unsigned)avp->val.v.t);
break;
case SR_XTYPE_LONG:
result = snprintf(
_pv_xavp_buf, 128, "%ld", (long unsigned)avp->val.v.l);
break;
case SR_XTYPE_LLONG:
result = snprintf(_pv_xavp_buf, 128, "%lld", avp->val.v.ll);
break;
Expand Down

0 comments on commit 96a174a

Please sign in to comment.