[asterisk-commits] kpfleming: branch 1.6.0 r230782 - in /branches/1.6.0: ./ channels/chan_sip.c
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Mon Nov 23 08:19:04 CST 2009
Author: kpfleming
Date: Mon Nov 23 08:19:01 2009
New Revision: 230782
URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=230782
Log:
Merged revisions 230773 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk
................
r230773 | kpfleming | 2009-11-23 08:15:48 -0600 (Mon, 23 Nov 2009) | 12 lines
Merged revisions 230772 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r230772 | kpfleming | 2009-11-23 08:13:56 -0600 (Mon, 23 Nov 2009) | 5 lines
Ensure that SDP parsing does not ignore the last line of the SDP.
(closes issue #16268)
Reported by: sgimeno
........
................
Modified:
branches/1.6.0/ (props changed)
branches/1.6.0/channels/chan_sip.c
Propchange: branches/1.6.0/
------------------------------------------------------------------------------
Binary property 'trunk-merged' - no diff available.
Modified: branches/1.6.0/channels/chan_sip.c
URL: http://svnview.digium.com/svn/asterisk/branches/1.6.0/channels/chan_sip.c?view=diff&rev=230782&r1=230781&r2=230782
==============================================================================
--- branches/1.6.0/channels/chan_sip.c (original)
+++ branches/1.6.0/channels/chan_sip.c Mon Nov 23 08:19:01 2009
@@ -5883,7 +5883,7 @@
{
int len = strlen(name);
- while (*start < req->sdp_end) {
+ while (*start <= req->sdp_end) {
const char *r = get_body_by_line(req->line[(*start)++], name, len);
if (r[0] != '\0')
return r;
@@ -5893,15 +5893,16 @@
}
/*! \brief Fetches the next valid SDP line between the 'start' line
- * and the 'stop' line. Returns the type ('a', 'c', ...) and
- * matching line in reference 'start' is updated with the next line number.
+ * and the 'stop' line (*excluding* the 'stop' line). Returns the type
+ * ('a', 'c', ...) and matching line in reference 'start' is updated with the
+ * next line number.
*/
static char get_sdp_line(int *start, int stop, struct sip_request *req, const char **value)
{
char type = '\0';
const char *line = NULL;
- if (stop > req->sdp_end || stop < req->sdp_start) stop = req->sdp_end;
+ if (stop > req->sdp_end || stop < req->sdp_start) stop = req->sdp_end + 1;
while (*start < stop) {
line = req->line[(*start)++];
More information about the asterisk-commits
mailing list