Skip to content

Commit

Permalink
rtpproxy: fix buffer dump of multiple media streams
Browse files Browse the repository at this point in the history
  • Loading branch information
razvancrainea committed Nov 2, 2021
1 parent 3a9b4a1 commit 86eabcf
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions modules/rtpproxy/rtpproxy.c
Expand Up @@ -3662,6 +3662,7 @@ static int rtpproxy_offer_answer(struct sip_msg *msg, struct rtpp_args *args,
body->len = 0;
}

newbody = v2p;
for(;;) {
/* Per-session iteration. */
v1p = v2p;
Expand Down Expand Up @@ -3973,7 +3974,6 @@ static int rtpproxy_offer_answer(struct sip_msg *msg, struct rtpp_args *args,
continue;

if (body) {
newbody = v1p;
if (o1p) {
tmpstr1.s = o1p;
tmpstr1.len = v2p - tmpstr1.s;
Expand Down Expand Up @@ -4053,8 +4053,9 @@ static int rtpproxy_offer_answer(struct sip_msg *msg, struct rtpp_args *args,
for (newbody = r2p; *newbody != '\r'; newbody++);
}
tmp.s = newbody;
tmp.len = bodylimit - newbody;
tmp.len = m2p - newbody;
RTPPROXY_APPEND(&tmp);
newbody = m2p;
} else {
/* Alter port. */
body1.s = m1p;
Expand Down

0 comments on commit 86eabcf

Please sign in to comment.