MCPcopy Create free account
hub / github.com/RangeNetworks/openbts / xmlFind

Function xmlFind

SIP/SIPDialog.cpp:702–714  ·  view source on GitHub ↗

Look for blah in xmlin and return "blah".

Source from the content-addressed store, hash-verified

700
701// Look for <tag>blah</tag> in xmlin and return "blah".
702static string xmlFind(const char *xmlin, const char *tag)
703{
704 char tagbuf[56];
705 assert(strlen(tag) < 50);
706 sprintf(tagbuf,"<%s>",tag);
707 const char *start = strstr(xmlin,tagbuf);
708 if (!start) return string("");
709 const char *result = start + strlen(tagbuf);
710 sprintf(tagbuf,"</%s>",tag);
711 const char *end = strstr(start,tagbuf);
712 if (!start) return string("");
713 return string(result,end-result);
714}
715
716// The incoming USSD BYE message could have a payload to be sent to the MS.
717void SipDialog::handleUssdBye(SipMessage *msg)

Callers 1

handleUssdByeMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected