[asterisk-commits] moy: branch moy/mfcr2 r182170 - in /team/moy/mfcr2: ./ apps/ autoconf/ bridge...

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Mon Mar 16 00:43:47 CDT 2009


Author: moy
Date: Mon Mar 16 00:43:36 2009
New Revision: 182170

URL: http://svn.digium.com/svn-view/asterisk?view=rev&rev=182170
Log:
merged trunk rev 182169

Added:
    team/moy/mfcr2/apps/app_confbridge.c
      - copied unchanged from r182169, trunk/apps/app_confbridge.c
    team/moy/mfcr2/apps/app_playtones.c
      - copied unchanged from r182169, trunk/apps/app_playtones.c
    team/moy/mfcr2/bridges/   (props changed)
      - copied from r182169, trunk/bridges/
    team/moy/mfcr2/bridges/Makefile
      - copied unchanged from r182169, trunk/bridges/Makefile
    team/moy/mfcr2/bridges/bridge_builtin_features.c
      - copied unchanged from r182169, trunk/bridges/bridge_builtin_features.c
    team/moy/mfcr2/bridges/bridge_multiplexed.c
      - copied unchanged from r182169, trunk/bridges/bridge_multiplexed.c
    team/moy/mfcr2/bridges/bridge_simple.c
      - copied unchanged from r182169, trunk/bridges/bridge_simple.c
    team/moy/mfcr2/bridges/bridge_softmix.c
      - copied unchanged from r182169, trunk/bridges/bridge_softmix.c
    team/moy/mfcr2/channels/chan_bridge.c
      - copied unchanged from r182169, trunk/channels/chan_bridge.c
    team/moy/mfcr2/channels/h323/ast_ptlib.h
      - copied unchanged from r182169, trunk/channels/h323/ast_ptlib.h
    team/moy/mfcr2/contrib/editors/
      - copied from r182169, trunk/contrib/editors/
    team/moy/mfcr2/contrib/editors/ael.vim
      - copied unchanged from r182169, trunk/contrib/editors/ael.vim
    team/moy/mfcr2/contrib/editors/asterisk.vim
      - copied unchanged from r182169, trunk/contrib/editors/asterisk.vim
    team/moy/mfcr2/contrib/editors/asteriskvm.vim
      - copied unchanged from r182169, trunk/contrib/editors/asteriskvm.vim
    team/moy/mfcr2/doc/database_transactions.txt
      - copied unchanged from r182169, trunk/doc/database_transactions.txt
    team/moy/mfcr2/doc/google-soc2009-ideas.txt
      - copied unchanged from r182169, trunk/doc/google-soc2009-ideas.txt
    team/moy/mfcr2/doc/timing.txt
      - copied unchanged from r182169, trunk/doc/timing.txt
    team/moy/mfcr2/include/asterisk/bridging.h
      - copied unchanged from r182169, trunk/include/asterisk/bridging.h
    team/moy/mfcr2/include/asterisk/bridging_features.h
      - copied unchanged from r182169, trunk/include/asterisk/bridging_features.h
    team/moy/mfcr2/include/asterisk/bridging_technology.h
      - copied unchanged from r182169, trunk/include/asterisk/bridging_technology.h
    team/moy/mfcr2/include/asterisk/heap.h
      - copied unchanged from r182169, trunk/include/asterisk/heap.h
    team/moy/mfcr2/main/bridging.c
      - copied unchanged from r182169, trunk/main/bridging.c
    team/moy/mfcr2/main/heap.c
      - copied unchanged from r182169, trunk/main/heap.c
    team/moy/mfcr2/tests/test_heap.c
      - copied unchanged from r182169, trunk/tests/test_heap.c
    team/moy/mfcr2/tests/test_sched.c
      - copied unchanged from r182169, trunk/tests/test_sched.c
Removed:
    team/moy/mfcr2/channels/chan_features.c
    team/moy/mfcr2/res/res_indications.c
