[asterisk-commits] mmichelson: branch mmichelson/queue-position r180438 - in /team/mmichelson/qu...

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Thu Mar 5 13:30:43 CST 2009


Author: mmichelson
Date: Thu Mar  5 13:30:15 2009
New Revision: 180438

URL: http://svn.digium.com/svn-view/asterisk?view=rev&rev=180438
Log:
Resync this forgotten branch.

Unlike the branches I've been deleting today, this old one still has
merit and seems like it may actually be close to complete. This may make
its way to reviewboard sometime soon.


Added:
    team/mmichelson/queue-position/apps/app_confbridge.c
      - copied unchanged from r180373, trunk/apps/app_confbridge.c
    team/mmichelson/queue-position/apps/app_playtones.c
      - copied unchanged from r180373, trunk/apps/app_playtones.c
    team/mmichelson/queue-position/bridges/   (props changed)
      - copied from r180373, trunk/bridges/
    team/mmichelson/queue-position/bridges/Makefile
      - copied unchanged from r180373, trunk/bridges/Makefile
    team/mmichelson/queue-position/bridges/bridge_builtin_features.c
      - copied unchanged from r180373, trunk/bridges/bridge_builtin_features.c
    team/mmichelson/queue-position/bridges/bridge_multiplexed.c
      - copied unchanged from r180373, trunk/bridges/bridge_multiplexed.c
    team/mmichelson/queue-position/bridges/bridge_simple.c
      - copied unchanged from r180373, trunk/bridges/bridge_simple.c
    team/mmichelson/queue-position/bridges/bridge_softmix.c
      - copied unchanged from r180373, trunk/bridges/bridge_softmix.c
    team/mmichelson/queue-position/channels/chan_bridge.c
      - copied unchanged from r180373, trunk/channels/chan_bridge.c
    team/mmichelson/queue-position/channels/h323/ast_ptlib.h
      - copied unchanged from r180373, trunk/channels/h323/ast_ptlib.h
    team/mmichelson/queue-position/contrib/editors/
      - copied from r180373, trunk/contrib/editors/
    team/mmichelson/queue-position/contrib/editors/ael.vim
      - copied unchanged from r180373, trunk/contrib/editors/ael.vim
    team/mmichelson/queue-position/contrib/editors/asterisk.vim
      - copied unchanged from r180373, trunk/contrib/editors/asterisk.vim
    team/mmichelson/queue-position/contrib/editors/asteriskvm.vim
      - copied unchanged from r180373, trunk/contrib/editors/asteriskvm.vim
    team/mmichelson/queue-position/doc/database_transactions.txt
      - copied unchanged from r180373, trunk/doc/database_transactions.txt
    team/mmichelson/queue-position/doc/timing.txt
      - copied unchanged from r180373, trunk/doc/timing.txt
    team/mmichelson/queue-position/formats/format_siren14.c
      - copied unchanged from r180373, trunk/formats/format_siren14.c
    team/mmichelson/queue-position/formats/format_siren7.c
      - copied unchanged from r180373, trunk/formats/format_siren7.c
    team/mmichelson/queue-position/funcs/func_aes.c
      - copied unchanged from r180373, trunk/funcs/func_aes.c
    team/mmichelson/queue-position/include/asterisk/bridging.h
      - copied unchanged from r180373, trunk/include/asterisk/bridging.h
    team/mmichelson/queue-position/include/asterisk/bridging_features.h
      - copied unchanged from r180373, trunk/include/asterisk/bridging_features.h
    team/mmichelson/queue-position/include/asterisk/bridging_technology.h
      - copied unchanged from r180373, trunk/include/asterisk/bridging_technology.h
    team/mmichelson/queue-position/include/asterisk/heap.h
      - copied unchanged from r180373, trunk/include/asterisk/heap.h
    team/mmichelson/queue-position/main/bridging.c
      - copied unchanged from r180373, trunk/main/bridging.c
    team/mmichelson/queue-position/main/heap.c
      - copied unchanged from r180373, trunk/main/heap.c
    team/mmichelson/queue-position/tests/test_heap.c
      - copied unchanged from r180373, trunk/tests/test_heap.c
    team/mmichelson/queue-position/tests/test_sched.c
      - copied unchanged from r180373, trunk/tests/test_sched.c
Removed:
    team/mmichelson/queue-position/channels/chan_features.c
    team/mmichelson/queue-position/res/res_indications.c
