asterisk/main
Richard Mudgett 4f7b859726 features: Fix channel datastore access.
Found as a result of the testsuite tests/callparking test crashing.

Several calls to ast_get_chan_featuremap_config() and
ast_get_chan_features_xfer_config() did not lock the channel before
calling so the channel's datastore list was accessed without the lock's
protection.  Apparently another thread deleted a datastore on the
channel's list while the crashing thread was walking the list.  Crash at
0xdeaddead due to MALLOC_DEBUG's memory filler value as a result.

* Add missing channel locks to calls that were not already protected
as the doxygen for those calls indicates.

Change-Id: Id273b3d305cc616406c353cbc841b2b7655efaa1
2016-06-30 15:38:11 -05:00
..
editline BuildSystem: Avoid 'ar cru' and use 'ar cr' instead. 2016-06-07 09:32:11 +02:00
stdtime BuildSystem: Fix a few issues hightlighted by gcc 6.x 2016-06-28 12:40:49 -05:00
.gitignore build-system: Allow building with static pjproject 2016-03-01 09:30:43 -07:00
Makefile Detect and use proper libraries for musl toolchains 2016-06-08 20:37:14 +03:00
abstract_jb.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
acl.c Restrict functionality when ACLs are misconfigured. 2015-04-30 10:43:51 -05:00
adsi.c Allow Asterisk to compile under GCC 4.10 2014-05-09 22:49:26 +00:00
alaw.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
aoc.c json: Audit ast_json_* usage for thread safety. 2015-12-16 15:21:14 -06:00
app.c main/app: Only look to end of file if ':end' is specified, and not just ':' 2016-03-23 13:53:31 -03:00
ast_expr2.c fix: memory leaks, resource leaks, out of bounds and bugs 2016-06-20 13:08:18 -04:00
ast_expr2.fl Git Conversion: Switch Non-C files to ASTERISK_REGISTER_FILE. 2015-04-29 01:02:10 -04:00
ast_expr2.h Allow the REALTIME() function to report errors back to the caller. 2012-07-11 17:16:50 +00:00
ast_expr2.y fix: memory leaks, resource leaks, out of bounds and bugs 2016-06-20 13:08:18 -04:00
ast_expr2f.c MALLOC_DEBUG: Replace WRAP_LIBC_MALLOC with ASTMM_LIBC. 2015-05-13 21:55:07 -04:00
asterisk.c core: Not the configured but granted number of possible file descriptors. 2016-06-10 21:04:44 +02:00
asterisk.dynamics Fix error loading res_monitor. 2014-04-23 15:02:39 +00:00
asterisk.exports.in pjproject_bundled: Various fixes discovered during testing of OSes 2016-05-03 07:56:18 -05:00
astfd.c astfd: With RLIMIT_NOFILE only the current value is sensible. 2016-06-10 10:13:20 +02:00
astmm.c astmm.c: Add more stats to CLI "memory show" commands. 2016-01-14 19:57:29 -06:00
astobj2.c Astobj2: Run weakproxy subscription callbacks in reverse order. 2015-05-22 17:09:47 -05:00
astobj2_container.c Astobj2: Allow reference debugging to be enabled/disabled by config. 2015-04-27 18:37:26 -04:00
astobj2_container_private.h Astobj2: Allow reference debugging to be enabled/disabled by config. 2015-04-27 18:37:26 -04:00
astobj2_hash.c Astobj2: Correctly treat hash_fn returning INT_MIN 2015-05-25 02:18:58 -05:00
astobj2_private.h Astobj2: Allow reference debugging to be enabled/disabled by config. 2015-04-27 18:37:26 -04:00
astobj2_rbtree.c Astobj2: Allow reference debugging to be enabled/disabled by config. 2015-04-27 18:37:26 -04:00
audiohook.c app_chanspy: reduce audio loss on the spying channel. 2016-04-27 15:39:59 +02:00
autochan.c app_chanspy: Fix occasional deadlock with ChanSpy and Local channels. 2016-03-11 16:05:30 -06:00
autoservice.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
backtrace.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
bridge.c Bridging: introduce "invisible" bridges. 2016-05-23 13:18:18 -05:00
bridge_after.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
bridge_basic.c Merge "bridge_basic: don't play an attended transfer fail sound after target hangs up" 2016-01-16 08:29:58 -06:00
bridge_channel.c features: Fix channel datastore access. 2016-06-30 15:38:11 -05:00
bridge_roles.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
bucket.c media cache: Add a core API and facade for a backend agnostic media cache 2015-07-12 20:44:16 -05:00
buildinfo.c fix a few small things found by using sparse 2008-10-30 16:49:02 +00:00
callerid.c SIP diversion: Fix REDIRECTING(reason) value inconsistencies. 2016-03-01 20:21:58 -06:00
ccss.c ccss.c: Replace space in taskprocessor name. 2016-01-08 21:05:16 -06:00
cdr.c Merge "stasis: Add setting subscription congestion levels." 2016-06-09 16:45:54 -05:00
cel.c Merge "cel: Ensure only one dial status per channel exists." 2016-06-09 22:38:52 -05:00
channel.c core/dial: New channel variable FORWARDERNAME 2016-06-04 11:07:22 -05:00
channel_internal_api.c channel api: Create is_t38_active accessor functions. 2016-02-29 12:50:43 -06:00
chanvars.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
cli.c Fixes to include signal.h 2016-06-08 20:37:08 +03:00
codec.c codecs: Fix ABI incompatibility created by adding format_name to ast_codec 2016-06-29 09:01:51 -05:00
codec_builtin.c codecs: Fix ABI incompatibility created by adding format_name to ast_codec 2016-06-29 09:01:51 -05:00
config.c config: Fix ast_config_text_file_save2 writability check for missing files 2016-04-25 18:17:28 -05:00
config_options.c Fix Alembic upgrades. 2016-06-22 12:23:44 -05:00
core_local.c bridge.c: Crash during attended transfer when missing a local channel half 2016-03-03 14:03:14 -06:00
core_unreal.c Bridge system: Fix memory leaks and double frees on impart failure. 2016-04-22 15:45:47 -05:00
crypt.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
cygload.c Kill off red blobs in most of main/* 2012-03-22 19:51:16 +00:00
data.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
datastore.c datastore: Add common container based datastores API. 2016-05-09 10:40:28 -03:00
db.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
devicestate.c devicestate: Cleanup engine thread during graceful shutdown. 2016-01-10 17:16:28 -06:00
dial.c core/dial: New channel variable FORWARDERNAME 2016-06-04 11:07:22 -05:00
dns.c Fix res_search usage 2016-06-02 22:57:49 +03:00
dns_core.c dns_core: Allow zero-length DNS responses. 2015-07-31 09:44:20 -05:00
dns_naptr.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
dns_query_set.c DNS: Fix some corner cases. 2015-06-10 18:06:15 -05:00
dns_recurring.c dns: Fix crash when invoking cancel in DNS recurring unit test. 2015-07-02 08:54:51 -03:00
dns_srv.c dns_srv: Fix SRV sorting when records with priority zero exist with non-zero. 2015-05-10 10:39:32 -03:00
dns_system_resolver.c dns: Change lookup failures from LOG_ERROR to debug 1. 2015-11-30 10:13:35 -07:00
dns_test.c dns: Fix build when TEST_FRAMEWORK is not defined. 2015-04-10 13:32:24 +00:00
dns_tlsa.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
dnsmgr.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
dsp.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
ecdisa.h Kill off red blobs in most of main/* 2012-03-22 19:51:16 +00:00
endpoints.c endpoint/stasis: Eliminate duplicate events on endpoint status change 2015-12-28 11:39:26 -06:00
enum.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
event.c Clang: change previous tautological-compare fixes. 2015-04-23 11:39:13 -05:00
features.c features: Fix channel datastore access. 2016-06-30 15:38:11 -05:00
features_config.c bridge_basic: don't cache xferfailsound during an attended transfer 2016-01-15 17:51:18 -06:00
file.c file: Ensure nativeformats remains valid for lifetime of use. 2016-05-05 11:02:48 -05:00
fixedjitterbuf.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
fixedjitterbuf.h Kill off red blobs in most of main/* 2012-03-22 19:51:16 +00:00
format.c format: Register format-attribute module with cached formats. 2015-11-13 09:32:52 +01:00
format_cache.c Astobj2: Allow reference debugging to be enabled/disabled by config. 2015-04-27 18:37:26 -04:00
format_cap.c Codecs: strip codec name while parsing allow/disallow options 2016-04-14 16:35:56 -05:00
format_compatibility.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
frame.c frame.c: Copy the whole subclass in ast_frdup(). 2016-04-06 11:10:49 -05:00
framehook.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
fskmodem.c Multiple revisions 369001-369002 2012-06-15 16:20:16 +00:00
fskmodem_float.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
fskmodem_int.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
global_datastores.c Detect potential forwarding loops based on count. 2015-04-17 15:58:07 -05:00
hashtab.c hashtab: Add NULL check when destroying iterator. 2015-11-14 08:06:48 -05:00
heap.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
http.c http: leverage 'bindaddr' for TLS in http.conf 2016-06-20 15:06:22 +02:00
image.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
indications.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
io.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
jitterbuf.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
json.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
libasteriskpj.c build-system: Allow building with static pjproject 2016-03-01 09:30:43 -07:00
libasteriskssl.c tcptls: Avoiding ERR_remove_state in OpenSSL. 2015-05-05 11:38:54 -05:00
libasteriskssl.exports.in Address OpenSSL initialization issues when using third-party libraries. 2012-01-30 21:21:16 +00:00
loader.c loader: Retry dlopen when loading fails 2016-03-03 15:38:01 -06:00
lock.c lock.c: Check *lt before dereferencing it 2016-04-21 11:07:18 -05:00
logger.c logging,cdr,cel: Fix stringfield memory leak. 2016-06-01 14:09:36 -05:00
manager.c stasis: Add setting subscription congestion levels. 2016-06-09 10:32:07 -05:00
manager_bridges.c Bridging: introduce "invisible" bridges. 2016-05-23 13:18:18 -05:00
manager_channels.c Expand the scope of Dial Events 2016-05-31 11:43:24 -05:00
manager_endpoints.c res_pjsip: Add AMI events for chan_pjsip contact lifecycle changes 2015-05-26 16:47:55 -05:00
manager_mwi.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
manager_system.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
max_forwards.c Detect potential forwarding loops based on count. 2015-04-17 15:58:07 -05:00
md5.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
media_cache.c media_cache: Demote warning to debug as it may occur often. 2016-03-25 10:22:36 -05:00
media_index.c media formats: re-architect handling of media for performance improvements 2014-07-20 22:06:33 +00:00
message.c CHAOS: cleanup possible null vars on msg alloc failure 2016-03-02 11:56:51 -06:00
mixmonitor.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
named_acl.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
named_locks.c lock: Add named lock capability 2016-04-08 13:52:02 -05:00
netsock.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
netsock2.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
optional_api.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
parking.c Modules: Make ast_module_info->self available to auxiliary sources. 2015-05-04 20:47:01 -04:00
pbx.c Merge "pbx.h: Make ast_state_cb_type take more const." 2016-04-08 15:47:50 -05:00
pbx_app.c main/pbx: Move dialplan application management routines to pbx_app.c. 2016-01-04 20:46:25 -05:00
pbx_builtins.c main/pbx: Move variable routines to pbx_variables.c. 2016-01-04 17:15:14 -05:00
pbx_functions.c main/pbx: Move custom function routines to pbx_functions.c. 2016-01-01 13:48:36 -05:00
pbx_hangup_handler.c main/pbx: Move hangup handler routines to pbx_hangup_handler.c. 2016-01-05 12:08:40 -05:00
pbx_private.h main/pbx: Move dialplan application management routines to pbx_app.c. 2016-01-04 20:46:25 -05:00
pbx_switch.c main/pbx: Move switch routines to pbx_switch.c. 2016-01-04 19:20:35 -05:00
pbx_timing.c main/pbx: Move timing routines to pbx_timing.c. 2016-01-04 19:00:23 -05:00
pbx_variables.c main/pbx: Move variable routines to pbx_variables.c. 2016-01-04 17:15:14 -05:00
pickup.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
plc.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
poll.c Merged revisions 285268 via svnmerge from 2010-09-07 19:09:08 +00:00
presencestate.c AMI: Escape string values. 2015-06-08 09:44:04 -05:00
privacy.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
rtp_engine.c res_rtp_asterisk: Use separate SRTP session for RTCP with DTLS 2016-03-29 10:57:55 -05:00
say.c BuildSystem: Fix a few issues hightlighted by gcc 6.x 2016-06-28 12:40:49 -05:00
sched.c sched.c: Ensure oldest expiring entry runs first. 2016-03-16 14:22:19 -05:00
sdp_srtp.c res_rtp_asterisk: Use separate SRTP session for RTCP with DTLS 2016-03-29 10:57:55 -05:00
security_events.c Clang: change previous tautological-compare fixes. 2015-04-23 11:39:13 -05:00
sem.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
sha1.c Doxygen Updates - janitor work 2012-09-21 17:14:59 +00:00
sip_api.c Don't make chan_sip export global symbols. 2012-10-11 15:49:02 +00:00
slinfactory.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
smoother.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
sorcery.c Fix Alembic upgrades. 2016-06-22 12:23:44 -05:00
sounds_index.c Replace most uses of ast_register_atexit with ast_register_cleanup. 2015-03-26 22:24:26 +00:00
srv.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
stasis.c stasis: Add setting subscription congestion levels. 2016-06-09 10:32:07 -05:00
stasis_bridges.c Bridging: introduce "invisible" bridges. 2016-05-23 13:18:18 -05:00
stasis_cache.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
stasis_cache_pattern.c endpoint/stasis: Eliminate duplicate events on endpoint status change 2015-12-28 11:39:26 -06:00
stasis_channels.c Expand the scope of Dial Events 2016-05-31 11:43:24 -05:00
stasis_endpoints.c res_pjsip: add "via_addr", "via_port", "call_id" to contact 2016-05-26 16:18:11 -05:00
stasis_message.c Manager: Short circuit AMI message processing. 2016-04-22 15:45:47 -05:00
stasis_message_router.c stasis: Add setting subscription congestion levels. 2016-06-09 10:32:07 -05:00
stasis_system.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
strcompat.c Add builtin roundf() for systems lacking it. 2013-01-19 20:54:07 +00:00
stringfields.c stringfields: Update extended string fields for master only. 2016-04-13 14:01:37 -06:00
strings.c Use doubles instead of floats for conversions when comparing strings. 2016-05-12 15:24:33 -05:00
stun.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
syslog.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
taskprocessor.c taskprocessors: Implement high/low water mark alerts. 2016-06-09 10:32:07 -05:00
tcptls.c Fixes to include signal.h 2016-06-08 20:37:08 +03:00
tdd.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
term.c main: Slight refactor of main. Improve color situation. 2015-11-25 20:29:55 +01:00
test.c test.c: Add unit test registration checks for summary and description. 2015-06-24 17:13:31 -05:00
threadpool.c threadpool: Fix potential data race. 2016-05-24 15:40:21 -05:00
threadstorage.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
timing.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
translate.c translate: Enables native Packet-Loss Concealment (PLC) for supporting codecs. 2016-06-10 12:40:00 -03:00
udptl.c udptl: Don't eat sequence numbers until OK is received 2016-05-18 14:06:09 -05:00
ulaw.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
uri.c uri: Quiet warning about type qualifiers ignored on function return type 2014-08-21 14:42:12 +00:00
utils.c stringfields: Refactor to allow fields to be added to the end of structures 2016-04-04 19:07:53 -05:00
uuid.c Fix printf problems with high ascii characters after r413586 (1.8). 2014-12-17 10:23:32 +00:00
xml.c git migration: Refactor the ASTERISK_FILE_VERSION macro 2015-04-13 03:48:57 -04:00
xmldoc.c xmldoc: Improve xmldoc wrapping of 'core show ...' output. 2015-11-06 08:46:24 -05:00