Skip to content

Commit 56fde8b

Browse files
author
Petr Cisar
committed
Updated the style. updated the DTD to allow regex
1 parent 3f30991 commit 56fde8b

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

sipp.dtd

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525

2626
<!ELEMENT recv ( action? ) >
2727
<!ATTLIST recv %messageCmdCommon; >
28-
<!ATTLIST recv response NMTOKEN #IMPLIED >
28+
<!ATTLIST recv response CDATA #IMPLIED >
2929
<!ATTLIST recv request CDATA #IMPLIED >
3030
<!ATTLIST recv optional (true|false) #IMPLIED >
3131
<!ATTLIST recv ignosesdp (true|false) #IMPLIED >

src/call.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -4454,7 +4454,7 @@ bool call::matches_scenario(unsigned int index, int reply_code, char * request,
44544454
} else if (curmsg->recv_response) {
44554455
if (curmsg->regexp_match) { // Match response code using regex
44564456
char reply_code_str[8];
4457-
snprintf(reply_code_str,8,"%u",reply_code); // Convert the response code to string
4457+
snprintf(reply_code_str, 8, "%u", reply_code); // Convert the response code to string
44584458
if (curmsg->regexp_compile == nullptr) {
44594459
regex_t *re = new regex_t;
44604460
/* No regex match position needed (NOSUB), we're simply
@@ -4469,7 +4469,7 @@ bool call::matches_scenario(unsigned int index, int reply_code, char * request,
44694469
return false;
44704470
}
44714471
} else { // Exact numerical match
4472-
if (atoi(curmsg->recv_response)!=reply_code) {
4472+
if (atoi(curmsg->recv_response) != reply_code) {
44734473
return false;
44744474
}
44754475
}

0 commit comments

Comments
 (0)