Modified:
    team/mmichelson/queue-position/   (props changed)
    team/mmichelson/queue-position/CHANGES
    team/mmichelson/queue-position/Makefile
    team/mmichelson/queue-position/README
    team/mmichelson/queue-position/UPGRADE.txt
    team/mmichelson/queue-position/apps/app_channelredirect.c
    team/mmichelson/queue-position/apps/app_chanspy.c
    team/mmichelson/queue-position/apps/app_dial.c
    team/mmichelson/queue-position/apps/app_dictate.c
    team/mmichelson/queue-position/apps/app_directed_pickup.c
    team/mmichelson/queue-position/apps/app_disa.c
    team/mmichelson/queue-position/apps/app_externalivr.c
    team/mmichelson/queue-position/apps/app_fax.c
    team/mmichelson/queue-position/apps/app_meetme.c
    team/mmichelson/queue-position/apps/app_milliwatt.c
    team/mmichelson/queue-position/apps/app_mixmonitor.c
    team/mmichelson/queue-position/apps/app_osplookup.c
    team/mmichelson/queue-position/apps/app_page.c
    team/mmichelson/queue-position/apps/app_parkandannounce.c
    team/mmichelson/queue-position/apps/app_queue.c
    team/mmichelson/queue-position/apps/app_read.c
    team/mmichelson/queue-position/apps/app_readexten.c
    team/mmichelson/queue-position/apps/app_record.c
    team/mmichelson/queue-position/apps/app_rpt.c
    team/mmichelson/queue-position/apps/app_speech_utils.c
    team/mmichelson/queue-position/apps/app_stack.c
    team/mmichelson/queue-position/apps/app_system.c
    team/mmichelson/queue-position/apps/app_voicemail.c
    team/mmichelson/queue-position/apps/app_waitforsilence.c
    team/mmichelson/queue-position/autoconf/ast_check_pwlib.m4
    team/mmichelson/queue-position/autoconf/ast_func_fork.m4
    team/mmichelson/queue-position/autoconf/ast_prog_sed.m4
    team/mmichelson/queue-position/build_tools/cflags.xml
    team/mmichelson/queue-position/cdr/cdr_sqlite3_custom.c
    team/mmichelson/queue-position/channels/chan_agent.c
    team/mmichelson/queue-position/channels/chan_dahdi.c
    team/mmichelson/queue-position/channels/chan_gtalk.c
    team/mmichelson/queue-position/channels/chan_h323.c
    team/mmichelson/queue-position/channels/chan_iax2.c
    team/mmichelson/queue-position/channels/chan_local.c
    team/mmichelson/queue-position/channels/chan_misdn.c
    team/mmichelson/queue-position/channels/chan_oss.c
    team/mmichelson/queue-position/channels/chan_sip.c
    team/mmichelson/queue-position/channels/chan_skinny.c
    team/mmichelson/queue-position/channels/chan_unistim.c
    team/mmichelson/queue-position/channels/h323/ast_h323.cxx
    team/mmichelson/queue-position/channels/h323/ast_h323.h
    team/mmichelson/queue-position/channels/h323/caps_h323.cxx
    team/mmichelson/queue-position/channels/h323/caps_h323.h
    team/mmichelson/queue-position/channels/h323/chan_h323.h
    team/mmichelson/queue-position/channels/h323/cisco-h225.cxx
    team/mmichelson/queue-position/channels/h323/cisco-h225.h
    team/mmichelson/queue-position/channels/h323/compat_h323.cxx
    team/mmichelson/queue-position/channels/h323/compat_h323.h
    team/mmichelson/queue-position/channels/iax2-parser.h
    team/mmichelson/queue-position/channels/iax2.h
    team/mmichelson/queue-position/codecs/codec_dahdi.c
    team/mmichelson/queue-position/configs/ais.conf.sample
    team/mmichelson/queue-position/configs/chan_dahdi.conf.sample
    team/mmichelson/queue-position/configs/extconfig.conf.sample
    team/mmichelson/queue-position/configs/extensions.conf.sample
    team/mmichelson/queue-position/configs/features.conf.sample
    team/mmichelson/queue-position/configs/func_odbc.conf.sample
    team/mmichelson/queue-position/configs/iax.conf.sample
    team/mmichelson/queue-position/configs/indications.conf.sample
    team/mmichelson/queue-position/configs/queues.conf.sample
    team/mmichelson/queue-position/configs/res_ldap.conf.sample
    team/mmichelson/queue-position/configs/res_odbc.conf.sample
    team/mmichelson/queue-position/configs/res_snmp.conf.sample
    team/mmichelson/queue-position/configs/sip.conf.sample
    team/mmichelson/queue-position/configs/skinny.conf.sample
    team/mmichelson/queue-position/configs/voicemail.conf.sample
    team/mmichelson/queue-position/configure
    team/mmichelson/queue-position/configure.ac
    team/mmichelson/queue-position/contrib/i18n.testsuite.conf
    team/mmichelson/queue-position/contrib/init.d/rc.archlinux.asterisk
    team/mmichelson/queue-position/contrib/init.d/rc.debian.asterisk
    team/mmichelson/queue-position/contrib/scripts/realtime_pgsql.sql
    team/mmichelson/queue-position/contrib/scripts/safe_asterisk
    team/mmichelson/queue-position/doc/distributed_devstate.txt
    team/mmichelson/queue-position/doc/manager_1_1.txt
    team/mmichelson/queue-position/doc/tex/Makefile
    team/mmichelson/queue-position/doc/tex/channelvariables.tex
    team/mmichelson/queue-position/doc/tex/extensions.tex
    team/mmichelson/queue-position/doc/unistim.txt
    team/mmichelson/queue-position/formats/format_ilbc.c
    team/mmichelson/queue-position/funcs/func_channel.c
    team/mmichelson/queue-position/funcs/func_odbc.c
    team/mmichelson/queue-position/funcs/func_strings.c
    team/mmichelson/queue-position/include/asterisk/_private.h
    team/mmichelson/queue-position/include/asterisk/app.h
    team/mmichelson/queue-position/include/asterisk/astobj2.h
    team/mmichelson/queue-position/include/asterisk/autoconfig.h.in
    team/mmichelson/queue-position/include/asterisk/causes.h
    team/mmichelson/queue-position/include/asterisk/channel.h
    team/mmichelson/queue-position/include/asterisk/compiler.h
    team/mmichelson/queue-position/include/asterisk/config.h
    team/mmichelson/queue-position/include/asterisk/features.h
    team/mmichelson/queue-position/include/asterisk/frame.h
    team/mmichelson/queue-position/include/asterisk/global_datastores.h
    team/mmichelson/queue-position/include/asterisk/hashtab.h
    team/mmichelson/queue-position/include/asterisk/indications.h
    team/mmichelson/queue-position/include/asterisk/linkedlists.h
    team/mmichelson/queue-position/include/asterisk/manager.h
    team/mmichelson/queue-position/include/asterisk/optional_api.h
    team/mmichelson/queue-position/include/asterisk/res_odbc.h
    team/mmichelson/queue-position/include/asterisk/rtp.h
    team/mmichelson/queue-position/include/asterisk/say.h
    team/mmichelson/queue-position/include/asterisk/sched.h
    team/mmichelson/queue-position/include/asterisk/slinfactory.h
    team/mmichelson/queue-position/include/asterisk/stringfields.h
    team/mmichelson/queue-position/include/asterisk/threadstorage.h
    team/mmichelson/queue-position/include/asterisk/timing.h
    team/mmichelson/queue-position/include/asterisk/utils.h
    team/mmichelson/queue-position/main/Makefile
    team/mmichelson/queue-position/main/abstract_jb.c
    team/mmichelson/queue-position/main/acl.c
    team/mmichelson/queue-position/main/aescrypt.c
    team/mmichelson/queue-position/main/alaw.c
    team/mmichelson/queue-position/main/app.c
    team/mmichelson/queue-position/main/ast_expr2.c
    team/mmichelson/queue-position/main/ast_expr2.fl
    team/mmichelson/queue-position/main/ast_expr2.h
    team/mmichelson/queue-position/main/ast_expr2.y
    team/mmichelson/queue-position/main/ast_expr2f.c
    team/mmichelson/queue-position/main/asterisk.c
    team/mmichelson/queue-position/main/astobj2.c
    team/mmichelson/queue-position/main/audiohook.c
    team/mmichelson/queue-position/main/callerid.c
    team/mmichelson/queue-position/main/channel.c
    team/mmichelson/queue-position/main/cli.c
    team/mmichelson/queue-position/main/config.c
    team/mmichelson/queue-position/main/editline/configure
    team/mmichelson/queue-position/main/editline/configure.in
    team/mmichelson/queue-position/main/editline/np/unvis.c
    team/mmichelson/queue-position/main/editline/sys.h
    team/mmichelson/queue-position/main/features.c
    team/mmichelson/queue-position/main/file.c
    team/mmichelson/queue-position/main/frame.c
    team/mmichelson/queue-position/main/global_datastores.c
    team/mmichelson/queue-position/main/hashtab.c
    team/mmichelson/queue-position/main/indications.c
    team/mmichelson/queue-position/main/jitterbuf.c
    team/mmichelson/queue-position/main/loader.c
    team/mmichelson/queue-position/main/logger.c
    team/mmichelson/queue-position/main/manager.c
    team/mmichelson/queue-position/main/pbx.c
    team/mmichelson/queue-position/main/rtp.c
    team/mmichelson/queue-position/main/say.c
    team/mmichelson/queue-position/main/sched.c
    team/mmichelson/queue-position/main/slinfactory.c
    team/mmichelson/queue-position/main/stdtime/localtime.c
    team/mmichelson/queue-position/main/strings.c
    team/mmichelson/queue-position/main/tcptls.c
    team/mmichelson/queue-position/main/timing.c
    team/mmichelson/queue-position/main/udptl.c
    team/mmichelson/queue-position/main/utils.c
    team/mmichelson/queue-position/main/xml.c
    team/mmichelson/queue-position/pbx/pbx_config.c
    team/mmichelson/queue-position/pbx/pbx_spool.c
    team/mmichelson/queue-position/res/ael/ael.tab.c
    team/mmichelson/queue-position/res/ael/ael.y
    team/mmichelson/queue-position/res/res_agi.c
    team/mmichelson/queue-position/res/res_ais.c
    team/mmichelson/queue-position/res/res_config_odbc.c
    team/mmichelson/queue-position/res/res_config_sqlite.c
    team/mmichelson/queue-position/res/res_jabber.c
    team/mmichelson/queue-position/res/res_musiconhold.c
    team/mmichelson/queue-position/res/res_odbc.c
    team/mmichelson/queue-position/res/res_timing_dahdi.c
    team/mmichelson/queue-position/res/res_timing_pthread.c
    team/mmichelson/queue-position/res/res_timing_timerfd.c
    team/mmichelson/queue-position/res/snmp/agent.c
    team/mmichelson/queue-position/sounds/Makefile
    team/mmichelson/queue-position/sounds/sounds.xml
    team/mmichelson/queue-position/utils/Makefile
    team/mmichelson/queue-position/utils/astcanary.c
    team/mmichelson/queue-position/utils/expr2.testinput
    team/mmichelson/queue-position/utils/refcounter.c

