dect
/
asterisk
Archived
13
0
Fork 0
This repository has been archived on 2022-02-17. You can view files and clone it, but cannot push or open issues or pull requests.
asterisk/funcs
mmichelson 91df49dd46 Merged revisions 140488 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r140488 | mmichelson | 2008-08-29 12:34:17 -0500 (Fri, 29 Aug 2008) | 22 lines

After working on the ao2_containers branch, I noticed
something a bit strange. In all cases where we provide
a callback function to ao2_container_alloc, the callback
function would only return 0 or CMP_MATCH. After inspecting
the ao2_callback() code carefully, I found that if you're
only looking for one specific item, then you should return
CMP_MATCH | CMP_STOP. Otherwise, astobj2 will continue
traversing the current bucket until the end searching for
more matches.

In cases like chan_iax2 where in 1.4, all the peers are
shoved into a single bucket, this makes for potentially
terrible performance since the entire bucket will be
traversed even if the peer is one of the first ones come
across in the bucket.

All the changes I have made were for cases where the 
callback function defined was passed to ao2_container_alloc
so that calls to ao2_find could find a unique instance
of whatever object was being stored in the container.


........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@140489 f38db490-d61c-443f-a65b-d21fe96a405b
2008-08-29 17:47:17 +00:00
..
Makefile Merged revisions 93180 via svnmerge from 2007-12-17 07:25:35 +00:00
func_base64.c remove some unnecessary includes. 2007-11-19 20:42:06 +00:00
func_blacklist.c remove some useless includes 2007-11-22 02:30:58 +00:00
func_callerid.c Merged revisions 90145 via svnmerge from 2007-11-29 00:28:10 +00:00
func_cdr.c Merged revisions 122046 via svnmerge from 2008-06-12 14:28:01 +00:00
func_channel.c Add some more IAX2-specific information about the channel to the CHANNEL() 2008-06-15 15:21:16 +00:00
func_config.c Continue merging in changes from resolve-shadow-warnings. funcs/ this time. 2008-08-07 01:07:40 +00:00
func_curl.c Merged revisions 134540 via svnmerge from 2008-07-30 19:55:31 +00:00
func_cut.c Reset default CUT delimiter back to '-' 2008-01-18 02:06:27 +00:00
func_db.c remove another set of redundant #include "asterisk/options.h" 2007-11-21 23:24:55 +00:00
func_devstate.c Add a \todo 2008-07-01 21:43:55 +00:00
func_dialgroup.c Merged revisions 140488 via svnmerge from 2008-08-29 17:47:17 +00:00
func_dialplan.c This function checks more than just contexts... 2007-12-27 09:13:07 +00:00
func_enum.c make datastore creation and destruction a generic API since it is not really channel related, and add the ability to add/find/remove datastores to manager sessions 2008-08-05 16:56:11 +00:00
func_env.c Merged revisions 95470 via svnmerge from 2007-12-31 20:33:21 +00:00
func_extstate.c Start untangling header inclusion in a way that does not affect 2007-11-16 20:04:58 +00:00
func_global.c make datastore creation and destruction a generic API since it is not really channel related, and add the ability to add/find/remove datastores to manager sessions 2008-08-05 16:56:11 +00:00
func_groupcount.c Merged revisions 97697 via svnmerge from 2008-01-10 15:12:08 +00:00
func_iconv.c implement "configure" checks for libiconv, and add the 2008-01-01 22:08:32 +00:00
func_lock.c make datastore creation and destruction a generic API since it is not really channel related, and add the ability to add/find/remove datastores to manager sessions 2008-08-05 16:56:11 +00:00
func_logic.c another bunch of include removals (errno.h and asterisk/logger.h) 2007-11-19 19:09:03 +00:00
func_math.c another bunch of include removals (errno.h and asterisk/logger.h) 2007-11-19 19:09:03 +00:00
func_md5.c remove some useless includes 2007-11-22 02:30:58 +00:00
func_module.c remove some useless includes 2007-11-22 02:30:58 +00:00
func_odbc.c Continue merging in changes from resolve-shadow-warnings. funcs/ this time. 2008-08-07 01:07:40 +00:00
func_rand.c remove another set of redundant #include "asterisk/options.h" 2007-11-21 23:24:55 +00:00
func_realtime.c Older versions of GNU gcc do not allow 'NULL' as sentinel. 2008-06-19 20:48:33 +00:00
func_sha1.c remove some useless includes 2007-11-22 02:30:58 +00:00
func_shell.c another bunch of include removals (errno.h and asterisk/logger.h) 2007-11-19 19:09:03 +00:00
func_speex.c make datastore creation and destruction a generic API since it is not really channel related, and add the ability to add/find/remove datastores to manager sessions 2008-08-05 16:56:11 +00:00
func_strings.c Merged revisions 138023 via svnmerge from 2008-08-15 15:03:32 +00:00
func_sysinfo.c Fixes sysinfo operator issue also fixed elsewhere in r131445. 2008-07-16 21:54:08 +00:00
func_timeout.c Continue merging in changes from resolve-shadow-warnings. funcs/ this time. 2008-08-07 01:07:40 +00:00
func_uri.c another bunch of include removals (errno.h and asterisk/logger.h) 2007-11-19 19:09:03 +00:00
func_version.c Simplify a trivial snprintf() with ast_copy_string() 2008-03-04 04:57:29 +00:00
func_vmcount.c remove another set of redundant #include "asterisk/options.h" 2007-11-21 23:24:55 +00:00
func_volume.c make datastore creation and destruction a generic API since it is not really channel related, and add the ability to add/find/remove datastores to manager sessions 2008-08-05 16:56:11 +00:00