[svn-commits] trunk r33595 - /trunk/channels/chan_iax2.c

svn-commits at lists.digium.com svn-commits at lists.digium.com
Sun Jun 11 19:54:32 MST 2006


Author: file
Date: Sun Jun 11 21:54:32 2006
New Revision: 33595

URL: http://svn.digium.com/view/asterisk?rev=33595&view=rev
Log:
Change a bit of logic in peer expiry back to the way it used to be

Modified:
    trunk/channels/chan_iax2.c

Modified: trunk/channels/chan_iax2.c
URL: http://svn.digium.com/view/asterisk/trunk/channels/chan_iax2.c?rev=33595&r1=33594&r2=33595&view=diff
==============================================================================
--- trunk/channels/chan_iax2.c (original)
+++ trunk/channels/chan_iax2.c Sun Jun 11 21:54:32 2006
@@ -5518,9 +5518,6 @@
 	AST_LIST_LOCK(&peers);
 	AST_LIST_TRAVERSE_SAFE_BEGIN(&peers, p, entry) {
 		if (!strcasecmp(p->name, name)) {
-			/* If we are set to auto clear then remove ourselves */
-			if (ast_test_flag(p, IAX_RTAUTOCLEAR))
-				AST_LIST_REMOVE_CURRENT(&peers, entry);
 			p->expire = -1;
 			break;
 		}
@@ -5546,8 +5543,8 @@
 		iax2_regfunk(p->name, 0);
 
 	if (ast_test_flag(p, IAX_RTAUTOCLEAR)) {
-		/* We are already gone from the list, so we can just destroy ourselves */
-		destroy_peer(p);
+		ast_set_flag(p, IAX_DELME);
+		prune_peers();
 	}
 }
 



More information about the svn-commits mailing list