MCPcopy Create free account
hub / github.com/OpenSIPS/opensips / pv_set_ruri_user

Function pv_set_ruri_user

pvar.c:3430–3455  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3428}
3429
3430static int pv_set_ruri_user(struct sip_msg* msg, pv_param_t *param,
3431 int op, pv_value_t *val)
3432{
3433 str sval;
3434
3435 if(msg==NULL || param==NULL)
3436 {
3437 LM_ERR("bad parameters\n");
3438 return -1;
3439 }
3440
3441 if(val == NULL)
3442 sval = str_empty;
3443 else if(!(val->flags&PV_VAL_STR)) {
3444 LM_ERR("str value required to set R-URI user\n");
3445 return -1;
3446 } else
3447 sval = val->rs;
3448
3449 if (rewrite_ruri(msg, &sval, 0, RW_RURI_USER) < 0) {
3450 LM_ERR("Failed to set R-URI user\n");
3451 return -1;
3452 }
3453
3454 return 0;
3455}
3456
3457static int pv_set_ruri_host(struct sip_msg* msg, pv_param_t *param,
3458 int op, pv_value_t *val)

Callers

nothing calls this directly

Calls 1

rewrite_ruriFunction · 0.85

Tested by

no test coverage detected