mirror of
				https://github.com/asterisk/asterisk.git
				synced 2025-10-31 02:37:10 +00:00 
			
		
		
		
	Merged revisions 81426 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r81426 | mmichelson | 2007-09-01 01:02:06 -0500 (Sat, 01 Sep 2007) | 4 lines Making match_by_addr into ao2_match_by_addr and making it available everywhere since it could be a handy callback to have ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@81427 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
		| @@ -430,6 +430,7 @@ void *ao2_callback(ao2_container *c, | ||||
| 	enum search_flags flags, | ||||
| 	ao2_callback_fn cb_fn, void *arg); | ||||
|  | ||||
| int ao2_match_by_addr(void *user_data, void *arg, int flags); | ||||
| /*! | ||||
|  * | ||||
|  * | ||||
|   | ||||
| @@ -349,7 +349,7 @@ void *ao2_link(ao2_container *c, void *user_data) | ||||
| /*! | ||||
|  * \brief another convenience function is a callback that matches on address | ||||
|  */ | ||||
| static int match_by_addr(void *user_data, void *arg, int flags) | ||||
| int ao2_match_by_addr(void *user_data, void *arg, int flags) | ||||
| { | ||||
| 	return (user_data == arg) ? (CMP_MATCH | CMP_STOP) : 0; | ||||
| } | ||||
| @@ -363,7 +363,7 @@ void *ao2_unlink(ao2_container *c, void *user_data) | ||||
| 	if (INTERNAL_OBJ(user_data) == NULL)	/* safety check on the argument */ | ||||
| 		return NULL; | ||||
|  | ||||
| 	ao2_callback(c, OBJ_UNLINK | OBJ_POINTER | OBJ_NODATA, match_by_addr, user_data); | ||||
| 	ao2_callback(c, OBJ_UNLINK | OBJ_POINTER | OBJ_NODATA, ao2_match_by_addr, user_data); | ||||
|  | ||||
| 	return NULL; | ||||
| } | ||||
|   | ||||
		Reference in New Issue
	
	Block a user