]> git.ipfire.org Git - thirdparty/asterisk.git/commit
Replace most uses of ast_register_atexit with ast_register_cleanup. 66/1466/1
authorCorey Farrell <git@cfware.com>
Thu, 26 Mar 2015 22:19:21 +0000 (22:19 +0000)
committerJoshua Colp <jcolp@digium.com>
Wed, 21 Oct 2015 14:11:49 +0000 (11:11 -0300)
commitcdd2d5b484aad2c932bed98edf75933532d2cb46
tree6bdff8211ec5e5861aec6e0f6cbef74c03c450a1
parentb5cfcfc427238c2a42f5fbfc758e18ebf8dfc04a
Replace most uses of ast_register_atexit with ast_register_cleanup.

Since 'core stop now' and 'core restart now' do not stop modules,
it is unsafe for most of the core to run cleanups.  Originally all
cleanups used ast_register_atexit, and were only changed when it
was shown to be unsafe.  ast_register_atexit is now used only when
absolutely required to prevent corruption and close child processes.

Exceptions that need to use ast_register_atexit:
* CDR: Flush records.
* res_musiconhold: Kill external applications.
* AstDB: Close the DB.
* canary_exit: Kill canary process.

ASTERISK-24142 #close
Reported by: David Brillert

ASTERISK-24683 #close
Reported by: Peter Katzmann

ASTERISK-24805 #close
Reported by: Badalian Vyacheslav

ASTERISK-24881 #close
Reported by: Corey Farrell

Review: https://reviewboard.asterisk.org/r/4500/
Review: https://reviewboard.asterisk.org/r/4501/
........

Merged revisions 433495 from http://svn.asterisk.org/svn/asterisk/branches/11

Change-Id: I6a67336050dea74327d79cdd6f7c7ea34d0b473e
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/13@433497
45 files changed:
include/asterisk.h
main/aoc.c
main/asterisk.c
main/astfd.c
main/astmm.c
main/astobj2.c
main/astobj2_container.c
main/bridge.c
main/ccss.c
main/cel.c
main/channel.c
main/cli.c
main/codec.c
main/config.c
main/config_options.c
main/core_local.c
main/data.c
main/dnsmgr.c
main/features.c
main/file.c
main/format.c
main/format_cache.c
main/http.c
main/image.c
main/indications.c
main/manager.c
main/manager_bridges.c
main/manager_channels.c
main/manager_endpoints.c
main/manager_mwi.c
main/manager_system.c
main/message.c
main/pbx.c
main/pickup.c
main/rtp_engine.c
main/sorcery.c
main/sounds_index.c
main/stasis.c
main/stun.c
main/taskprocessor.c
main/threadstorage.c
main/timing.c
main/udptl.c
main/utils.c
main/xmldoc.c