[Asterisk-cvs] asterisk/channels chan_sip.c,1.443,1.444

markster at lists.digium.com markster at lists.digium.com
Fri Jul 9 07:17:47 CDT 2004


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

Modified Files:
	chan_sip.c 
Log Message:
Expire time fix (bug #1996)


Index: chan_sip.c
===================================================================
RCS file: /usr/cvsroot/asterisk/channels/chan_sip.c,v
retrieving revision 1.443
retrieving revision 1.444
diff -u -d -r1.443 -r1.444
--- chan_sip.c	9 Jul 2004 10:46:50 -0000	1.443
+++ chan_sip.c	9 Jul 2004 11:03:33 -0000	1.444
@@ -6463,8 +6463,10 @@
 							contact = __get_header(req, "Contact", &start);
 							/* this loop ensures we get a contact header about our register request */
 							if(!ast_strlen_zero(contact)) {
-								if(strstr(contact, p->our_contact))
+								if( (tmptmp=strstr(contact, p->our_contact))) {
+									contact=tmptmp;
 									break;
+								}
 							} else
 								break;
 						}
@@ -6483,6 +6485,7 @@
 					else
 						expires_ms -= EXPIRY_GUARD_SECS * 1000;
 
+					r->refresh= (int) expires_ms / 1000;
 					r->expire=ast_sched_add(sched, expires_ms, sip_reregister, r); 
 				} else
 					ast_log(LOG_WARNING, "Got 200 OK on REGISTER that isn't a register\n");




More information about the svn-commits mailing list