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

Function pv_get_srcip

pvar.c:1228–1239  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1226}
1227
1228static int pv_get_srcip(struct sip_msg *msg, pv_param_t *param,
1229 pv_value_t *res)
1230{
1231 str s;
1232 if(msg==NULL)
1233 return -1;
1234
1235 if ( (s.s=ip_addr2a(&msg->rcv.src_ip))==NULL)
1236 return pv_get_null(msg, param, res);
1237 s.len = strlen(s.s);
1238 return pv_get_strval(msg, param, res, &s);
1239}
1240
1241static int pv_get_srcport(struct sip_msg *msg, pv_param_t *param,
1242 pv_value_t *res)

Callers

nothing calls this directly

Calls 3

ip_addr2aFunction · 0.85
pv_get_nullFunction · 0.85
pv_get_strvalFunction · 0.85

Tested by

no test coverage detected