| 3428 | } |
| 3429 | |
| 3430 | static 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 | |
| 3457 | static int pv_set_ruri_host(struct sip_msg* msg, pv_param_t *param, |
| 3458 | int op, pv_value_t *val) |
nothing calls this directly
no test coverage detected