Propchange: team/mmichelson/queue-position/
------------------------------------------------------------------------------
    automerge = *

Propchange: team/mmichelson/queue-position/
------------------------------------------------------------------------------
Binary property 'branch-1.4-blocked' - no diff available.

Propchange: team/mmichelson/queue-position/
------------------------------------------------------------------------------
Binary property 'branch-1.4-merged' - no diff available.

Propchange: team/mmichelson/queue-position/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Thu Mar  5 13:30:15 2009
@@ -1,1 +1,1 @@
-/trunk:1-169643
+/trunk:1-180378

Modified: team/mmichelson/queue-position/CHANGES
URL: http://svn.digium.com/svn-view/asterisk/team/mmichelson/queue-position/CHANGES?view=diff&rev=180438&r1=180437&r2=180438
==============================================================================
--- team/mmichelson/queue-position/CHANGES (original)
+++ team/mmichelson/queue-position/CHANGES Thu Mar  5 13:30:15 2009
@@ -28,8 +28,8 @@
  * Added a new 'faxdetect=yes|no' configuration option to sip.conf.  When this
    option is enabled, a SIP channel will go to the fax extension (if it exists)
    after T38 is negotiated.  This option is disabled by default.
- * If ATTENDED_TRANSFER_COMPLETE_SOUND is set, the sound will be played to the
-   target of an attended transfer
+ * If the channel variable  ATTENDED_TRANSFER_COMPLETE_SOUND is set, 
+   the sound will be played to the target of an attended transfer
  * Added two new configuration options, "qualifygap" and "qualifypeers", which allow
    finer control over how many peers Asterisk will qualify and the gap between them
    when all peers need to be qualified at the same time.
