[Asterisk-cvs] asterisk/channels chan_sip.c,1.701,1.702

russell at lists.digium.com russell at lists.digium.com
Wed Apr 6 12:11:12 CDT 2005


Update of /usr/cvsroot/asterisk/channels
In directory mongoose.digium.com:/tmp/cvs-serv15861/channels

Modified Files:
	chan_sip.c 
Log Message:
actually space out the registrations :)  (bug #3104)


Index: chan_sip.c
===================================================================
RCS file: /usr/cvsroot/asterisk/channels/chan_sip.c,v
retrieving revision 1.701
retrieving revision 1.702
diff -u -d -r1.701 -r1.702
--- chan_sip.c	5 Apr 2005 23:34:56 -0000	1.701
+++ chan_sip.c	6 Apr 2005 17:03:50 -0000	1.702
@@ -10754,11 +10754,12 @@
 /*--- sip_send_all_registers: Send all known registrations */
 static void sip_send_all_registers(void)
 {
-	int ms = (rand() >> 12) & 0x1fff;
+	int ms;
 	ASTOBJ_CONTAINER_TRAVERSE(&regl, 1, do {
 		ASTOBJ_WRLOCK(iterator);
 		if (iterator->expire > -1)
 			ast_sched_del(sched, iterator->expire);
+		ms = (rand() >> 12) & 0x1fff;
 		iterator->expire = ast_sched_add(sched, ms, sip_reregister, iterator);
 		ASTOBJ_UNLOCK(iterator);
 	} while (0)




More information about the svn-commits mailing list