[asterisk-commits] file: branch 1.4 r49066 - /branches/1.4/main/rtp.c

asterisk-commits at lists.digium.com asterisk-commits at lists.digium.com
Fri Dec 29 22:46:58 MST 2006


Author: file
Date: Fri Dec 29 23:46:57 2006
New Revision: 49066

URL: http://svn.digium.com/view/asterisk?view=rev&rev=49066
Log:
If the Packet2Packet bridge is being broken because of a masquerade then attempt to read a frame in so the masquerade actually happens. Otherwise weirdness will occur. (issue #8696 reported by kjotte)

Modified:
    branches/1.4/main/rtp.c

Modified: branches/1.4/main/rtp.c
URL: http://svn.digium.com/view/asterisk/branches/1.4/main/rtp.c?view=diff&rev=49066&r1=49065&r2=49066
==============================================================================
--- branches/1.4/main/rtp.c (original)
+++ branches/1.4/main/rtp.c Fri Dec 29 23:46:57 2006
@@ -3000,6 +3000,10 @@
 		    (c1->tech_pvt != pvt1) ||
 		    (c0->masq || c0->masqr || c1->masq || c1->masqr)) {
 			ast_log(LOG_DEBUG, "Oooh, something is weird, backing out\n");
+			if ((c0->masq || c0->masqr) && (fr = ast_read(c0)))
+				ast_frfree(fr);
+			if ((c1->masq || c1->masqr) && (fr = ast_read(c1)))
+				ast_frfree(fr);
 			res = AST_BRIDGE_RETRY;
 			break;
 		}



More information about the asterisk-commits mailing list