@@ -44,8 +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
 --------------
@@ -57,6 +68,13 @@
 -------------
  * The UK option waitfordialtone has been added for use with BT analog
    lines.
+ * Added a 'faxbuffers' configuration option to chan_dahdi.conf.  This option
+   is used in conjunction with the 'faxdetect' configuration option.  When
+   'faxbuffers' is used and fax tones are detected, the channel will dynamically
+   switch to the configured faxbuffers policy.  For example, to use 6 buffers
+   and a 'full' buffer policy for a fax transmission, add:
+     faxbuffers=>6,full
+   The faxbuffers configuration will be in affect until the call is torn down.
 
 Dialplan Functions
 ------------------
@@ -78,6 +96,11 @@
    Totally.  Hopefully, that means more to you than it does to me.
  * Added AUDIOHOOK_INHERIT. For information on its use, please see the output
    of "core show function AUDIOHOOK_INHERIT" from the CLI
+ * Added AES_ENCRYPT. For information on its use, please see the output
+   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
 ------------
@@ -92,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
 -------------
@@ -122,6 +150,10 @@
  * The contrib/scripts/ directory now has a script called sip_nat_settings that will
    give you the correct output for an asterisk box behind nat. It will give you the
    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.
 
 Asterisk Manager Interface
 --------------------------
