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

Function get_naptr_proto

resolve.c:1348–1368  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1346
1347
1348static inline int get_naptr_proto(struct naptr_rdata *n)
1349{
1350 if (n->services[3]=='s' || n->services[3]=='S' )
1351 return PROTO_TLS;
1352 switch (n->services[n->services_len-1]) {
1353 case 'U':
1354 case 'u':
1355 return PROTO_UDP;
1356 break;
1357 case 'T':
1358 case 't':
1359 return PROTO_TCP;
1360 break;
1361 case 'S':
1362 case 's':
1363 return PROTO_SCTP;
1364 break;
1365 }
1366 LM_CRIT("failed to detect proto\n");
1367 return PROTO_NONE;
1368}
1369
1370
1371

Callers 2

srv2dns_nodeFunction · 0.85
sip_resolvehostFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected