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

Function pv_set_ruri_host

pvar.c:3457–3478  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3455}
3456
3457static int pv_set_ruri_host(struct sip_msg* msg, pv_param_t *param,
3458 int op, pv_value_t *val)
3459{
3460 if(msg==NULL || param==NULL || val==NULL)
3461 {
3462 LM_ERR("bad parameters\n");
3463 return -1;
3464 }
3465
3466 if(!(val->flags&PV_VAL_STR))
3467 {
3468 LM_ERR("str value required to set R-URI hostname\n");
3469 return -1;
3470 }
3471
3472 if (rewrite_ruri(msg, &val->rs, 0, RW_RURI_HOST) < 0) {
3473 LM_ERR("Failed to set R-URI hostname\n");
3474 return -1;
3475 }
3476
3477 return 0;
3478}
3479
3480static int pv_set_dsturi_host(struct sip_msg* msg, pv_param_t *param,
3481 int op, pv_value_t *val)

Callers

nothing calls this directly

Calls 1

rewrite_ruriFunction · 0.85

Tested by

no test coverage detected