@@ -137,6 +169,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  -------------
@@ -327,6 +365,9 @@
   * A new configuration option, "timeoutpriority" has been added. Please see the section labeled
     "QUEUE TIMING OPTIONS" in configs/queues.conf.sample for a detailed explanation of the option
     as well as an explanation about timeout options in general
+  * Added a new option - C - for forcing the "answered elsewhere" flag on
+    cancellation of calls in to members of the queue. This is to avoid the
+    call to a member of a queue having the call listed as a "missed call".
 
 Realtime changes
 ----------------
@@ -715,6 +756,9 @@
   * Added a new parameter for member definition, called state_interface. This may be
     used so that a member may be called via one interface but have a different interface's
     device state reported.
+  * Added new CLI and Manager commands relating to reloading queues. From the CLI, see
+    "queue reload", "queue reset stats". Also see "manager show command QueueReload" and
+    "manager show command QueueReset."
   * New configuration option: randomperiodicannounce. If a list of periodic announcements is
     specified by the periodic-announce option, then one will be chosen randomly when it is time
     to play a periodic announcment
@@ -854,6 +898,13 @@
 Call Features (res_features) Changes
 ------------------------------------
   * Added the parkedcalltransfers option to features.conf
+  * Added parkedcallparking option to control one touch parking w/ parking
+    pickup
+  * Added parkedcallhangup option to control disconnect feature w/ parking
+    pickup
+  * Added parkedcallrecording option to control one-touch record w/ parking
+    pickup
+  * Added BRIDGE_FEATURES variable to set available features for a channel
   * The built-in method for doing attended transfers has been updated to
      include some new options that allow you to have the transferee sent
      back to the person that did the transfer if the transfer is not successful.

Modified: team/mmichelson/queue-position/Makefile
URL: http://svn.digium.com/svn-view/asterisk/team/mmichelson/queue-position/Makefile?view=diff&rev=180438&r1=180437&r2=180438
==============================================================================
--- team/mmichelson/queue-position/Makefile (original)
+++ team/mmichelson/queue-position/Makefile Thu Mar  5 13:30:15 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/mmichelson/queue-position/README
URL: http://svn.digium.com/svn-view/asterisk/team/mmichelson/queue-position/README?view=diff&rev=180438&r1=180437&r2=180438
==============================================================================
--- team/mmichelson/queue-position/README (original)
+++ team/mmichelson/queue-position/README Thu Mar  5 13:30:15 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/mmichelson/queue-position/UPGRADE.txt
URL: http://svn.digium.com/svn-view/asterisk/team/mmichelson/queue-position/UPGRADE.txt?view=diff&rev=180438&r1=180437&r2=180438
==============================================================================
--- team/mmichelson/queue-position/UPGRADE.txt (original)
+++ team/mmichelson/queue-position/UPGRADE.txt Thu Mar  5 13:30:15 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/mmichelson/queue-position/apps/app_channelredirect.c
URL: http://svn.digium.com/svn-view/asterisk/team/mmichelson/queue-position/apps/app_channelredirect.c?view=diff&rev=180438&r1=180437&r2=180438
==============================================================================
--- team/mmichelson/queue-position/apps/app_channelredirect.c (original)
+++ team/mmichelson/queue-position/apps/app_channelredirect.c Thu Mar  5 13:30:15 2009
@@ -93,6 +93,9 @@
 		return 0;
 	}
 
+	if (chan2->pbx) {
+		ast_set_flag(chan2, AST_FLAG_BRIDGE_HANGUP_DONT); /* don't let the after-bridge code run the h-exten */
+	}
 	res = ast_async_parseable_goto(chan2, args.label);
 	pbx_builtin_setvar_helper(chan, "CHANNELREDIRECT_STATUS", "SUCCESS");
 	ast_channel_unlock(chan2);

Modified: team/mmichelson/queue-position/apps/app_chanspy.c
URL: http://svn.digium.com/svn-view/asterisk/team/mmichelson/queue-position/apps/app_chanspy.c?view=diff&rev=180438&r1=180437&r2=180438
==============================================================================
--- team/mmichelson/queue-position/apps/app_chanspy.c (original)
+++ team/mmichelson/queue-position/apps/app_chanspy.c Thu Mar  5 13:30:15 2009
@@ -46,6 +46,7 @@
 #include "asterisk/say.h"
 #include "asterisk/pbx.h"
 #include "asterisk/translate.h"