Modified:
    team/moy/mfcr2/   (props changed)
    team/moy/mfcr2/CHANGES
    team/moy/mfcr2/Makefile
    team/moy/mfcr2/README
    team/moy/mfcr2/UPGRADE.txt
    team/moy/mfcr2/apps/app_dial.c
    team/moy/mfcr2/apps/app_directed_pickup.c
    team/moy/mfcr2/apps/app_disa.c
    team/moy/mfcr2/apps/app_fax.c
    team/moy/mfcr2/apps/app_meetme.c
    team/moy/mfcr2/apps/app_milliwatt.c
    team/moy/mfcr2/apps/app_osplookup.c
    team/moy/mfcr2/apps/app_queue.c
    team/moy/mfcr2/apps/app_read.c
    team/moy/mfcr2/apps/app_readexten.c
    team/moy/mfcr2/apps/app_rpt.c
    team/moy/mfcr2/apps/app_speech_utils.c
    team/moy/mfcr2/apps/app_system.c
    team/moy/mfcr2/apps/app_voicemail.c
    team/moy/mfcr2/autoconf/ast_check_gnu_make.m4
    team/moy/mfcr2/autoconf/ast_check_pwlib.m4
    team/moy/mfcr2/autoconf/ast_prog_sed.m4
    team/moy/mfcr2/build_tools/make_version
    team/moy/mfcr2/cdr/cdr_sqlite3_custom.c
    team/moy/mfcr2/channels/chan_dahdi.c
    team/moy/mfcr2/channels/chan_iax2.c
    team/moy/mfcr2/channels/chan_local.c
    team/moy/mfcr2/channels/chan_misdn.c
    team/moy/mfcr2/channels/chan_sip.c
    team/moy/mfcr2/channels/chan_skinny.c
    team/moy/mfcr2/channels/chan_unistim.c
    team/moy/mfcr2/channels/h323/ast_h323.cxx
    team/moy/mfcr2/channels/h323/ast_h323.h
    team/moy/mfcr2/channels/h323/caps_h323.cxx
    team/moy/mfcr2/channels/h323/caps_h323.h
    team/moy/mfcr2/channels/h323/chan_h323.h
    team/moy/mfcr2/channels/h323/cisco-h225.cxx
    team/moy/mfcr2/channels/h323/cisco-h225.h
    team/moy/mfcr2/channels/h323/compat_h323.cxx
    team/moy/mfcr2/channels/h323/compat_h323.h
    team/moy/mfcr2/channels/iax2-parser.h
    team/moy/mfcr2/codecs/codec_dahdi.c
    team/moy/mfcr2/configs/ais.conf.sample
    team/moy/mfcr2/configs/extconfig.conf.sample
    team/moy/mfcr2/configs/extensions.conf.sample
    team/moy/mfcr2/configs/features.conf.sample
    team/moy/mfcr2/configs/indications.conf.sample
    team/moy/mfcr2/configs/queues.conf.sample
    team/moy/mfcr2/configs/res_odbc.conf.sample
    team/moy/mfcr2/configs/res_snmp.conf.sample
    team/moy/mfcr2/configs/sip.conf.sample
    team/moy/mfcr2/configs/voicemail.conf.sample
    team/moy/mfcr2/configure
    team/moy/mfcr2/configure.ac
    team/moy/mfcr2/contrib/asterisk-ng-doxygen
    team/moy/mfcr2/contrib/init.d/rc.archlinux.asterisk
    team/moy/mfcr2/contrib/init.d/rc.debian.asterisk
    team/moy/mfcr2/contrib/scripts/safe_asterisk
    team/moy/mfcr2/doc/distributed_devstate.txt
    team/moy/mfcr2/doc/manager_1_1.txt
    team/moy/mfcr2/doc/tex/channelvariables.tex
    team/moy/mfcr2/doc/unistim.txt
    team/moy/mfcr2/formats/format_ilbc.c
    team/moy/mfcr2/funcs/func_channel.c
    team/moy/mfcr2/funcs/func_odbc.c
    team/moy/mfcr2/include/asterisk/_private.h
    team/moy/mfcr2/include/asterisk/app.h
    team/moy/mfcr2/include/asterisk/astmm.h
    team/moy/mfcr2/include/asterisk/astobj2.h
    team/moy/mfcr2/include/asterisk/audiohook.h
    team/moy/mfcr2/include/asterisk/autoconfig.h.in
    team/moy/mfcr2/include/asterisk/callerid.h
    team/moy/mfcr2/include/asterisk/channel.h
    team/moy/mfcr2/include/asterisk/config.h
    team/moy/mfcr2/include/asterisk/datastore.h
    team/moy/mfcr2/include/asterisk/devicestate.h
    team/moy/mfcr2/include/asterisk/dlinkedlists.h
    team/moy/mfcr2/include/asterisk/dnsmgr.h
    team/moy/mfcr2/include/asterisk/doxyref.h
    team/moy/mfcr2/include/asterisk/dsp.h
    team/moy/mfcr2/include/asterisk/enum.h
    team/moy/mfcr2/include/asterisk/event.h
    team/moy/mfcr2/include/asterisk/extconf.h
    team/moy/mfcr2/include/asterisk/frame.h
    team/moy/mfcr2/include/asterisk/hashtab.h
    team/moy/mfcr2/include/asterisk/http.h
    team/moy/mfcr2/include/asterisk/indications.h
    team/moy/mfcr2/include/asterisk/linkedlists.h
    team/moy/mfcr2/include/asterisk/lock.h
    team/moy/mfcr2/include/asterisk/logger.h
    team/moy/mfcr2/include/asterisk/manager.h
    team/moy/mfcr2/include/asterisk/pbx.h
    team/moy/mfcr2/include/asterisk/res_odbc.h
    team/moy/mfcr2/include/asterisk/rtp.h
    team/moy/mfcr2/include/asterisk/sched.h
    team/moy/mfcr2/include/asterisk/stringfields.h
    team/moy/mfcr2/include/asterisk/strings.h
    team/moy/mfcr2/include/asterisk/taskprocessor.h
    team/moy/mfcr2/include/asterisk/tcptls.h
    team/moy/mfcr2/include/asterisk/threadstorage.h
    team/moy/mfcr2/include/asterisk/timing.h
    team/moy/mfcr2/include/asterisk/udptl.h
    team/moy/mfcr2/include/asterisk/utils.h
    team/moy/mfcr2/main/Makefile
    team/moy/mfcr2/main/abstract_jb.c
    team/moy/mfcr2/main/acl.c
    team/moy/mfcr2/main/aescrypt.c
    team/moy/mfcr2/main/alaw.c
    team/moy/mfcr2/main/app.c
    team/moy/mfcr2/main/ast_expr2.c
    team/moy/mfcr2/main/ast_expr2.fl
    team/moy/mfcr2/main/ast_expr2.h
    team/moy/mfcr2/main/ast_expr2.y
    team/moy/mfcr2/main/ast_expr2f.c
    team/moy/mfcr2/main/asterisk.c
    team/moy/mfcr2/main/astobj2.c
    team/moy/mfcr2/main/audiohook.c
    team/moy/mfcr2/main/callerid.c
    team/moy/mfcr2/main/channel.c
    team/moy/mfcr2/main/config.c
    team/moy/mfcr2/main/devicestate.c
    team/moy/mfcr2/main/editline/configure
    team/moy/mfcr2/main/editline/configure.in
    team/moy/mfcr2/main/editline/np/unvis.c
    team/moy/mfcr2/main/editline/sys.h
    team/moy/mfcr2/main/enum.c
    team/moy/mfcr2/main/features.c
    team/moy/mfcr2/main/file.c
    team/moy/mfcr2/main/frame.c
    team/moy/mfcr2/main/hashtab.c
    team/moy/mfcr2/main/indications.c
    team/moy/mfcr2/main/loader.c
    team/moy/mfcr2/main/logger.c
    team/moy/mfcr2/main/manager.c
    team/moy/mfcr2/main/pbx.c
    team/moy/mfcr2/main/rtp.c
    team/moy/mfcr2/main/sched.c
    team/moy/mfcr2/main/stdtime/localtime.c
    team/moy/mfcr2/main/strings.c
    team/moy/mfcr2/main/tcptls.c
    team/moy/mfcr2/main/timing.c
    team/moy/mfcr2/main/translate.c
    team/moy/mfcr2/main/utils.c
    team/moy/mfcr2/pbx/pbx_config.c
    team/moy/mfcr2/pbx/pbx_spool.c
    team/moy/mfcr2/res/ael/ael.tab.c
    team/moy/mfcr2/res/ael/ael.y
    team/moy/mfcr2/res/res_ais.c
    team/moy/mfcr2/res/res_musiconhold.c
    team/moy/mfcr2/res/res_odbc.c
    team/moy/mfcr2/res/res_timing_dahdi.c
    team/moy/mfcr2/res/res_timing_pthread.c
    team/moy/mfcr2/res/res_timing_timerfd.c
    team/moy/mfcr2/res/snmp/agent.c
    team/moy/mfcr2/sounds/Makefile
    team/moy/mfcr2/sounds/sounds.xml
    team/moy/mfcr2/utils/Makefile
    team/moy/mfcr2/utils/astcanary.c
    team/moy/mfcr2/utils/expr2.testinput
    team/moy/mfcr2/utils/extconf.c

Propchange: team/moy/mfcr2/
------------------------------------------------------------------------------
Binary property 'branch-1.4-blocked' - no diff available.

