mirror of
				https://github.com/asterisk/asterisk.git
				synced 2025-10-31 02:37:10 +00:00 
			
		
		
		
	Merged revisions 176320 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk ........ r176320 | tilghman | 2009-02-16 17:14:08 -0600 (Mon, 16 Feb 2009) | 7 lines Use the correct list macros for deleting an item from the middle of a list. (issue #13777) Reported by: pj Patches: 20090203__bug13777.diff.txt uploaded by Corydon76 (license 14) Tested by: pj ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.1@176321 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
		| @@ -5867,9 +5867,9 @@ static void destroy_session(struct skinnysession *s) | ||||
| { | ||||
| 	struct skinnysession *cur; | ||||
| 	AST_LIST_LOCK(&sessions); | ||||
| 	AST_LIST_TRAVERSE(&sessions, cur, list) { | ||||
| 	AST_LIST_TRAVERSE_SAFE_BEGIN(&sessions, cur, list) { | ||||
| 		if (cur == s) { | ||||
| 			AST_LIST_REMOVE(&sessions, s, list); | ||||
| 			AST_LIST_REMOVE_CURRENT(list); | ||||
| 			if (s->fd > -1)  | ||||
| 				close(s->fd); | ||||
| 			 | ||||
| @@ -5880,6 +5880,7 @@ static void destroy_session(struct skinnysession *s) | ||||
| 			ast_log(LOG_WARNING, "Trying to delete nonexistent session %p?\n", s); | ||||
| 		} | ||||
| 	} | ||||
| 	AST_LIST_TRAVERSE_SAFE_END | ||||
| 	AST_LIST_UNLOCK(&sessions); | ||||
| } | ||||
|  | ||||
|   | ||||
		Reference in New Issue
	
	Block a user