+#include "asterisk/manager.h"
 #include "asterisk/module.h"
 #include "asterisk/lock.h"
 #include "asterisk/options.h"
@@ -456,8 +457,9 @@
 	}
 	ast_mutex_unlock(&spyee_chanspy_ds->lock);
 
-	if (!spyee)
+	if (!spyee) {
 		return 0;
+	}
 
 	/* We now hold the channel lock on spyee */
 
@@ -467,7 +469,12 @@
 	}
 
 	name = ast_strdupa(spyee->name);
+
 	ast_verb(2, "Spying on channel %s\n", name);
+	manager_event(EVENT_FLAG_CALL, "ChanSpyStart",
+			"SpyerChannel: %s\r\n"
+			"SpyeeChannel: %s\r\n",
+			spyer_name, name);
 
 	memset(&csth, 0, sizeof(csth));
 
@@ -611,19 +618,15 @@
 	ast_clear_flag(chan, AST_FLAG_END_DTMF_ONLY);
 	ast_channel_unlock(chan);
 
-	if (ast_test_flag(flags, OPTION_WHISPER)) {
-		ast_audiohook_lock(&csth.whisper_audiohook);
-		ast_audiohook_detach(&csth.whisper_audiohook);
-		ast_audiohook_unlock(&csth.whisper_audiohook);
-		ast_audiohook_destroy(&csth.whisper_audiohook);
-	}
-
-	if (ast_test_flag(flags, OPTION_BARGE)) {
-		ast_audiohook_lock(&csth.bridge_whisper_audiohook);
-		ast_audiohook_detach(&csth.bridge_whisper_audiohook);
-		ast_audiohook_unlock(&csth.bridge_whisper_audiohook);
-		ast_audiohook_destroy(&csth.bridge_whisper_audiohook);
-	}
+	ast_audiohook_lock(&csth.whisper_audiohook);
+	ast_audiohook_detach(&csth.whisper_audiohook);
+	ast_audiohook_unlock(&csth.whisper_audiohook);
+	ast_audiohook_destroy(&csth.whisper_audiohook);
+	
+	ast_audiohook_lock(&csth.bridge_whisper_audiohook);
+	ast_audiohook_detach(&csth.bridge_whisper_audiohook);
+	ast_audiohook_unlock(&csth.bridge_whisper_audiohook);
+	ast_audiohook_destroy(&csth.bridge_whisper_audiohook);
 
 	ast_audiohook_lock(&csth.spy_audiohook);
 	ast_audiohook_detach(&csth.spy_audiohook);
@@ -631,6 +634,7 @@
 	ast_audiohook_destroy(&csth.spy_audiohook);
 	
 	ast_verb(2, "Done Spying on channel %s\n", name);
+	manager_event(EVENT_FLAG_CALL, "ChanSpyStop", "SpyeeChannel: %s\r\n", name);
 
 	return running;
 }
@@ -833,22 +837,9 @@
 			 chanspy_ds_free(peer_chanspy_ds), prev = peer,
 		     peer_chanspy_ds = next_chanspy_ds ? next_chanspy_ds : 
 			 	next_channel(chan, prev, spec, exten, context, &chanspy_ds), next_chanspy_ds = NULL) {
-			const char *group;
 			int igrp = !mygroup;
-			char *groups[NUM_SPYGROUPS];
-			char *mygroups[NUM_SPYGROUPS];
-			int num_groups = 0;
-			char dup_group[512];
-			int num_mygroups = 0;
-			char *dup_mygroup;
-			int x;
-			int y;
+			int ienf = !myenforced;
 			char *s;
-			char *buffer;
-			char *end;
-			char *ext;
-			char *form_enforced;
-			int ienf = !myenforced;
 
 			peer = peer_chanspy_ds->chan;
 
@@ -877,7 +868,16 @@
 			}
 
 			if (mygroup) {
-				dup_mygroup = ast_strdupa(mygroup);
+				int num_groups = 0;
+				int num_mygroups = 0;
+				char dup_group[512];
+				char dup_mygroup[512];
+				char *groups[NUM_SPYGROUPS];
+				char *mygroups[NUM_SPYGROUPS];
+				const char *group;
+				int x;
+				int y;
+				ast_copy_string(dup_mygroup, mygroup, sizeof(dup_mygroup));
 				num_mygroups = ast_app_separate_args(dup_mygroup, ':', mygroups,
 					ARRAY_LEN(mygroups));
 
@@ -903,35 +903,28 @@
 			}
 
 			if (myenforced) {
-
-				/* We don't need to allocate more space than just the
-				length of (peer->name) for ext as we will cut the
-				channel name's ending before copying into ext */
-
-				ext = alloca(strlen(peer->name));
-
-				form_enforced = alloca(strlen(myenforced) + 3);
-
-				strcpy(form_enforced, ":");
-				strcat(form_enforced, myenforced);
-				strcat(form_enforced, ":");
-
-				buffer = ast_strdupa(peer->name);
-				
-				if ((end = strchr(buffer, '-'))) {
+				char ext[AST_CHANNEL_NAME + 3];
+				char buffer[512];
+				char *end;
+
+				snprintf(buffer, sizeof(buffer) - 1, ":%s:", myenforced);
+
+				ast_copy_string(ext + 1, peer->name, sizeof(ext) - 1);
+				if ((end = strchr(ext, '-'))) {
 					*end++ = ':';
 					*end = '\0';
 				}
 
-				strcpy(ext, ":");
-				strcat(ext, buffer);
-
-				if (strcasestr(form_enforced, ext))
+				ext[0] = ':';
+
+				if (strcasestr(buffer, ext)) {
 					ienf = 1;
-			}
-
-			if (!ienf)
+				}
+			}
+
+			if (!ienf) {
 				continue;
+			}
 
 			strcpy(peer_name, "spy-");
 			strncat(peer_name, peer->name, AST_NAME_STRLEN - 4 - 1);