Propchange: team/moy/mfcr2/
------------------------------------------------------------------------------
Binary property 'branch-1.4-merged' - no diff available.

Modified: team/moy/mfcr2/CHANGES
URL: http://svn.digium.com/svn-view/asterisk/team/moy/mfcr2/CHANGES?view=diff&rev=182170&r1=182169&r2=182170
==============================================================================
--- team/moy/mfcr2/CHANGES (original)
+++ team/moy/mfcr2/CHANGES Mon Mar 16 00:43:36 2009
@@ -44,11 +44,19 @@
  * The parsing of register => lines in sip.conf has been modified to allow a port
    to be present in the "user" portion. Please see the sip.conf.sample file for more
    information
+ * Added support for subscribing to MWI on a remote server and making the status available
+   as a mailbox. Please see the sip.conf.sample file for more information.
  * Added a function to remove SIP headers added in the dialplan before the
    first INVITE is generated - SIPRemoveHeader()
  * Channel variables set with setvar= in a device configuration is now 
    set both for inbound and outbound calls.
  * Added support for ITU G.722.1 and G.722.1C (Siren7 and Siren14) media streams.
+
+IAX2 changes
+------------
+  * Added immediate option to iax.conf
+  * Added forceencryption option to iax.conf
+  * Added Encryption and Trunk status to manager command "iaxpeers"
 
 Skinny Changes
 --------------
@@ -92,6 +100,7 @@
    of "core show function AES_ENCRYPT" from the CLI
  * Added AES_DECRYPT. For information on its use, please see the output
    of "core show function AES_DECRYPT" from the CLI
+ * func_odbc now supports database transactions across multiple queries.
 
 Applications
 ------------
@@ -106,6 +115,11 @@
    specified in the initial argument.
  * A new application, Originate, has been introduced, that allows asynchronous
    call origination from the dialplan.
+ * Voicemail now permits setting the emailsubject and emailbody per mailbox,
+   in addition to the setting in the "general" context.
+ * Added ConfBridge dialplan application which does conference bridges without
+   DAHDI. For information on its use, please see the output of
+   "core show application ConfBridge" from the CLI.
 
 Miscellaneous
 -------------
@@ -138,6 +152,12 @@
    externhost and localnet settings.
  * The Asterisk core now supports ITU G.722.1 and G.722.1C media streams, and
    can connect calls in passthrough mode, as well as record and play back files.
+ * Successful and unsuccessful call pickup can now be alerted through sounds, by
+   using pickupsound and pickupfailsound in features.conf.
+ * ASTVARRUNDIR is now set to $(localstatedir)/run/asterisk by default. 
+   This means the asterisk pid file will now be in /var/run/asterisk/asterisk.pid on LINUX
+   instead of the /var/run/asterisk.pid where it used to be. This will make
+   installs as non-root easier to manage.
 
 Asterisk Manager Interface
 --------------------------
@@ -153,6 +173,12 @@
    Pragma: SuppressEvents
 
    If this is included, the server supports event suppression.
+
+ * Added 4 new Actions to list skinny device(s) and line(s)
+   SKINNYdevices
+   SKINNYshowdevice
+   SKINNYlines
+   SKINNYshowline
 
 ------------------------------------------------------------------------------
 --- Functionality changes from Asterisk 1.6.0 to Asterisk 1.6.1  -------------
@@ -555,8 +581,6 @@
   * Added the srvlookup option to iax.conf
   * Added support for OSP.  The token is set and retrieved through the CHANNEL()
      dialplan function.
-  * Added immediate option to iax.conf
-  * Added forceencryption option to iax.conf
 
 XMPP Google Talk/Jingle changes
 -------------------------------

Modified: team/moy/mfcr2/Makefile
URL: http://svn.digium.com/svn-view/asterisk/team/moy/mfcr2/Makefile?view=diff&rev=182170&r1=182169&r2=182170
==============================================================================
--- team/moy/mfcr2/Makefile (original)
+++ team/moy/mfcr2/Makefile Mon Mar 16 00:43:36 2009
@@ -146,7 +146,7 @@
   ASTSBINDIR=$(sbindir)
   ASTSPOOLDIR=$(localstatedir)/spool/asterisk
   ASTLOGDIR=$(localstatedir)/log/asterisk
-  ASTVARRUNDIR=$(localstatedir)/run
+  ASTVARRUNDIR=$(localstatedir)/run/asterisk
   ASTMANDIR=$(mandir)
 ifneq ($(findstring BSD,$(OSARCH)),)
   ASTVARLIBDIR=$(prefix)/share/asterisk
@@ -293,7 +293,7 @@
 #	value directly to ASTCFLAGS
 ASTCFLAGS+=$(MALLOC_DEBUG)$(OPTIONS)
 
-MOD_SUBDIRS:=channels pbx apps codecs formats cdr funcs tests main res $(LOCAL_MOD_SUBDIRS)
+MOD_SUBDIRS:=channels pbx apps codecs formats cdr bridges funcs tests main res $(LOCAL_MOD_SUBDIRS)
 OTHER_SUBDIRS:=utils agi
 SUBDIRS:=$(OTHER_SUBDIRS) $(MOD_SUBDIRS)
 SUBDIRS_INSTALL:=$(SUBDIRS:%=%-install)
@@ -805,22 +805,28 @@
 config:
 	@if [ "${OSARCH}" = "linux-gnu" ]; then \
 		if [ -f /etc/redhat-release -o -f /etc/fedora-release ]; then \
-			$(INSTALL) -m 755 contrib/init.d/rc.redhat.asterisk $(DESTDIR)/etc/rc.d/init.d/asterisk; \
+			cat contrib/init.d/rc.redhat.asterisk | sed 's|__ASTERISK_ETC_DIR__|$(ASTETCDIR)|;s|__ASTERISK_SBIN_DIR__|$(ASTSBINDIR)|;s|__ASTERISK_VARRUN_DIR__|$(ASTVARRUNDIR)|;' > $(DESTDIR)/etc/rc.d/init.d/asterisk ;\
+			chmod 755 $(DESTDIR)/etc/rc.d/init.d/asterisk;\
 			if [ -z "$(DESTDIR)" ]; then /sbin/chkconfig --add asterisk; fi; \
 		elif [ -f /etc/debian_version ]; then \
