Module: sip-router
Branch: master
Commit: eaa6473333649585c3098e00bb114d1041ff72bf
URL:
http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=eaa6473…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: Sat Jan 14 22:12:58 2012 +0100
core/tcp: use term from MSRP spec to name the variable
---
tcp_read.c | 20 ++++++++++----------
1 files changed, 10 insertions(+), 10 deletions(-)
diff --git a/tcp_read.c b/tcp_read.c
index 41fbbf7..05e4d44 100644
--- a/tcp_read.c
+++ b/tcp_read.c
@@ -381,7 +381,7 @@ int tcp_read_headers(struct tcp_connection *c, int* read_flags)
#ifdef READ_MSRP
char *mfline;
- str msessid;
+ str mtransid;
#endif
#define crlf_default_skip_case \
@@ -944,23 +944,23 @@ int tcp_read_headers(struct tcp_connection *c, int* read_flags)
r->state=H_MSRP_BODY;
break;
}
- /* locate session id in first line
+ /* locate transaction id in first line
* -- first line exists, that's why we are here */
mfline = q_memchr(r->start, '\n', r->pos-r->start);
- msessid.s = q_memchr(r->start + 5 /* 'MSRP ' */, ' ',
+ mtransid.s = q_memchr(r->start + 5 /* 'MSRP ' */, ' ',
mfline - r->start);
- msessid.len = msessid.s - r->start - 5;
- msessid.s = r->start + 5;
- trim(&msessid);
- if(memcmp(msessid.s,
- p - 1 /*\r*/ - 1 /* '+'|'#'|'$' */ - msessid.len,
- msessid.len)!=0) {
+ mtransid.len = mtransid.s - r->start - 5;
+ mtransid.s = r->start + 5;
+ trim(&mtransid);
+ if(memcmp(mtransid.s,
+ p - 1 /*\r*/ - 1 /* '+'|'#'|'$' */ - mtransid.len,
+ mtransid.len)!=0) {
/* no match on session id - not end-line */
p++;
r->state=H_MSRP_BODY;
break;
}
- if(memcmp(p - 1 /*\r*/ - 1 /* '+'|'#'|'$' */ - msessid.len
+ if(memcmp(p - 1 /*\r*/ - 1 /* '+'|'#'|'$' */ - mtransid.len
- 7 /* 7 x '-' */ - 1 /* '\n' */, "\n-------",
8)!=0) {
/* no match on "\n-------" - not end-line */