Modified: team/mmichelson/queue-position/apps/app_dial.c
URL: http://svn.digium.com/svn-view/asterisk/team/mmichelson/queue-position/apps/app_dial.c?view=diff&rev=180438&r1=180437&r2=180438
==============================================================================
--- team/mmichelson/queue-position/apps/app_dial.c (original)
+++ team/mmichelson/queue-position/apps/app_dial.c Thu Mar  5 13:30:15 2009
@@ -524,8 +524,6 @@
 	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),
 	AST_APP_OPTION_ARG('m', OPT_MUSICBACK, OPT_ARG_MUSICBACK),
 	AST_APP_OPTION_ARG('M', OPT_CALLEE_MACRO, OPT_ARG_CALLEE_MACRO),
@@ -568,8 +566,12 @@
 	while (outgoing) {
 		/* Hangup any existing lines we have open */
 		if (outgoing->chan && (outgoing->chan != exception)) {
-			if (answered_elsewhere)
+			if (answered_elsewhere) {
+				/* The flag is used for local channel inheritance and stuff */
 				ast_set_flag(outgoing->chan, AST_FLAG_ANSWERED_ELSEWHERE);
+				/* This is for the channel drivers */
+				outgoing->chan->hangupcause = AST_CAUSE_ANSWERED_ELSEWHERE;
+			}
 			ast_hangup(outgoing->chan);
 		}
 		oo = outgoing;
@@ -775,6 +777,9 @@
 			}
 			/* Hangup the original channel now, in case we needed it */
 			ast_hangup(original);
+		}
+		if (single) {
+			ast_indicate(in, -1);
 		}
 	}
 }
@@ -1454,19 +1459,6 @@
 	return 1; /* success */
 }
 
-static void set_dial_features(struct ast_flags64 *opts, struct ast_dial_features *features)
-{
-	struct ast_flags64 perm_opts = {.flags = 0};
-
-	ast_copy_flags64(&perm_opts, opts,
-		OPT_CALLER_TRANSFER | OPT_CALLER_PARK | OPT_CALLER_MONITOR | OPT_CALLER_MIXMONITOR | OPT_CALLER_HANGUP |
-		OPT_CALLEE_TRANSFER | OPT_CALLEE_PARK | OPT_CALLEE_MONITOR | OPT_CALLEE_MIXMONITOR | OPT_CALLEE_HANGUP);
-
-	memset(features->options, 0, sizeof(features->options));
-
-	ast_app_options2str64(dial_exec_options, &perm_opts, features->options, sizeof(features->options));
-}
-
 static void end_bridge_callback(void *data)
 {
 	char buf[80];
@@ -1530,9 +1522,6 @@
 	struct ast_flags64 opts = { 0, };
 	char *opt_args[OPT_ARG_ARRAY_SIZE];
 	struct ast_datastore *datastore = NULL;
-	struct ast_datastore *ds_caller_features = NULL;
-	struct ast_datastore *ds_callee_features = NULL;
-	struct ast_dial_features *caller_features;
 	int fulldial = 0, num_dialed = 0;
 
 	/* Reset all DIAL variables back to blank, to prevent confusion (in case we don't reset all of them). */
@@ -1563,6 +1552,7 @@
 		pbx_builtin_setvar_helper(chan, "DIALSTATUS", pa.status);
 		goto done;
 	}