-			$(INSTALL) -m 755 contrib/init.d/rc.debian.asterisk $(DESTDIR)/etc/init.d/asterisk; \
+			cat contrib/init.d/rc.debian.asterisk | sed 's|__ASTERISK_ETC_DIR__|$(ASTETCDIR)|;s|__ASTERISK_SBIN_DIR__|$(ASTSBINDIR)|;s|__ASTERISK_VARRUN_DIR__|$(ASTVARRUNDIR)|;' > $(DESTDIR)/etc/init.d/asterisk ;\
+			chmod 755 $(DESTDIR)/etc/init.d/asterisk;\
 			if [ -z "$(DESTDIR)" ]; then /usr/sbin/update-rc.d asterisk start 50 2 3 4 5 . stop 91 2 3 4 5 .; fi; \
 		elif [ -f /etc/gentoo-release ]; then \
-			$(INSTALL) -m 755 contrib/init.d/rc.gentoo.asterisk $(DESTDIR)/etc/init.d/asterisk; \
+			cat contrib/init.d/rc.gentoo.asterisk | sed 's|__ASTERISK_ETC_DIR__|$(ASTETCDIR)|;s|__ASTERISK_SBIN_DIR__|$(ASTSBINDIR)|;s|__ASTERISK_VARRUN_DIR__|$(ASTVARRUNDIR)|;' > $(DESTDIR)/etc/init.d/asterisk ;\
+			chmod 755 $(DESTDIR)/etc/init.d/asterisk;\
 			if [ -z "$(DESTDIR)" ]; then /sbin/rc-update add asterisk default; fi; \
 		elif [ -f /etc/mandrake-release -o -f /etc/mandriva-release ]; then \
-			$(INSTALL) -m 755 contrib/init.d/rc.mandriva.asterisk $(DESTDIR)/etc/rc.d/init.d/asterisk; \
+			cat contrib/init.d/rc.mandriva.asterisk | sed 's|__ASTERISK_ETC_DIR__|$(ASTETCDIR)|;s|__ASTERISK_SBIN_DIR__|$(ASTSBINDIR)|;s|__ASTERISK_VARRUN_DIR__|$(ASTVARRUNDIR)|;' > $(DESTDIR)/etc/rc.d/init.d/asterisk ;\
+			chmod 755 $(DESTDIR)/etc/rc.d/init.d/asterisk;\
 			if [ -z "$(DESTDIR)" ]; then /sbin/chkconfig --add asterisk; fi; \
 		elif [ -f /etc/SuSE-release -o -f /etc/novell-release ]; then \
-			$(INSTALL) -m 755 contrib/init.d/rc.suse.asterisk $(DESTDIR)/etc/init.d/asterisk; \
+			cat contrib/init.d/rc.suse.asterisk | sed 's|__ASTERISK_ETC_DIR__|$(ASTETCDIR)|;s|__ASTERISK_SBIN_DIR__|$(ASTSBINDIR)|;s|__ASTERISK_VARRUN_DIR__|$(ASTVARRUNDIR)|;' > $(DESTDIR)/etc/init.d/asterisk ;\
+			chmod 755 $(DESTDIR)/etc/init.d/asterisk;\
 			if [ -z "$(DESTDIR)" ]; then /sbin/chkconfig --add asterisk; fi; \
 		elif [ -f /etc/arch-release -o -f /etc/arch-release ]; then \
-			$(INSTALL) -m 755 contrib/init.d/rc.archlinux.asterisk $(DESTDIR)/etc/rc.d/asterisk; \
+			cat contrib/init.d/rc.archlinux.asterisk | sed 's|__ASTERISK_ETC_DIR__|$(ASTETCDIR)|;s|__ASTERISK_SBIN_DIR__|$(ASTSBINDIR)|;s|__ASTERISK_VARRUN_DIR__|$(ASTVARRUNDIR)|;' > $(DESTDIR)/etc/rc.d/asterisk ;\
+			chmod 755 $(DESTDIR)/etc/rc.d/asterisk;\
 		elif [ -f /etc/slackware-version ]; then \
 			echo "Slackware is not currently supported, although an init script does exist for it." \
 		else \

Modified: team/moy/mfcr2/README
URL: http://svn.digium.com/svn-view/asterisk/team/moy/mfcr2/README?view=diff&rev=182170&r1=182169&r2=182170
==============================================================================
--- team/moy/mfcr2/README (original)
+++ team/moy/mfcr2/README Mon Mar 16 00:43:36 2009
@@ -4,7 +4,7 @@
 ===                   by Mark Spencer <markster at digium.com>
 ===                  and the Asterisk.org developer community
 ===
-===                    Copyright (C) 2001-2008 Digium, Inc.
+===                    Copyright (C) 2001-2009 Digium, Inc.
 ===                       and other copyright holders.
 ===============================================================================
 
@@ -68,8 +68,8 @@
 	* All Analog and Digital Interface cards from Digium (www.digium.com)
 	* QuickNet Internet PhoneJack and LineJack (http://www.quicknet.net)
 	* any full duplex sound card supported by ALSA, OSS, or PortAudio
-	* any ISDN card supported by mISDN on Linux (BRI)
-	* The Xorcom AstriBank channel bank
+	* any ISDN card supported by mISDN on Linux
+	* The Xorcom Astribank channel bank
 	* VoiceTronix OpenLine products
 
 -------------------------------------------------------------------------------

Modified: team/moy/mfcr2/UPGRADE.txt
URL: http://svn.digium.com/svn-view/asterisk/team/moy/mfcr2/UPGRADE.txt?view=diff&rev=182170&r1=182169&r2=182170
==============================================================================
--- team/moy/mfcr2/UPGRADE.txt (original)
+++ team/moy/mfcr2/UPGRADE.txt Mon Mar 16 00:43:36 2009
@@ -17,6 +17,13 @@
 === UPGRADE-1.6.txt -- Upgrade info for 1.4 to 1.6
 ===
 ===========================================================
+
+From 1.6.1 to 1.6.2:
+
+* The res_indications module has been removed.  Its functionality was important
+  enough that most of it has been moved into the Asterisk core.
+  Two applications previously provided by res_indications, PlayTones and
+  StopPlayTones, have been moved into a new module, app_playtones.
 
 From 1.6.0.1 to 1.6.1:
 
@@ -38,6 +45,13 @@
   operations.
 
 From 1.6.0.x to 1.6.1:
+
+* In previous versions of Asterisk, due to the way objects were arranged in
+  memory by chan_sip, the order of entries in sip.conf could be adjusted to
+  control the behavior of matching against peers and users.  The way objects
+  are managed has been significantly changed for reasons involving performance
+  and stability.  A side effect of these changes is that the order of entries
+  in sip.conf can no longer be relied upon to control behavior.
 
 * The following core commands dealing with dialplan have been deprecated: 'core
   show globals', 'core set global' and 'core set chanvar'. Use the equivalent

Modified: team/moy/mfcr2/apps/app_dial.c
URL: http://svn.digium.com/svn-view/asterisk/team/moy/mfcr2/apps/app_dial.c?view=diff&rev=182170&r1=182169&r2=182170
==============================================================================
--- team/moy/mfcr2/apps/app_dial.c (original)
+++ team/moy/mfcr2/apps/app_dial.c Mon Mar 16 00:43:36 2009
@@ -522,8 +522,6 @@
 	AST_APP_OPTION('h', OPT_CALLEE_HANGUP),
 	AST_APP_OPTION('H', OPT_CALLER_HANGUP),
 	AST_APP_OPTION('i', OPT_IGNORE_FORWARDING),
-	AST_APP_OPTION('k', OPT_CALLEE_PARK),
-	AST_APP_OPTION('K', OPT_CALLER_PARK),
 	AST_APP_OPTION('k', OPT_CALLEE_PARK),
 	AST_APP_OPTION('K', OPT_CALLER_PARK),
 	AST_APP_OPTION_ARG('L', OPT_DURATION_LIMIT, OPT_ARG_DURATION_LIMIT),
@@ -2270,10 +2268,12 @@
 	parse = ast_strdupa(data);
 	AST_STANDARD_APP_ARGS(args, parse);
 
-	if ((sleepms = atoi(args.sleep)))
+	if (!ast_strlen_zero(args.sleep) && (sleepms = atoi(args.sleep)))
 		sleepms *= 1000;
 
-	loops = atoi(args.retries);
+	if (!ast_strlen_zero(args.retries)) {
+		loops = atoi(args.retries);
+	}
 
 	if (!args.dialdata) {
 		ast_log(LOG_ERROR, "%s requires a 4th argument (dialdata)\n", rapp);

Modified: team/moy/mfcr2/apps/app_directed_pickup.c
URL: http://svn.digium.com/svn-view/asterisk/team/moy/mfcr2/apps/app_directed_pickup.c?view=diff&rev=182170&r1=182169&r2=182170
==============================================================================
--- team/moy/mfcr2/apps/app_directed_pickup.c (original)
+++ team/moy/mfcr2/apps/app_directed_pickup.c Mon Mar 16 00:43:36 2009
@@ -163,8 +163,8 @@
 	/* Just check that we are not picking up the SAME as target */
 	if (chan->name != target->name && chan != target) {
 		res = pickup_do(chan, target);
-		ast_channel_unlock(target);
-	}
+	}
+	ast_channel_unlock(target);
 
 	return res;
 }

