[asterisk-commits] russell: branch 1.4 r47497 - in /branches/1.4:
./ channels/chan_iax2.c
asterisk-commits at lists.digium.com
asterisk-commits at lists.digium.com
Sat Nov 11 23:23:23 MST 2006
Author: russell
Date: Sun Nov 12 00:23:23 2006
New Revision: 47497
URL: http://svn.digium.com/view/asterisk?view=rev&rev=47497
Log:
Merged revisions 47496 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.2
........
r47496 | russell | 2006-11-12 01:09:03 -0500 (Sun, 12 Nov 2006) | 4 lines
Only do the check to determine whether the channel calling this function is an
IAX2 channel when getting the IP address using the special argument,
CURRENTCHANNEL. (issue #8341, jcovert)
........
Modified:
branches/1.4/ (props changed)
branches/1.4/channels/chan_iax2.c
Propchange: branches/1.4/
------------------------------------------------------------------------------
Binary property 'branch-1.2-merged' - no diff available.
Modified: branches/1.4/channels/chan_iax2.c
URL: http://svn.digium.com/view/asterisk/branches/1.4/channels/chan_iax2.c?view=diff&rev=47497&r1=47496&r2=47497
==============================================================================
--- branches/1.4/channels/chan_iax2.c (original)
+++ branches/1.4/channels/chan_iax2.c Sun Nov 12 00:23:23 2006
@@ -9473,14 +9473,14 @@
struct iax2_peer *peer;
char *peername, *colname;
- if (chan->tech != &iax2_tech)
- return -1;
-
peername = ast_strdupa(data);
/* if our channel, return the IP address of the endpoint of current channel */
if (!strcmp(peername,"CURRENTCHANNEL")) {
- unsigned short callno = PTR_TO_CALLNO(chan->tech_pvt);
+ unsigned short callno;
+ if (chan->tech != &iax2_tech)
+ return -1;
+ callno = PTR_TO_CALLNO(chan->tech_pvt);
ast_copy_string(buf, iaxs[callno]->addr.sin_addr.s_addr ? ast_inet_ntoa(iaxs[callno]->addr.sin_addr) : "", len);
return 0;
}
More information about the asterisk-commits
mailing list