+
 
 	if (ast_test_flag64(&opts, OPT_OPERMODE)) {
 		opermode = ast_strlen_zero(opt_args[OPT_ARG_OPERMODE]) ? 1 : atoi(opt_args[OPT_ARG_OPERMODE]);
@@ -1601,6 +1591,10 @@
 		res = -1; /* reset default */
 	}
 
+	if (ast_test_flag64(&opts, OPT_DTMF_EXIT)) {
+		__ast_answer(chan, 0, 0);
+	}
+
 	if (continue_exec)
 		*continue_exec = 0;
 
@@ -1615,28 +1609,6 @@
 	}
 	ast_channel_unlock(chan);	
 	ast_copy_flags64(peerflags, &opts, OPT_DTMF_EXIT | OPT_GO_ON | OPT_ORIGINAL_CLID | OPT_CALLER_HANGUP | OPT_IGNORE_FORWARDING);
-
-	/* Create datastore for channel dial features for caller */
-	if (!(ds_caller_features = ast_datastore_alloc(&dial_features_info, NULL))) {
-		ast_log(LOG_WARNING, "Unable to create channel datastore for dial features. Aborting!\n");
-		goto out;
-	}
-
-	if (!(caller_features = ast_malloc(sizeof(*caller_features)))) {
-		ast_log(LOG_WARNING, "Unable to allocate memory for feature flags. Aborting!\n");
-		goto out;
-	}
-
-	ast_copy_flags(&(caller_features->features_callee), &(config.features_caller), AST_FLAGS_ALL);
-	caller_features->is_caller = 1;
-	set_dial_features(&opts, caller_features);
-
-	ds_caller_features->inheritance = DATASTORE_INHERIT_FOREVER;
-	ds_caller_features->data = caller_features;
-
-	ast_channel_lock(chan);
-	ast_channel_datastore_add(chan, ds_caller_features);
-	ast_channel_unlock(chan);
 
 	/* loop through the list of dial destinations */
 	rest = args.peers;
@@ -1649,7 +1621,6 @@
 		char *tech = strsep(&number, "/");
 		/* find if we already dialed this interface */
 		struct ast_dialed_interface *di;
-		struct ast_dial_features *callee_features;
 		AST_LIST_HEAD(, ast_dialed_interface) *dialed_interfaces;
 		num_dialed++;
 		if (!number) {
@@ -1777,6 +1748,14 @@
 		/* If we have an outbound group, set this peer channel to it */
 		if (outbound_group)
 			ast_app_group_set_channel(tc, outbound_group);
+		/* If the calling channel has the ANSWERED_ELSEWHERE flag set, inherit it. This is to support local channels */
+		if (ast_test_flag(chan, AST_FLAG_ANSWERED_ELSEWHERE))
+			ast_set_flag(tc, AST_FLAG_ANSWERED_ELSEWHERE);
+
+		/* Check if we're forced by configuration */
+		if (ast_test_flag64(&opts, OPT_CANCEL_ELSEWHERE))
+			 ast_set_flag(tc, AST_FLAG_ANSWERED_ELSEWHERE);
+
 
 		/* Inherit context and extension */
 		ast_string_field_set(tc, dialcontext, ast_strlen_zero(chan->macrocontext) ? chan->context : chan->macrocontext);
@@ -1784,30 +1763,6 @@
 			ast_copy_string(tc->exten, chan->macroexten, sizeof(tc->exten));
 		else
 			ast_copy_string(tc->exten, chan->exten, sizeof(tc->exten));
-
-		/* Save callee features */
-		if (!(ds_callee_features = ast_datastore_alloc(&dial_features_info, NULL))) {
-			ast_log(LOG_WARNING, "Unable to create channel datastore for dial features. Aborting!\n");
-			ast_free(tmp);
-			goto out;
-		}
-
-		if (!(callee_features = ast_malloc(sizeof(*callee_features)))) {
-			ast_log(LOG_WARNING, "Unable to allocate memory for feature flags. Aborting!\n");
-			ast_free(tmp);
-			goto out;
-		}
-
-		ast_copy_flags(&(callee_features->features_callee), &(config.features_callee), AST_FLAGS_ALL);
-		callee_features->is_caller = 0;
-		set_dial_features(&opts, callee_features);
-
-		ds_callee_features->inheritance = DATASTORE_INHERIT_FOREVER;

[... 35934 lines stripped ...]



More information about the asterisk-commits mailing list