Modified: team/moy/mfcr2/apps/app_disa.c
URL: http://svn.digium.com/svn-view/asterisk/team/moy/mfcr2/apps/app_disa.c?view=diff&rev=182170&r1=182169&r2=182170
==============================================================================
--- team/moy/mfcr2/apps/app_disa.c (original)
+++ team/moy/mfcr2/apps/app_disa.c Mon Mar 16 00:43:36 2009
@@ -124,15 +124,20 @@
 
 static void play_dialtone(struct ast_channel *chan, char *mailbox)
 {
-	const struct tone_zone_sound *ts = NULL;
-	if(ast_app_has_voicemail(mailbox, NULL))
+	struct ast_tone_zone_sound *ts = NULL;
+
+	if (ast_app_has_voicemail(mailbox, NULL)) {
 		ts = ast_get_indication_tone(chan->zone, "dialrecall");
-	else
+	} else {
 		ts = ast_get_indication_tone(chan->zone, "dial");
-	if (ts)
+	}
+
+	if (ts) {
 		ast_playtones_start(chan, 0, ts->data, 0);
-	else
+		ts = ast_tone_zone_sound_unref(ts);
+	} else {
 		ast_tonepair_start(chan, 350, 440, 0, 0);
+	}
 }
 
 static int disa_exec(struct ast_channel *chan, void *data)

Modified: team/moy/mfcr2/apps/app_fax.c
URL: http://svn.digium.com/svn-view/asterisk/team/moy/mfcr2/apps/app_fax.c?view=diff&rev=182170&r1=182169&r2=182170
==============================================================================
--- team/moy/mfcr2/apps/app_fax.c (original)
+++ team/moy/mfcr2/apps/app_fax.c Mon Mar 16 00:43:36 2009
@@ -206,6 +206,7 @@
 	char buf[20];
 	fax_session *s = (fax_session *) user_data;
 	t30_stats_t stat;
+	int pages_transferred;
 
 	ast_debug(1, "Fax phase E handler. result=%d\n", result);
 
@@ -231,7 +232,12 @@
 	pbx_builtin_setvar_helper(s->chan, "FAXSTATUS", "SUCCESS"); 
 	pbx_builtin_setvar_helper(s->chan, "FAXERROR", NULL); 
 	pbx_builtin_setvar_helper(s->chan, "REMOTESTATIONID", far_ident);
-	snprintf(buf, sizeof(buf), "%d", stat.pages_transferred);
+#if SPANDSP_RELEASE_DATE >= 20090220
+	pages_transferred = (s->direction) ? stat.pages_tx : stat.pages_rx;
+#else
+	pages_transferred = stat.pages_transferred;
+#endif
+	snprintf(buf, sizeof(buf), "%d", pages_transferred);
 	pbx_builtin_setvar_helper(s->chan, "FAXPAGES", buf);
 	snprintf(buf, sizeof(buf), "%d", stat.y_resolution);
 	pbx_builtin_setvar_helper(s->chan, "FAXRESOLUTION", buf);
@@ -240,7 +246,7 @@
 	
 	ast_debug(1, "Fax transmitted successfully.\n");
 	ast_debug(1, "  Remote station ID: %s\n", far_ident);
-	ast_debug(1, "  Pages transferred: %d\n", stat.pages_transferred);
+	ast_debug(1, "  Pages transferred: %d\n", pages_transferred);
 	ast_debug(1, "  Image resolution:  %d x %d\n", stat.x_resolution, stat.y_resolution);
 	ast_debug(1, "  Transfer Rate:     %d\n", stat.bit_rate);
 	
@@ -260,7 +266,7 @@
 		      S_OR(s->chan->cid.cid_num, ""),
 		      far_ident,
 		      local_ident,
-		      stat.pages_transferred,
+		      pages_transferred,
 		      stat.y_resolution,
 		      stat.bit_rate,
 		      s->file_name);

Modified: team/moy/mfcr2/apps/app_meetme.c
URL: http://svn.digium.com/svn-view/asterisk/team/moy/mfcr2/apps/app_meetme.c?view=diff&rev=182170&r1=182169&r2=182170
==============================================================================
--- team/moy/mfcr2/apps/app_meetme.c (original)
+++ team/moy/mfcr2/apps/app_meetme.c Mon Mar 16 00:43:36 2009
@@ -502,6 +502,8 @@
 	CONFFLAG_EMPTY = (1 << 18),
 	CONFFLAG_EMPTYNOPIN = (1 << 19),
 	CONFFLAG_ALWAYSPROMPT = (1 << 20),
