[asterisk-commits] russell: branch 1.2 r73678 - /branches/1.2/channels/chan_sip.c
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Fri Jul 6 10:55:41 CDT 2007
Author: russell
Date: Fri Jul 6 10:55:41 2007
New Revision: 73678
URL: http://svn.digium.com/view/asterisk?view=rev&rev=73678
Log:
(closes issue #10125)
Reported by: makoto
Patches submitted by: makoto
This fixes a crash in chan_sip that happens when the bindaddr setting is not
valid on Asterisk startup, gets fixed, and then a reload gets issued.
Modified:
branches/1.2/channels/chan_sip.c
Modified: branches/1.2/channels/chan_sip.c
URL: http://svn.digium.com/view/asterisk/branches/1.2/channels/chan_sip.c?view=diff&rev=73678&r1=73677&r2=73678
==============================================================================
--- branches/1.2/channels/chan_sip.c (original)
+++ branches/1.2/channels/chan_sip.c Fri Jul 6 10:55:41 2007
@@ -11672,8 +11672,12 @@
sip_do_reload();
/* Change the I/O fd of our UDP socket */
- if (sipsock > -1)
- sipsock_read_id = ast_io_change(io, sipsock_read_id, sipsock, NULL, 0, NULL);
+ if (sipsock > -1) {
+ if (sipsock_read_id)
+ sipsock_read_id = ast_io_change(io, sipsock_read_id, sipsock, NULL, 0, NULL);
+ else
+ sipsock_read_id = ast_io_add(io, sipsock, sipsock_read, AST_IO_IN, NULL);
+ }
}
/* Check for interfaces needing to be killed */
ast_mutex_lock(&iflock);
More information about the asterisk-commits
mailing list