+	/*! If set, treat talking users as muted users */
+	CONFFLAG_OPTIMIZETALKER = (1 << 21),
 	/*! If set, won't speak the extra prompt when the first person 
 	 *  enters the conference */
 	CONFFLAG_NOONLYPERSON = (1 << 22),
@@ -546,6 +548,7 @@
 	AST_APP_OPTION('I', CONFFLAG_INTROUSERNOREVIEW ),
 	AST_APP_OPTION_ARG('M', CONFFLAG_MOH, OPT_ARG_MOH_CLASS ),
 	AST_APP_OPTION('m', CONFFLAG_STARTMUTED ),
+	AST_APP_OPTION('o', CONFFLAG_OPTIMIZETALKER ),
 	AST_APP_OPTION('P', CONFFLAG_ALWAYSPROMPT ),
 	AST_APP_OPTION_ARG('p', CONFFLAG_KEYEXIT, OPT_ARG_EXITKEYS ),
 	AST_APP_OPTION('q', CONFFLAG_QUIET ),
@@ -1973,7 +1976,6 @@
 	int ms;
 	int nfds;
 	int res;
-	int flags;
 	int retrydahdi;
 	int origfd;
 	int musiconhold = 0;
@@ -2332,24 +2334,13 @@
  dahdiretry:
 	origfd = chan->fds[0];
 	if (retrydahdi) {
-		fd = open("/dev/dahdi/pseudo", O_RDWR);
+		/* open pseudo in non-blocking mode */
+		fd = open("/dev/dahdi/pseudo", O_RDWR | O_NONBLOCK);
 		if (fd < 0) {
 			ast_log(LOG_WARNING, "Unable to open pseudo channel: %s\n", strerror(errno));
 			goto outrun;
 		}
 		using_pseudo = 1;
-		/* Make non-blocking */
-		flags = fcntl(fd, F_GETFL);
-		if (flags < 0) {
-			ast_log(LOG_WARNING, "Unable to get flags: %s\n", strerror(errno));
-			close(fd);
-			goto outrun;
-		}
-		if (fcntl(fd, F_SETFL, flags | O_NONBLOCK)) {
-			ast_log(LOG_WARNING, "Unable to set flags: %s\n", strerror(errno));
-			close(fd);
-			goto outrun;
-		}
 		/* Setup buffering information */
 		memset(&bi, 0, sizeof(bi));
 		bi.bufsize = CONF_SIZE / 2;
@@ -2493,7 +2484,7 @@
 			x = 1;
 			ast_channel_setoption(chan, AST_OPTION_TONE_VERIFY, &x, sizeof(char), 0);
 		}	
-		if (!(confflags & CONFFLAG_MONITOR) && !(dsp = ast_dsp_new())) {
+		if ((confflags & CONFFLAG_OPTIMIZETALKER) && !(confflags & CONFFLAG_MONITOR) && !(dsp = ast_dsp_new())) {
 			ast_log(LOG_WARNING, "Unable to allocate DSP!\n");
 			res = -1;
 		}
@@ -2668,8 +2659,6 @@
 				}
 			}
 
-			c = ast_waitfor_nandfds(&chan, 1, &fd, nfds, NULL, &outfd, &ms);
-
 			/* Update the struct with the actual confflags */
 			user->userflags = confflags;
 
@@ -2832,6 +2821,8 @@
 				break;
 			}
 
+			c = ast_waitfor_nandfds(&chan, 1, &fd, nfds, NULL, &outfd, &ms);
+
 			if (c) {
 				char dtmfstr[2] = "";
 
@@ -2864,7 +2855,7 @@
 						ast_frame_adjust_volume(f, user->talk.actual);
 					}
 
-					if (!(confflags & CONFFLAG_MONITOR)) {
+					if ((confflags & CONFFLAG_OPTIMIZETALKER) && !(confflags & CONFFLAG_MONITOR)) {
 						int totalsilence;
 
 						if (user->talking == -1) {
@@ -2909,7 +2900,7 @@
 						   don't want to block, but we do want to at least *try*
 						   to write out all the samples.
 						 */
-						if (user->talking) {
+						if (user->talking && !(confflags & CONFFLAG_OPTIMIZETALKER)) {
 							careful_write(fd, f->data.ptr, f->datalen, 0);
 						}
 					}
@@ -3175,10 +3166,11 @@
 					fr.samples = res / 2;
 					fr.data.ptr = buf;
 					fr.offset = AST_FRIENDLY_OFFSET;
-					if (!user->listen.actual && 
-						((confflags & CONFFLAG_MONITOR) || 
+					if (!user->listen.actual &&
+						((confflags & CONFFLAG_MONITOR) ||
 						 (user->adminflags & (ADMINFLAG_MUTED | ADMINFLAG_SELFMUTED)) ||
-						 (!user->talking)) ) {
+						 (!user->talking && (confflags & CONFFLAG_OPTIMIZETALKER))
+						 )) {
 						int idx;
 						for (idx = 0; idx < AST_FRAME_BITS; idx++) {
 							if (chan->rawwriteformat & (1 << idx)) {
@@ -3355,6 +3347,8 @@
 		char *pin = NULL, *pinadmin = NULL; /* For temp use */
 		int maxusers = 0;
 		struct timeval now;
+		char recordingfilename[256] = "";
+		char recordingformat[10] = "";
 		char currenttime[19] = "";
 		char eatime[19] = "";
 		char bookid[19] = "";
@@ -3363,6 +3357,7 @@
 		char adminopts[OPTIONS_LEN];
 		struct ast_tm tm, etm;
 		struct timeval endtime = { .tv_sec = 0 };
+		const char *var2;
 
 		if (rt_schedule) {
 			now = ast_tvnow();
@@ -3428,6 +3423,10 @@
 				maxusers = atoi(var->value);
 			} else if (!strcasecmp(var->name, "adminopts")) {
 				ast_copy_string(adminopts, var->value, sizeof(char[OPTIONS_LEN]));
+			} else if (!strcasecmp(var->name, "recordingfilename")) {
+				ast_copy_string(recordingfilename, var->value, sizeof(recordingfilename));
+			} else if (!strcasecmp(var->name, "recordingformat")) {
+				ast_copy_string(recordingformat, var->value, sizeof(recordingformat));
 			} else if (!strcasecmp(var->name, "endtime")) {
 				struct ast_tm endtime_tm;
 				ast_strptime(var->value, "%Y-%m-%d %H:%M:%S", &endtime_tm);
@@ -3446,9 +3445,37 @@
 			cnf->useropts = ast_strdup(useropts);
 			cnf->adminopts = ast_strdup(adminopts);
 			cnf->bookid = ast_strdup(bookid);
-			snprintf(recordingtmp, sizeof(recordingtmp), "%s/meetme/meetme-conf-rec-%s-%s", ast_config_AST_SPOOL_DIR, confno, bookid);
-			cnf->recordingfilename = ast_strdup(recordingtmp);
-			cnf->recordingformat = ast_strdup("wav");
+			cnf->recordingfilename = ast_strdup(recordingfilename);
+			cnf->recordingformat = ast_strdup(recordingformat);
+
+			if (strchr(cnf->useropts, 'r')) {
+				if (ast_strlen_zero(recordingfilename)) { /* If the recordingfilename in the database is empty, use the channel definition or use the default. */
+					ast_channel_lock(chan);
+					if ((var2 = pbx_builtin_getvar_helper(chan, "MEETME_RECORDINGFILE"))) {
+						ast_free(cnf->recordingfilename);
+						cnf->recordingfilename = ast_strdup(var2);
+					}
+					ast_channel_unlock(chan);
+					if (ast_strlen_zero(cnf->recordingfilename)) {
+						snprintf(recordingtmp, sizeof(recordingtmp), "meetme-conf-rec-%s-%s", cnf->confno, chan->uniqueid);
+						ast_free(cnf->recordingfilename);
+						cnf->recordingfilename = ast_strdup(recordingtmp);
+					}
+				}
+				if (ast_strlen_zero(cnf->recordingformat)) {/* If the recording format is empty, use the wav as default */
+					ast_channel_lock(chan);
+					if ((var2 = pbx_builtin_getvar_helper(chan, "MEETME_RECORDINGFORMAT"))) {
+						ast_free(cnf->recordingformat);
+						cnf->recordingformat = ast_strdup(var2);
+					}
+					ast_channel_unlock(chan);
+					if (ast_strlen_zero(cnf->recordingformat)) {
+						ast_free(cnf->recordingformat);
+						cnf->recordingformat = ast_strdup("wav");
+					}
+				}
+				ast_verb(4, "Starting recording of MeetMe Conference %s into file %s.%s.\n", cnf->confno, cnf->recordingfilename, cnf->recordingformat);
+			}
 		}
 	}
 
@@ -3824,6 +3851,7 @@
 									}
 								}
 								/* Run the conference */
+								ast_verb(4, "Starting recording of MeetMe Conference %s into file %s.%s.\n", cnf->confno, cnf->recordingfilename, cnf->recordingformat);
 								res = conf_run(chan, cnf, confflags.flags, optargs);
 								break;
 							} else {

Modified: team/moy/mfcr2/apps/app_milliwatt.c
URL: http://svn.digium.com/svn-view/asterisk/team/moy/mfcr2/apps/app_milliwatt.c?view=diff&rev=182170&r1=182169&r2=182170
==============================================================================
--- team/moy/mfcr2/apps/app_milliwatt.c (original)
+++ team/moy/mfcr2/apps/app_milliwatt.c Mon Mar 16 00:43:36 2009
@@ -24,10 +24,6 @@
  * 
  * \ingroup applications
  */
-
-/*** MODULEINFO
-	<depend>res_indications</depend>
- ***/
 
 #include "asterisk.h"
 

Modified: team/moy/mfcr2/apps/app_osplookup.c
URL: http://svn.digium.com/svn-view/asterisk/team/moy/mfcr2/apps/app_osplookup.c?view=diff&rev=182170&r1=182169&r2=182170
==============================================================================
--- team/moy/mfcr2/apps/app_osplookup.c (original)
+++ team/moy/mfcr2/apps/app_osplookup.c Mon Mar 16 00:43:36 2009
@@ -713,7 +713,7 @@
 	unsigned int* timelimit)
 {
 	int res;
-	struct osp_provider* p;
+	struct osp_provider* p = NULL;
 	char dest[OSP_NORSTR_SIZE];
 
 	*transaction = OSP_INVALID_HANDLE;
@@ -861,7 +861,7 @@
 	struct osp_result* result)
 {
 	int res;
-	struct osp_provider* p;
+	struct osp_provider* p = NULL;
 	char source[OSP_NORSTR_SIZE];
 	char callingnum[OSP_NORSTR_SIZE];
 	char callednum[OSP_NORSTR_SIZE];
@@ -1076,7 +1076,7 @@
 	struct osp_result* result)
 {
 	int res;
-	struct osp_provider* p;
+	struct osp_provider* p = NULL;
 	char callingnum[OSP_NORSTR_SIZE];
 	char callednum[OSP_NORSTR_SIZE];
 	char destination[OSP_NORSTR_SIZE];

Modified: team/moy/mfcr2/apps/app_queue.c
URL: http://svn.digium.com/svn-view/asterisk/team/moy/mfcr2/apps/app_queue.c?view=diff&rev=182170&r1=182169&r2=182170
==============================================================================
--- team/moy/mfcr2/apps/app_queue.c (original)
+++ team/moy/mfcr2/apps/app_queue.c Mon Mar 16 00:43:36 2009
@@ -1826,11 +1826,13 @@
 			ast_variables_destroy(queue_vars);
 		}
 		/* update the use_weight value if the queue's has gained or lost a weight */ 
-		if (!q->weight && prev_weight) {
-			ast_atomic_fetchadd_int(&use_weight, -1);
-		}
-		if (q->weight && !prev_weight) {
-			ast_atomic_fetchadd_int(&use_weight, +1);
+		if (q) {
+			if (!q->weight && prev_weight) {
+				ast_atomic_fetchadd_int(&use_weight, -1);
+			}
+			if (q->weight && !prev_weight) {
+				ast_atomic_fetchadd_int(&use_weight, +1);
+			}
 		}
 		/* Other cases will end up with the proper value for use_weight */
 		ao2_unlock(queues);
@@ -1973,6 +1975,10 @@
 static int play_file(struct ast_channel *chan, const char *filename)
 {
 	int res;
+
+	if (ast_strlen_zero(filename)) {
+		return 0;
+	}
 
 	ast_stopstream(chan);
 
@@ -2111,7 +2117,7 @@
 		if (res)
 			goto playout;
 
-		if (avgholdmins > 1) {
+		if (avgholdmins >= 1) {
 			res = ast_say_number(qe->chan, avgholdmins, AST_DIGIT_ANY, qe->chan->language, NULL);
 			if (res)
 				goto playout;
@@ -2126,7 +2132,7 @@
 					goto playout;
 			}
 		}
-		if (avgholdsecs > 1) {
+		if (avgholdsecs >= 1) {
 			res = ast_say_number(qe->chan, avgholdmins > 1 ? avgholdsecs : avgholdmins * 60 + avgholdsecs, AST_DIGIT_ANY, qe->chan->language, NULL);
 			if (res)
 				goto playout;
@@ -4031,7 +4037,7 @@
 			application = pbx_findapp("Macro");
 
 			if (application) {
-				res = pbx_exec(qe->chan, application, macroexec);
+				res = pbx_exec(peer, application, macroexec);
 				ast_debug(1, "Macro exited with status %d\n", res);
 				res = 0;
 			} else {
@@ -7095,7 +7101,7 @@
 		ast_log(LOG_WARNING, "devicestate taskprocessor reference failed - devicestate notifications will not occur\n");
 	}
 
-	if (!(device_state_sub = ast_event_subscribe(AST_EVENT_DEVICE_STATE_CHANGE, device_state_cb, NULL, AST_EVENT_IE_END))) {
+	if (!(device_state_sub = ast_event_subscribe(AST_EVENT_DEVICE_STATE, device_state_cb, NULL, AST_EVENT_IE_END))) {
 		res = -1;
 	}
 

Modified: team/moy/mfcr2/apps/app_read.c
URL: http://svn.digium.com/svn-view/asterisk/team/moy/mfcr2/apps/app_read.c?view=diff&rev=182170&r1=182169&r2=182170
==============================================================================
--- team/moy/mfcr2/apps/app_read.c (original)
+++ team/moy/mfcr2/apps/app_read.c Mon Mar 16 00:43:36 2009
@@ -132,7 +132,7 @@
 	int tries = 1, to = 0, x = 0;
 	double tosec;
 	char *argcopy = NULL;
-	struct tone_zone_sound *ts = NULL;
+	struct ast_tone_zone_sound *ts = NULL;
 	struct ast_flags flags = {0};
 	const char *status = "ERROR";
 
@@ -188,7 +188,7 @@
 		return 0;
 	}
 	if (ast_test_flag(&flags, OPT_INDICATION)) {
-		if (! ast_strlen_zero(arglist.filename)) {
+		if (!ast_strlen_zero(arglist.filename)) {
 			ts = ast_get_indication_tone(chan->zone, arglist.filename);
 		}
 	}
@@ -231,11 +231,11 @@
 				}
 			} else {
 				res = ast_app_getdata(chan, arglist.filename, tmp, maxdigits, to);
-				if (res == 0)
+				if (res == AST_GETDATA_COMPLETE || res == AST_GETDATA_EMPTY_END_TERMINATED)
 					status = "OK";
-				else if (res == 1)
+				else if (res == AST_GETDATA_TIMEOUT)
 					status = "TIMEOUT";
-				else if (res == 2)
+				else if (res == AST_GETDATA_INTERRUPTED)
 					status = "INTERRUPTED";
 			}
 			if (res > -1) {
@@ -258,6 +258,10 @@
 		}
 	}
 
+	if (ts) {
+		ts = ast_tone_zone_sound_unref(ts);
+	}
+
 	if (ast_check_hangup(chan))
 		status = "HANGUP";
 	pbx_builtin_setvar_helper(chan, "READSTATUS", status);

Modified: team/moy/mfcr2/apps/app_readexten.c
URL: http://svn.digium.com/svn-view/asterisk/team/moy/mfcr2/apps/app_readexten.c?view=diff&rev=182170&r1=182169&r2=182170
==============================================================================
--- team/moy/mfcr2/apps/app_readexten.c (original)
+++ team/moy/mfcr2/apps/app_readexten.c Mon Mar 16 00:43:36 2009
@@ -132,7 +132,7 @@
 	int maxdigits = sizeof(exten) - 1;
 	int timeout = 0, digit_timeout = 0, x = 0;
 	char *argcopy = NULL, *status = "";
-	struct tone_zone_sound *ts = NULL;
+	struct ast_tone_zone_sound *ts = NULL;
 	struct ast_flags flags = {0};
 
 	 AST_DECLARE_APP_ARGS(arglist,
@@ -179,8 +179,9 @@
 	if (digit_timeout <= 0)
 		digit_timeout = chan->pbx ? chan->pbx->dtimeoutms : 5000;
 
-	if (ast_test_flag(&flags, OPT_INDICATION) && !ast_strlen_zero(arglist.filename))
+	if (ast_test_flag(&flags, OPT_INDICATION) && !ast_strlen_zero(arglist.filename)) {
 		ts = ast_get_indication_tone(chan->zone, arglist.filename);
+	}
 
 	do {
 		if (chan->_state != AST_STATE_UP) {
@@ -250,6 +251,10 @@
 		}
 	} while (0);
 
+	if (ts) {
+		ts = ast_tone_zone_sound_unref(ts);
+	}
+
 	pbx_builtin_setvar_helper(chan, "READEXTENSTATUS", status);
 
 	return status[0] == 'H' ? -1 : 0;

Modified: team/moy/mfcr2/apps/app_rpt.c
URL: http://svn.digium.com/svn-view/asterisk/team/moy/mfcr2/apps/app_rpt.c?view=diff&rev=182170&r1=182169&r2=182170
==============================================================================
--- team/moy/mfcr2/apps/app_rpt.c (original)
+++ team/moy/mfcr2/apps/app_rpt.c Mon Mar 16 00:43:36 2009
@@ -14680,7 +14680,7 @@
 
 			if(myrpt->remote){ /* Remote base ? */
 				char *loginuser, *loginlevel, *freq, *rxpl, *txpl, *modestr;
-				char offset,powerlevel,rxplon,txplon,remoteon,remmode,reportfmstuff;
+				char offset = 0, powerlevel = 0, rxplon = 0, txplon = 0, remoteon, remmode = 0, reportfmstuff;
 				char offsetc,powerlevelc;
 
 				loginuser = loginlevel = freq = rxpl = txpl = NULL;

Modified: team/moy/mfcr2/apps/app_speech_utils.c
URL: http://svn.digium.com/svn-view/asterisk/team/moy/mfcr2/apps/app_speech_utils.c?view=diff&rev=182170&r1=182169&r2=182170
==============================================================================
--- team/moy/mfcr2/apps/app_speech_utils.c (original)
+++ team/moy/mfcr2/apps/app_speech_utils.c Mon Mar 16 00:43:36 2009
@@ -500,6 +500,7 @@
 		pbx_builtin_setvar_helper(chan, "ERROR", "1");
 		return 0;
 	}
+	pbx_builtin_setvar_helper(chan, "ERROR", NULL);
 	datastore->data = speech;
 	ast_channel_datastore_add(chan, datastore);
 
@@ -743,7 +744,7 @@
 		/* Do timeout check (shared between audio/dtmf) */

[... 26780 lines stripped ...]



More information about the asterisk-commits mailing list