[svn-commits] russell: branch russell/iax2_media r123330 - in /team/russell/iax2_media: ./ ...

SVN commits to the Digium repositories svn-commits at lists.digium.com
Tue Jun 17 12:55:08 CDT 2008


Author: russell
Date: Tue Jun 17 12:55:07 2008
New Revision: 123330

URL: http://svn.digium.com/view/asterisk?view=rev&rev=123330
Log:
resolve, reset

Added:
    team/russell/iax2_media/apps/app_dahdibarge.c
      - copied unchanged from r123275, trunk/apps/app_dahdibarge.c
    team/russell/iax2_media/apps/app_dahdiras.c
      - copied unchanged from r123275, trunk/apps/app_dahdiras.c
    team/russell/iax2_media/apps/app_dahdiscan.c
      - copied unchanged from r123275, trunk/apps/app_dahdiscan.c
    team/russell/iax2_media/channels/chan_dahdi.c
      - copied unchanged from r123275, trunk/channels/chan_dahdi.c
    team/russell/iax2_media/codecs/codec_dahdi.c
      - copied unchanged from r123275, trunk/codecs/codec_dahdi.c
    team/russell/iax2_media/include/asterisk/dahdi.h
      - copied unchanged from r123275, trunk/include/asterisk/dahdi.h
    team/russell/iax2_media/res/res_timing_dahdi.c
      - copied unchanged from r123275, trunk/res/res_timing_dahdi.c
    team/russell/iax2_media/res/res_timing_pthread.c
      - copied unchanged from r123275, trunk/res/res_timing_pthread.c
Removed:
    team/russell/iax2_media/apps/app_zapbarge.c
    team/russell/iax2_media/apps/app_zapras.c
    team/russell/iax2_media/apps/app_zapscan.c
    team/russell/iax2_media/channels/chan_zap.c
    team/russell/iax2_media/codecs/codec_zap.c
    team/russell/iax2_media/include/asterisk/zapata.h
Modified:
    team/russell/iax2_media/   (props changed)
    team/russell/iax2_media/Makefile
    team/russell/iax2_media/README
    team/russell/iax2_media/UPGRADE.txt
    team/russell/iax2_media/apps/app_chanisavail.c
    team/russell/iax2_media/apps/app_chanspy.c
    team/russell/iax2_media/apps/app_dial.c
    team/russell/iax2_media/apps/app_externalivr.c
    team/russell/iax2_media/apps/app_flash.c
    team/russell/iax2_media/apps/app_getcpeid.c
    team/russell/iax2_media/apps/app_meetme.c
    team/russell/iax2_media/apps/app_page.c
    team/russell/iax2_media/apps/app_parkandannounce.c
    team/russell/iax2_media/apps/app_queue.c
    team/russell/iax2_media/apps/app_rpt.c
    team/russell/iax2_media/apps/app_stack.c
    team/russell/iax2_media/build_tools/menuselect-deps.in
    team/russell/iax2_media/cdr/cdr_csv.c
    team/russell/iax2_media/cdr/cdr_tds.c
    team/russell/iax2_media/channels/chan_h323.c
    team/russell/iax2_media/channels/chan_iax2.c
    team/russell/iax2_media/channels/chan_mgcp.c
    team/russell/iax2_media/channels/chan_sip.c
    team/russell/iax2_media/channels/chan_skinny.c
    team/russell/iax2_media/channels/misdn/isdn_lib.c
    team/russell/iax2_media/configs/extensions.ael.sample
    team/russell/iax2_media/configs/extensions.conf.sample
    team/russell/iax2_media/configs/extensions.lua.sample
    team/russell/iax2_media/configs/meetme.conf.sample
    team/russell/iax2_media/configs/modules.conf.sample
    team/russell/iax2_media/configs/muted.conf.sample
    team/russell/iax2_media/configs/queues.conf.sample
    team/russell/iax2_media/configs/rpt.conf.sample
    team/russell/iax2_media/configs/sla.conf.sample
    team/russell/iax2_media/configs/smdi.conf.sample
    team/russell/iax2_media/configs/users.conf.sample
    team/russell/iax2_media/configs/vpb.conf.sample
    team/russell/iax2_media/configs/zapata.conf.sample
    team/russell/iax2_media/configure
    team/russell/iax2_media/configure.ac
    team/russell/iax2_media/contrib/init.d/rc.mandrake.asterisk
    team/russell/iax2_media/contrib/init.d/rc.mandrake.zaptel
    team/russell/iax2_media/contrib/init.d/rc.suse.asterisk
    team/russell/iax2_media/contrib/scripts/autosupport
    team/russell/iax2_media/contrib/scripts/loadtest.tcl
    team/russell/iax2_media/contrib/utils/zones2indications.c
    team/russell/iax2_media/doc/asterisk.8
    team/russell/iax2_media/doc/asterisk.sgml
    team/russell/iax2_media/doc/backtrace.txt
    team/russell/iax2_media/doc/janitor-projects.txt
    team/russell/iax2_media/doc/manager_1_1.txt
    team/russell/iax2_media/doc/osp.txt
    team/russell/iax2_media/doc/sms.txt
    team/russell/iax2_media/doc/ss7.txt
    team/russell/iax2_media/doc/tex/ael.tex
    team/russell/iax2_media/doc/tex/app-sms.tex
    team/russell/iax2_media/doc/tex/backtrace.tex
    team/russell/iax2_media/doc/tex/channelvariables.tex
    team/russell/iax2_media/doc/tex/configuration.tex
    team/russell/iax2_media/doc/tex/enum.tex
    team/russell/iax2_media/doc/tex/hardware.tex
    team/russell/iax2_media/doc/tex/localchannel.tex
    team/russell/iax2_media/doc/tex/manager.tex
    team/russell/iax2_media/doc/tex/privacy.tex
    team/russell/iax2_media/doc/tex/queues-with-callback-members.tex
    team/russell/iax2_media/doc/tex/security.tex
    team/russell/iax2_media/doc/tex/sla.tex
    team/russell/iax2_media/funcs/func_channel.c
    team/russell/iax2_media/include/asterisk/_private.h
    team/russell/iax2_media/include/asterisk/autoconfig.h.in
    team/russell/iax2_media/include/asterisk/callerid.h
    team/russell/iax2_media/include/asterisk/channel.h
    team/russell/iax2_media/include/asterisk/config.h
    team/russell/iax2_media/include/asterisk/doxyref.h
    team/russell/iax2_media/include/asterisk/dsp.h
    team/russell/iax2_media/include/asterisk/network.h
    team/russell/iax2_media/include/asterisk/options.h
    team/russell/iax2_media/include/asterisk/pbx.h
    team/russell/iax2_media/include/asterisk/timing.h
    team/russell/iax2_media/main/asterisk.c
    team/russell/iax2_media/main/astobj2.c
    team/russell/iax2_media/main/autoservice.c
    team/russell/iax2_media/main/callerid.c
    team/russell/iax2_media/main/channel.c
    team/russell/iax2_media/main/dial.c
    team/russell/iax2_media/main/features.c
    team/russell/iax2_media/main/file.c
    team/russell/iax2_media/main/loader.c
    team/russell/iax2_media/main/pbx.c
    team/russell/iax2_media/main/timing.c
    team/russell/iax2_media/makeopts.in
    team/russell/iax2_media/pbx/pbx_config.c
    team/russell/iax2_media/res/res_config_pgsql.c
    team/russell/iax2_media/res/res_musiconhold.c
    team/russell/iax2_media/utils/extconf.c

Propchange: team/russell/iax2_media/
------------------------------------------------------------------------------
    automerge = *

Propchange: team/russell/iax2_media/
------------------------------------------------------------------------------
Binary property 'branch-1.4-blocked' - no diff available.

Propchange: team/russell/iax2_media/
------------------------------------------------------------------------------
Binary property 'branch-1.4-merged' - no diff available.

Propchange: team/russell/iax2_media/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Tue Jun 17 12:55:07 2008
@@ -1,1 +1,1 @@
-/trunk:1-122202
+/trunk:1-123329

Modified: team/russell/iax2_media/Makefile
URL: http://svn.digium.com/view/asterisk/team/russell/iax2_media/Makefile?view=diff&rev=123330&r1=123329&r2=123330
==============================================================================
--- team/russell/iax2_media/Makefile (original)
+++ team/russell/iax2_media/Makefile Tue Jun 17 12:55:07 2008
@@ -680,6 +680,7 @@
 		echo ";transcode_via_sln = yes ; Build transcode paths via SLINEAR, instead of directly" ; \
 		echo ";runuser = asterisk ; The user to run as" ; \
 		echo ";rungroup = asterisk ; The group to run as" ; \
+		echo "dahdichanname = yes" ; Set channel name as DAHDI\
 		echo "" ; \
 		echo "; Changing the following lines may compromise your security." ; \
 		echo ";[files]" ; \

Modified: team/russell/iax2_media/README
URL: http://svn.digium.com/view/asterisk/team/russell/iax2_media/README?view=diff&rev=123330&r1=123329&r2=123330
==============================================================================
--- team/russell/iax2_media/README (original)
+++ team/russell/iax2_media/README Tue Jun 17 12:55:07 2008
@@ -175,7 +175,7 @@
 understand, and do not affect how it is actually parsed.
 
   Entries of the form 'variable=value' set the value of some parameter in
-asterisk.  For example, in zapata.conf, one might specify:
+asterisk.  For example, in dahdi.conf, one might specify:
 
 	switchtype=national
 

Modified: team/russell/iax2_media/UPGRADE.txt
URL: http://svn.digium.com/view/asterisk/team/russell/iax2_media/UPGRADE.txt?view=diff&rev=123330&r1=123329&r2=123330
==============================================================================
--- team/russell/iax2_media/UPGRADE.txt (original)
+++ team/russell/iax2_media/UPGRADE.txt Tue Jun 17 12:55:07 2008
@@ -181,6 +181,9 @@
 	sip:defaultuser at defaultip
   The "username" setting still work, but is deprecated and will not work in 
   the next version of Asterisk.
+* SIP: All of the functionality in SIPCHANINFO() has been implemented in CHANNEL(),
+  and you should start using that function instead for retrieving information about
+  the channel in a technology-agnostic way.
 
 * chan_local.c: the comma delimiter inside the channel name has been changed to a
   semicolon, in order to make the Local channel driver compatible with the comma

Modified: team/russell/iax2_media/apps/app_chanisavail.c
URL: http://svn.digium.com/view/asterisk/team/russell/iax2_media/apps/app_chanisavail.c?view=diff&rev=123330&r1=123329&r2=123330
==============================================================================
--- team/russell/iax2_media/apps/app_chanisavail.c (original)
+++ team/russell/iax2_media/apps/app_chanisavail.c Tue Jun 17 12:55:07 2008
@@ -75,7 +75,7 @@
 	);
 
 	if (ast_strlen_zero(data)) {
-		ast_log(LOG_WARNING, "ChanIsAvail requires an argument (Zap/1&Zap/2)\n");
+		ast_log(LOG_WARNING, "ChanIsAvail requires an argument (DAHDI/1&DAHDI/2)\n");
 		return -1;
 	}
 

Modified: team/russell/iax2_media/apps/app_chanspy.c
URL: http://svn.digium.com/view/asterisk/team/russell/iax2_media/apps/app_chanspy.c?view=diff&rev=123330&r1=123329&r2=123330
==============================================================================
--- team/russell/iax2_media/apps/app_chanspy.c (original)
+++ team/russell/iax2_media/apps/app_chanspy.c Tue Jun 17 12:55:07 2008
@@ -47,6 +47,7 @@
 #include "asterisk/translate.h"
 #include "asterisk/module.h"
 #include "asterisk/lock.h"
+#include "asterisk/options.h"
 
 #define AST_NAME_STRLEN 256
 #define NUM_SPYGROUPS 128
@@ -587,6 +588,7 @@
 	const char *exten, const char *context, struct chanspy_ds *chanspy_ds)
 {
 	struct ast_channel *next;
+	char channel_name[AST_CHANNEL_NAME];
 
 redo:
 	if (!ast_strlen_zero(spec))
@@ -599,7 +601,8 @@
 	if (!next)
 		return NULL;
 
-	if (!strncmp(next->name, "Zap/pseudo", 10)) {
+	snprintf(channel_name, AST_CHANNEL_NAME, "%s/pseudo", dahdi_chan_name);
+	if (!strncmp(next->name, channel_name, 10)) {
 		ast_channel_unlock(next);
 		goto redo;
 	} else if (next == chan) {

Modified: team/russell/iax2_media/apps/app_dial.c
URL: http://svn.digium.com/view/asterisk/team/russell/iax2_media/apps/app_dial.c?view=diff&rev=123330&r1=123329&r2=123330
==============================================================================
--- team/russell/iax2_media/apps/app_dial.c (original)
+++ team/russell/iax2_media/apps/app_dial.c Tue Jun 17 12:55:07 2008
@@ -171,8 +171,8 @@
 "    o    - Specify that the CallerID that was present on the *calling* channel\n"
 "           be set as the CallerID on the *called* channel. This was the\n"
 "           behavior of Asterisk 1.0 and earlier.\n"
-"    O([x]) - \"Operator Services\" mode (Zaptel channel to Zaptel channel\n"
-"             only, if specified on non-Zaptel interface, it will be ignored).\n"
+"    O([x]) - \"Operator Services\" mode (DAHDI channel to DAHDI channel\n"
+"             only, if specified on non-DAHDI interface, it will be ignored).\n"
 "             When the destination answers (presumably an operator services\n"
 "             station), the originator no longer has control of their line.\n"
 "             They may hang up, but the switch will not release their line\n"
@@ -1895,9 +1895,9 @@
 				res = -1;
 				goto done;
 			}
-			if (opermode && !strncmp(chan->name, "Zap", 3) && !strncmp(peer->name, "Zap", 3)) {
-				/* what's this special handling for Zap <-> Zap ?
-				 * A: Zap to Zap calls are natively bridged at the kernel driver
+			if (opermode && !strncmp(chan->tech->type, "DAHDI", 3) && !strncmp(peer->name, "DAHDI", 3)) {
+				/* what's this special handling for dahdi <-> dahdi ?
+				 * A: dahdi to dahdi calls are natively bridged at the kernel driver
 				 * level, so we need to ensure that this mode gets propagated
 				 * all the way down. */
 				struct oprmode oprmode;
@@ -2098,7 +2098,7 @@
 	res |= ast_unregister_application(rapp);
 
 	if ((con = ast_context_find("app_dial_gosub_virtual_context"))) {
-		ast_context_remove_extension2(con, "s", 1, NULL);
+		ast_context_remove_extension2(con, "s", 1, NULL, 0);
 		ast_context_destroy(con, "app_dial"); /* leave nothing behind */
 	}
 

Modified: team/russell/iax2_media/apps/app_externalivr.c
URL: http://svn.digium.com/view/asterisk/team/russell/iax2_media/apps/app_externalivr.c?view=diff&rev=123330&r1=123329&r2=123330
==============================================================================
--- team/russell/iax2_media/apps/app_externalivr.c (original)
+++ team/russell/iax2_media/apps/app_externalivr.c Tue Jun 17 12:55:07 2008
@@ -373,7 +373,7 @@
 		/* Put the application + the arguments in a | delimited list */
 		ast_str_reset(pipe_delim_args);
 		for (j = 0; application_args.cmd[j] != NULL; j++) {
-			ast_str_append(&pipe_delim_args, 0, "%s%s", j == 0 ? "" : "|", application_args.cmd[j]);
+			ast_str_append(&pipe_delim_args, 0, "%s%s", j == 0 ? "" : ",", application_args.cmd[j]);
 		}
 
 		/* Parse the ExternalIVR() arguments */

Modified: team/russell/iax2_media/apps/app_flash.c
URL: http://svn.digium.com/view/asterisk/team/russell/iax2_media/apps/app_flash.c?view=diff&rev=123330&r1=123329&r2=123330
==============================================================================
--- team/russell/iax2_media/apps/app_flash.c (original)
+++ team/russell/iax2_media/apps/app_flash.c Tue Jun 17 12:55:07 2008
@@ -18,7 +18,7 @@
 
 /*! \file
  *
- * \brief App to flash a zap trunk
+ * \brief App to flash a DAHDI trunk
  *
  * \author Mark Spencer <markster at digium.com>
  * 
@@ -26,14 +26,14 @@
  */
  
 /*** MODULEINFO
-	<depend>zaptel</depend>
+	<depend>dahdi</depend>
  ***/
 
 #include "asterisk.h"
 
 ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
 
-#include "asterisk/zapata.h"
+#include "asterisk/dahdi.h"
 
 #include "asterisk/lock.h"
 #include "asterisk/file.h"
@@ -45,22 +45,22 @@
 
 static char *app = "Flash";
 
-static char *synopsis = "Flashes a Zap Trunk";
+static char *synopsis = "Flashes a DAHDI Trunk";
 
 static char *descrip = 
-"Performs a flash on a zap trunk.  This can be used\n"
+"Performs a flash on a DAHDI trunk.  This can be used\n"
 "to access features provided on an incoming analogue circuit\n"
 "such as conference and call waiting. Use with SendDTMF() to\n"
 "perform external transfers\n";
 
 
-static inline int zt_wait_event(int fd)
+static inline int dahdi_wait_event(int fd)
 {
-	/* Avoid the silly zt_waitevent which ignores a bunch of events */
+	/* Avoid the silly dahdi_waitevent which ignores a bunch of events */
 	int i,j=0;
-	i = ZT_IOMUX_SIGEVENT;
-	if (ioctl(fd, ZT_IOMUX, &i) == -1) return -1;
-	if (ioctl(fd, ZT_GETEVENT, &j) == -1) return -1;
+	i = DAHDI_IOMUX_SIGEVENT;
+	if (ioctl(fd, DAHDI_IOMUX, &i) == -1) return -1;
+	if (ioctl(fd, DAHDI_GETEVENT, &j) == -1) return -1;
 	return j;
 }
 
@@ -68,23 +68,23 @@
 {
 	int res = -1;
 	int x;
-	struct zt_params ztp;
+	struct dahdi_params dahdip;
 
-	if (strcasecmp(chan->tech->type, "Zap")) {
-		ast_log(LOG_WARNING, "%s is not a Zap channel\n", chan->name);
+	if (strcasecmp(chan->tech->type, "DAHDI")) {
+		ast_log(LOG_WARNING, "%s is not a DAHDI channel\n", chan->name);
 		return -1;
 	}
 	
-	memset(&ztp, 0, sizeof(ztp));
-	res = ioctl(chan->fds[0], ZT_GET_PARAMS, &ztp);
+	memset(&dahdip, 0, sizeof(dahdip));
+	res = ioctl(chan->fds[0], DAHDI_GET_PARAMS, &dahdip);
 	if (!res) {
-		if (ztp.sigtype & __ZT_SIG_FXS) {
-			x = ZT_FLASH;
-			res = ioctl(chan->fds[0], ZT_HOOK, &x);
+		if (dahdip.sigtype & __DAHDI_SIG_FXS) {
+			x = DAHDI_FLASH;
+			res = ioctl(chan->fds[0], DAHDI_HOOK, &x);
 			if (!res || (errno == EINPROGRESS)) {
 				if (res) {
 					/* Wait for the event to finish */
-					zt_wait_event(chan->fds[0]);
+					dahdi_wait_event(chan->fds[0]);
 				}
 				res = ast_safe_sleep(chan, 1000);
 				ast_verb(3, "Flashed channel %s\n", chan->name);

Modified: team/russell/iax2_media/apps/app_getcpeid.c
URL: http://svn.digium.com/view/asterisk/team/russell/iax2_media/apps/app_getcpeid.c?view=diff&rev=123330&r1=123329&r2=123330
==============================================================================
--- team/russell/iax2_media/apps/app_getcpeid.c (original)
+++ team/russell/iax2_media/apps/app_getcpeid.c Tue Jun 17 12:55:07 2008
@@ -42,7 +42,7 @@
 
 static char *descrip =
 "  GetCPEID(): Obtains and displays ADSI CPE ID and other information in order\n"
-"to properly setup zapata.conf for on-hook operations.\n";
+"to properly setup dahdi.conf for on-hook operations.\n";
 
 
 static int cpeid_setstatus(struct ast_channel *chan, char *stuff[], int voice)

Modified: team/russell/iax2_media/apps/app_meetme.c
URL: http://svn.digium.com/view/asterisk/team/russell/iax2_media/apps/app_meetme.c?view=diff&rev=123330&r1=123329&r2=123330
==============================================================================
--- team/russell/iax2_media/apps/app_meetme.c (original)
+++ team/russell/iax2_media/apps/app_meetme.c Tue Jun 17 12:55:07 2008
@@ -30,14 +30,14 @@
  */
 
 /*** MODULEINFO
-	<depend>zaptel</depend>
+	<depend>dahdi</depend>
  ***/
 
 #include "asterisk.h"
 
 ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
 
-#include "asterisk/zapata.h"
+#include "asterisk/dahdi.h"
 
 #include "asterisk/lock.h"
 #include "asterisk/file.h"
@@ -228,15 +228,15 @@
 "conference.  If the conference number is omitted, the user will be prompted\n"
 "to enter one.  User can exit the conference by hangup, or if the 'p' option\n"
 "is specified, by pressing '#'.\n"
-"Please note: The Zaptel kernel modules and at least one hardware driver (or ztdummy)\n"
-"             must be present for conferencing to operate properly. In addition, the chan_zap\n"
+"Please note: The DAHDI kernel modules and at least one hardware driver (or dahdi_dummy)\n"
+"             must be present for conferencing to operate properly. In addition, the chan_dahdi\n"
 "             channel driver must be loaded for the 'i' and 'r' options to operate at all.\n\n"
 "The option string may contain zero or more of the following characters:\n"
 "      'a' -- set admin mode\n"
 "      'A' -- set marked mode\n"
 "      'b' -- run AGI script specified in ${MEETME_AGI_BACKGROUND}\n"
 "             Default: conf-background.agi  (Note: This does not work with\n"
-"             non-Zap channels in the same conference)\n"
+"             non-DAHDI channels in the same conference)\n"
 "      'c' -- announce user(s) count on joining a conference\n"
 "      'C' -- continue in dialplan when kicked out of conference\n"
 "      'd' -- dynamically add conference\n"
@@ -361,7 +361,7 @@
 	struct ast_channel *chan;               /*!< Announcements channel */
 	struct ast_channel *lchan;              /*!< Listen/Record channel */
 	int fd;                                 /*!< Announcements fd */
-	int zapconf;                            /*!< Zaptel Conf # */
+	int dahdiconf;                            /*!< DAHDI Conf # */
 	int users;                              /*!< Number of active users */
 	int markedusers;                        /*!< Number of marked users */
 	int maxusers;                           /*!< Participant limit if scheduled */
@@ -403,7 +403,7 @@
 	int adminflags;                         /*!< Flags set by the Admin */
 	struct ast_channel *chan;               /*!< Connected channel */
 	int talking;                            /*!< Is user talking */
-	int zapchannel;                         /*!< Is a Zaptel channel */
+	int dahdichannel;                         /*!< Is a DAHDI channel */
 	char usrvalue[50];                      /*!< Custom User Value */
 	char namerecloc[PATH_MAX];				/*!< Name Recorded file Location */
 	time_t jointime;                        /*!< Time the user joined the conference */
@@ -639,8 +639,8 @@
 
 	while (len) {
 		if (block) {
-			x = ZT_IOMUX_WRITE | ZT_IOMUX_SIGEVENT;
-			res = ioctl(fd, ZT_IOMUX, &x);
+			x = DAHDI_IOMUX_WRITE | DAHDI_IOMUX_SIGEVENT;
+			res = ioctl(fd, DAHDI_IOMUX, &x);
 		} else
 			res = 0;
 		if (res >= 0)
@@ -801,7 +801,7 @@
 static struct ast_conference *build_conf(char *confno, char *pin, char *pinadmin, int make, int dynamic, int refcount, const struct ast_channel *chan)
 {
 	struct ast_conference *cnf;
-	struct zt_confinfo ztc = { 0, };
+	struct dahdi_confinfo dahdic = { 0, };
 	int confno_int = 0;
 
 	AST_LIST_LOCK(&confs);
@@ -827,11 +827,11 @@
 	ast_copy_string(cnf->pinadmin, pinadmin, sizeof(cnf->pinadmin));
 	ast_copy_string(cnf->uniqueid, chan->uniqueid, sizeof(cnf->uniqueid));
 
-	/* Setup a new zap conference */
-	ztc.confno = -1;
-	ztc.confmode = ZT_CONF_CONFANN | ZT_CONF_CONFANNMON;
-	cnf->fd = open("/dev/zap/pseudo", O_RDWR);
-	if (cnf->fd < 0 || ioctl(cnf->fd, ZT_SETCONF, &ztc)) {
+	/* Setup a new dahdi conference */
+	dahdic.confno = -1;
+	dahdic.confmode = DAHDI_CONF_CONFANN | DAHDI_CONF_CONFANNMON;
+	cnf->fd = open("/dev/dahdi/pseudo", O_RDWR);
+	if (cnf->fd < 0 || ioctl(cnf->fd, DAHDI_SETCONF, &dahdic)) {
 		ast_log(LOG_WARNING, "Unable to open pseudo device\n");
 		if (cnf->fd >= 0)
 			close(cnf->fd);
@@ -840,17 +840,17 @@
 		goto cnfout;
 	}
 
-	cnf->zapconf = ztc.confno;
+	cnf->dahdiconf = dahdic.confno;
 
 	/* Setup a new channel for playback of audio files */
-	cnf->chan = ast_request("zap", AST_FORMAT_SLINEAR, "pseudo", NULL);
+	cnf->chan = ast_request("DAHDI", AST_FORMAT_SLINEAR, "pseudo", NULL);
 	if (cnf->chan) {
 		ast_set_read_format(cnf->chan, AST_FORMAT_SLINEAR);
 		ast_set_write_format(cnf->chan, AST_FORMAT_SLINEAR);
-		ztc.chan = 0;
-		ztc.confno = cnf->zapconf;
-		ztc.confmode = ZT_CONF_CONFANN | ZT_CONF_CONFANNMON;
-		if (ioctl(cnf->chan->fds[0], ZT_SETCONF, &ztc)) {
+		dahdic.chan = 0;
+		dahdic.confno = cnf->dahdiconf;
+		dahdic.confmode = DAHDI_CONF_CONFANN | DAHDI_CONF_CONFANNMON;
+		if (ioctl(cnf->chan->fds[0], DAHDI_SETCONF, &dahdic)) {
 			ast_log(LOG_WARNING, "Error setting conference\n");
 			if (cnf->chan)
 				ast_hangup(cnf->chan);
@@ -867,7 +867,7 @@
 	cnf->start = time(NULL);
 	cnf->maxusers = 0x7fffffff;
 	cnf->isdynamic = dynamic ? 1 : 0;
-	ast_verb(3, "Created MeetMe conference %d for conference '%s'\n", cnf->zapconf, cnf->confno);
+	ast_verb(3, "Created MeetMe conference %d for conference '%s'\n", cnf->dahdiconf, cnf->confno);
 	AST_LIST_INSERT_HEAD(&confs, cnf, list);
 
 	/* Reserve conference number in map */
@@ -1309,8 +1309,8 @@
 	}
 
 	/* flush any data sitting in the pseudo channel */
-	x = ZT_FLUSH_ALL;
-	if (ioctl(fd, ZT_FLUSH, &x))
+	x = DAHDI_FLUSH_ALL;
+	if (ioctl(fd, DAHDI_FLUSH, &x))
 		ast_log(LOG_WARNING, "Error flushing channel\n");
 
 }
@@ -1484,7 +1484,7 @@
 	struct ast_conf_user *user = NULL;
 	struct ast_conf_user *usr = NULL;
 	int fd;
-	struct zt_confinfo ztc, ztc_empty;
+	struct dahdi_confinfo dahdic, dahdic_empty;
 	struct ast_frame *f;
 	struct ast_channel *c;
 	struct ast_frame fr;
@@ -1493,7 +1493,7 @@
 	int nfds;
 	int res;
 	int flags;
-	int retryzap;
+	int retrydahdi;
 	int origfd;
 	int musiconhold = 0;
 	int firstpass = 0;
@@ -1520,7 +1520,7 @@
 	char members[10] = "";
 	int dtmf, opt_waitmarked_timeout = 0;
 	time_t timeout = 0;
-	ZT_BUFFERINFO bi;
+	DAHDI_BUFFERINFO bi;
 	char __buf[CONF_SIZE + AST_FRIENDLY_OFFSET];
 	char *buf = __buf + AST_FRIENDLY_OFFSET;
 	char *exitkeys = NULL;
@@ -1645,13 +1645,13 @@
 	}
 
 	ast_mutex_lock(&conf->recordthreadlock);
-	if ((conf->recordthread == AST_PTHREADT_NULL) && (confflags & CONFFLAG_RECORDCONF) && ((conf->lchan = ast_request("zap", AST_FORMAT_SLINEAR, "pseudo", NULL)))) {
+	if ((conf->recordthread == AST_PTHREADT_NULL) && (confflags & CONFFLAG_RECORDCONF) && ((conf->lchan = ast_request("DAHDI", AST_FORMAT_SLINEAR, "pseudo", NULL)))) {
 		ast_set_read_format(conf->lchan, AST_FORMAT_SLINEAR);
 		ast_set_write_format(conf->lchan, AST_FORMAT_SLINEAR);
-		ztc.chan = 0;
-		ztc.confno = conf->zapconf;
-		ztc.confmode = ZT_CONF_CONFANN | ZT_CONF_CONFANNMON;
-		if (ioctl(conf->lchan->fds[0], ZT_SETCONF, &ztc)) {
+		dahdic.chan = 0;
+		dahdic.confno = conf->dahdiconf;
+		dahdic.confmode = DAHDI_CONF_CONFANN | DAHDI_CONF_CONFANNMON;
+		if (ioctl(conf->lchan->fds[0], DAHDI_SETCONF, &dahdic)) {
 			ast_log(LOG_WARNING, "Error starting listen channel\n");
 			ast_hangup(conf->lchan);
 			conf->lchan = NULL;
@@ -1832,13 +1832,13 @@
 		goto outrun;
 	}
 
-	retryzap = (strcasecmp(chan->tech->type, "Zap") || (chan->audiohooks || chan->monitor) ? 1 : 0);
-	user->zapchannel = !retryzap;
-
- zapretry:
+	retrydahdi = (strcasecmp(chan->tech->type, "DAHDI") || (chan->audiohooks || chan->monitor) ? 1 : 0);
+	user->dahdichannel = !retrydahdi;
+
+ dahdiretry:
 	origfd = chan->fds[0];
-	if (retryzap) {
-		fd = open("/dev/zap/pseudo", O_RDWR);
+	if (retrydahdi) {
+		fd = open("/dev/dahdi/pseudo", O_RDWR);
 		if (fd < 0) {
 			ast_log(LOG_WARNING, "Unable to open pseudo channel: %s\n", strerror(errno));
 			goto outrun;
@@ -1859,16 +1859,16 @@
 		/* Setup buffering information */
 		memset(&bi, 0, sizeof(bi));
 		bi.bufsize = CONF_SIZE / 2;
-		bi.txbufpolicy = ZT_POLICY_IMMEDIATE;
-		bi.rxbufpolicy = ZT_POLICY_IMMEDIATE;
+		bi.txbufpolicy = DAHDI_POLICY_IMMEDIATE;
+		bi.rxbufpolicy = DAHDI_POLICY_IMMEDIATE;
 		bi.numbufs = audio_buffers;
-		if (ioctl(fd, ZT_SET_BUFINFO, &bi)) {
+		if (ioctl(fd, DAHDI_SET_BUFINFO, &bi)) {
 			ast_log(LOG_WARNING, "Unable to set buffering information: %s\n", strerror(errno));
 			close(fd);
 			goto outrun;
 		}
 		x = 1;
-		if (ioctl(fd, ZT_SETLINEAR, &x)) {
+		if (ioctl(fd, DAHDI_SETLINEAR, &x)) {
 			ast_log(LOG_WARNING, "Unable to set linear mode: %s\n", strerror(errno));
 			close(fd);
 			goto outrun;
@@ -1879,27 +1879,27 @@
 		fd = chan->fds[0];
 		nfds = 0;
 	}
-	memset(&ztc, 0, sizeof(ztc));
-	memset(&ztc_empty, 0, sizeof(ztc_empty));
+	memset(&dahdic, 0, sizeof(dahdic));
+	memset(&dahdic_empty, 0, sizeof(dahdic_empty));
 	/* Check to see if we're in a conference... */
-	ztc.chan = 0;	
-	if (ioctl(fd, ZT_GETCONF, &ztc)) {
+	dahdic.chan = 0;	
+	if (ioctl(fd, DAHDI_GETCONF, &dahdic)) {
 		ast_log(LOG_WARNING, "Error getting conference\n");
 		close(fd);
 		goto outrun;
 	}
-	if (ztc.confmode) {
+	if (dahdic.confmode) {
 		/* Whoa, already in a conference...  Retry... */
-		if (!retryzap) {
-			ast_debug(1, "Zap channel is in a conference already, retrying with pseudo\n");
-			retryzap = 1;
-			goto zapretry;
-		}
-	}
-	memset(&ztc, 0, sizeof(ztc));
+		if (!retrydahdi) {
+			ast_debug(1, "DAHDI channel is in a conference already, retrying with pseudo\n");
+			retrydahdi = 1;
+			goto dahdiretry;
+		}
+	}
+	memset(&dahdic, 0, sizeof(dahdic));
 	/* Add us to the conference */
-	ztc.chan = 0;	
-	ztc.confno = conf->zapconf;
+	dahdic.chan = 0;	
+	dahdic.confno = conf->dahdiconf;
 
 	ast_mutex_lock(&conf->playlock);
 
@@ -1913,21 +1913,21 @@
 	}
 
 	if (confflags & CONFFLAG_WAITMARKED && !conf->markedusers)
-		ztc.confmode = ZT_CONF_CONF;
+		dahdic.confmode = DAHDI_CONF_CONF;
 	else if (confflags & CONFFLAG_MONITOR)
-		ztc.confmode = ZT_CONF_CONFMON | ZT_CONF_LISTENER;
+		dahdic.confmode = DAHDI_CONF_CONFMON | DAHDI_CONF_LISTENER;
 	else if (confflags & CONFFLAG_TALKER)
-		ztc.confmode = ZT_CONF_CONF | ZT_CONF_TALKER;
+		dahdic.confmode = DAHDI_CONF_CONF | DAHDI_CONF_TALKER;
 	else 
-		ztc.confmode = ZT_CONF_CONF | ZT_CONF_TALKER | ZT_CONF_LISTENER;
-
-	if (ioctl(fd, ZT_SETCONF, &ztc)) {
+		dahdic.confmode = DAHDI_CONF_CONF | DAHDI_CONF_TALKER | DAHDI_CONF_LISTENER;
+
+	if (ioctl(fd, DAHDI_SETCONF, &dahdic)) {
 		ast_log(LOG_WARNING, "Error setting conference\n");
 		close(fd);
 		ast_mutex_unlock(&conf->playlock);
 		goto outrun;
 	}
-	ast_debug(1, "Placed channel %s in ZAP conf %d\n", chan->name, conf->zapconf);
+	ast_debug(1, "Placed channel %s in ZAP conf %d\n", chan->name, conf->dahdiconf);
 
 	if (!sent_event) {
 		manager_event(EVENT_FLAG_CALL, "MeetmeJoin", 
@@ -1968,8 +1968,8 @@
 		}
 		ast_channel_unlock(chan);
 		
-		if (user->zapchannel) {
-			/*  Set CONFMUTE mode on Zap channel to mute DTMF tones */
+		if (user->dahdichannel) {
+			/*  Set CONFMUTE mode on DAHDI channel to mute DTMF tones */
 			x = 1;
 			ast_channel_setoption(chan, AST_OPTION_TONE_VERIFY, &x, sizeof(char), 0);
 		}
@@ -1981,14 +1981,14 @@
 			ast_log(LOG_WARNING, "Could not find application (agi)\n");
 			ret = -2;
 		}
-		if (user->zapchannel) {
-			/*  Remove CONFMUTE mode on Zap channel */
+		if (user->dahdichannel) {
+			/*  Remove CONFMUTE mode on DAHDI channel */
 			x = 0;
 			ast_channel_setoption(chan, AST_OPTION_TONE_VERIFY, &x, sizeof(char), 0);
 		}
 	} else {
-		if (user->zapchannel && (confflags & CONFFLAG_STARMENU)) {
-			/*  Set CONFMUTE mode on Zap channel to mute DTMF tones when the menu is enabled */
+		if (user->dahdichannel && (confflags & CONFFLAG_STARMENU)) {
+			/*  Set CONFMUTE mode on DAHDI channel to mute DTMF tones when the menu is enabled */
 			x = 1;
 			ast_channel_setoption(chan, AST_OPTION_TONE_VERIFY, &x, sizeof(char), 0);
 		}	
@@ -2139,8 +2139,8 @@
 								ret = 0;
 							break;
 						} else {
-							ztc.confmode = ZT_CONF_CONF;
-							if (ioctl(fd, ZT_SETCONF, &ztc)) {
+							dahdic.confmode = DAHDI_CONF_CONF;
+							if (ioctl(fd, DAHDI_SETCONF, &dahdic)) {
 								ast_log(LOG_WARNING, "Error setting conference\n");
 								close(fd);
 								goto outrun;
@@ -2155,12 +2155,12 @@
 					/* Marked user entered, so cancel timeout */
 					timeout = 0;
 					if (confflags & CONFFLAG_MONITOR)
-						ztc.confmode = ZT_CONF_CONFMON | ZT_CONF_LISTENER;
+						dahdic.confmode = DAHDI_CONF_CONFMON | DAHDI_CONF_LISTENER;
 					else if (confflags & CONFFLAG_TALKER)
-						ztc.confmode = ZT_CONF_CONF | ZT_CONF_TALKER;
+						dahdic.confmode = DAHDI_CONF_CONF | DAHDI_CONF_TALKER;
 					else
-						ztc.confmode = ZT_CONF_CONF | ZT_CONF_TALKER | ZT_CONF_LISTENER;
-					if (ioctl(fd, ZT_SETCONF, &ztc)) {
+						dahdic.confmode = DAHDI_CONF_CONF | DAHDI_CONF_TALKER | DAHDI_CONF_LISTENER;
+					if (ioctl(fd, DAHDI_SETCONF, &dahdic)) {
 						ast_log(LOG_WARNING, "Error setting conference\n");
 						close(fd);
 						goto outrun;
@@ -2204,9 +2204,9 @@
 			/* Check if my modes have changed */
 
 			/* If I should be muted but am still talker, mute me */
-			if ((user->adminflags & (ADMINFLAG_MUTED | ADMINFLAG_SELFMUTED)) && (ztc.confmode & ZT_CONF_TALKER)) {
-				ztc.confmode ^= ZT_CONF_TALKER;
-				if (ioctl(fd, ZT_SETCONF, &ztc)) {
+			if ((user->adminflags & (ADMINFLAG_MUTED | ADMINFLAG_SELFMUTED)) && (dahdic.confmode & DAHDI_CONF_TALKER)) {
+				dahdic.confmode ^= DAHDI_CONF_TALKER;
+				if (ioctl(fd, DAHDI_SETCONF, &dahdic)) {
 					ast_log(LOG_WARNING, "Error setting conference - Un/Mute \n");
 					ret = -1;
 					break;
@@ -2222,9 +2222,9 @@
 			}
 
 			/* If I should be un-muted but am not talker, un-mute me */
-			if (!(user->adminflags & (ADMINFLAG_MUTED | ADMINFLAG_SELFMUTED)) && !(confflags & CONFFLAG_MONITOR) && !(ztc.confmode & ZT_CONF_TALKER)) {
-				ztc.confmode |= ZT_CONF_TALKER;
-				if (ioctl(fd, ZT_SETCONF, &ztc)) {
+			if (!(user->adminflags & (ADMINFLAG_MUTED | ADMINFLAG_SELFMUTED)) && !(confflags & CONFFLAG_MONITOR) && !(dahdic.confmode & DAHDI_CONF_TALKER)) {
+				dahdic.confmode |= DAHDI_CONF_TALKER;
+				if (ioctl(fd, DAHDI_SETCONF, &dahdic)) {
 					ast_log(LOG_WARNING, "Error setting conference - Un/Mute \n");
 					ret = -1;
 					break;
@@ -2283,16 +2283,16 @@
 			if (c) {
 				char dtmfstr[2] = "";
 
-				if (c->fds[0] != origfd || (user->zapchannel && (c->audiohooks || c->monitor))) {
+				if (c->fds[0] != origfd || (user->dahdichannel && (c->audiohooks || c->monitor))) {
 					if (using_pseudo) {
 						/* Kill old pseudo */
 						close(fd);
 						using_pseudo = 0;
 					}
 					ast_debug(1, "Ooh, something swapped out under us, starting over\n");
-					retryzap = (strcasecmp(c->tech->type, "Zap") || (c->audiohooks || c->monitor) ? 1 : 0);
-					user->zapchannel = !retryzap;
-					goto zapretry;
+					retrydahdi = (strcasecmp(c->tech->type, "DAHDI") || (c->audiohooks || c->monitor) ? 1 : 0);
+					user->dahdichannel = !retrydahdi;
+					goto dahdiretry;
 				}
 				if ((confflags & CONFFLAG_MONITOR) || (user->adminflags & (ADMINFLAG_MUTED | ADMINFLAG_SELFMUTED)))
 					f = ast_read_noaudio(c);
@@ -2358,7 +2358,7 @@
 				} else if (((f->frametype == AST_FRAME_DTMF) && (f->subclass == '*') && (confflags & CONFFLAG_STARMENU)) || ((f->frametype == AST_FRAME_DTMF) && menu_active)) {
 					if (confflags & CONFFLAG_PASS_DTMF)
 						conf_queue_dtmf(conf, user, f);
-					if (ioctl(fd, ZT_SETCONF, &ztc_empty)) {
+					if (ioctl(fd, DAHDI_SETCONF, &dahdic_empty)) {
 						ast_log(LOG_WARNING, "Error setting conference\n");
 						close(fd);
 						ast_frfree(f);
@@ -2513,7 +2513,7 @@
 					if (musiconhold)
 						conf_start_moh(chan, optargs[OPT_ARG_MOH_CLASS]);
 
-					if (ioctl(fd, ZT_SETCONF, &ztc)) {
+					if (ioctl(fd, DAHDI_SETCONF, &dahdic)) {
 						ast_log(LOG_WARNING, "Error setting conference\n");
 						close(fd);
 						ast_frfree(f);
@@ -2625,10 +2625,10 @@
 		close(fd);
 	else {
 		/* Take out of conference */
-		ztc.chan = 0;	
-		ztc.confno = 0;
-		ztc.confmode = 0;
-		if (ioctl(fd, ZT_SETCONF, &ztc)) {
+		dahdic.chan = 0;	
+		dahdic.confno = 0;
+		dahdic.confmode = 0;
+		if (ioctl(fd, DAHDI_SETCONF, &dahdic)) {
 			ast_log(LOG_WARNING, "Error setting conference\n");
 		}
 	}
@@ -2834,13 +2834,13 @@
 		if (confflags && !cnf->chan &&
 		    !ast_test_flag(confflags, CONFFLAG_QUIET) &&
 		    ast_test_flag(confflags, CONFFLAG_INTROUSER)) {
-			ast_log(LOG_WARNING, "No Zap channel available for conference, user introduction disabled (is chan_zap loaded?)\n");
+			ast_log(LOG_WARNING, "No DAHDI channel available for conference, user introduction disabled (is chan_dahdi loaded?)\n");
 			ast_clear_flag(confflags, CONFFLAG_INTROUSER);
 		}
 		
 		if (confflags && !cnf->chan &&
 		    ast_test_flag(confflags, CONFFLAG_RECORDCONF)) {
-			ast_log(LOG_WARNING, "No Zap channel available for conference, conference recording disabled (is chan_zap loaded?)\n");
+			ast_log(LOG_WARNING, "No DAHDI channel available for conference, conference recording disabled (is chan_dahdi loaded?)\n");
 			ast_clear_flag(confflags, CONFFLAG_RECORDCONF);
 		}
 	}
@@ -2932,13 +2932,13 @@
 		if (confflags && !cnf->chan &&
 		    !ast_test_flag(confflags, CONFFLAG_QUIET) &&
 		    ast_test_flag(confflags, CONFFLAG_INTROUSER)) {
-			ast_log(LOG_WARNING, "No Zap channel available for conference, user introduction disabled (is chan_zap loaded?)\n");
+			ast_log(LOG_WARNING, "No DAHDI channel available for conference, user introduction disabled (is chan_dahdi loaded?)\n");
 			ast_clear_flag(confflags, CONFFLAG_INTROUSER);
 		}
 		
 		if (confflags && !cnf->chan &&
 		    ast_test_flag(confflags, CONFFLAG_RECORDCONF)) {
-			ast_log(LOG_WARNING, "No Zap channel available for conference, conference recording disabled (is chan_zap loaded?)\n");
+			ast_log(LOG_WARNING, "No DAHDI channel available for conference, conference recording disabled (is chan_dahdi loaded?)\n");
 			ast_clear_flag(confflags, CONFFLAG_RECORDCONF);
 		}
 	}
@@ -3722,9 +3722,9 @@
 		if ((sscanf(val, "%d", &audio_buffers) != 1)) {
 			ast_log(LOG_WARNING, "audiobuffers setting must be a number, not '%s'\n", val);
 			audio_buffers = DEFAULT_AUDIO_BUFFERS;
-		} else if ((audio_buffers < ZT_DEFAULT_NUM_BUFS) || (audio_buffers > ZT_MAX_NUM_BUFS)) {
+		} else if ((audio_buffers < DAHDI_DEFAULT_NUM_BUFS) || (audio_buffers > DAHDI_MAX_NUM_BUFS)) {
 			ast_log(LOG_WARNING, "audiobuffers setting must be between %d and %d\n",
-				ZT_DEFAULT_NUM_BUFS, ZT_MAX_NUM_BUFS);
+				DAHDI_DEFAULT_NUM_BUFS, DAHDI_MAX_NUM_BUFS);
 			audio_buffers = DEFAULT_AUDIO_BUFFERS;
 		}
 		if (audio_buffers != DEFAULT_AUDIO_BUFFERS)

Modified: team/russell/iax2_media/apps/app_page.c
URL: http://svn.digium.com/view/asterisk/team/russell/iax2_media/apps/app_page.c?view=diff&rev=123330&r1=123329&r2=123330
==============================================================================
--- team/russell/iax2_media/apps/app_page.c (original)
+++ team/russell/iax2_media/apps/app_page.c Tue Jun 17 12:55:07 2008
@@ -26,7 +26,7 @@
  */
 
 /*** MODULEINFO
-	<depend>zaptel</depend>
+	<depend>dahdi</depend>
 	<depend>app_meetme</depend>
  ***/
 

Modified: team/russell/iax2_media/apps/app_parkandannounce.c
URL: http://svn.digium.com/view/asterisk/team/russell/iax2_media/apps/app_parkandannounce.c?view=diff&rev=123330&r1=123329&r2=123330
==============================================================================
--- team/russell/iax2_media/apps/app_parkandannounce.c (original)
+++ team/russell/iax2_media/apps/app_parkandannounce.c Tue Jun 17 12:55:07 2008
@@ -113,7 +113,9 @@
 	/* we are using masq_park here to protect * from touching the channel once we park it.  If the channel comes out of timeout
 	before we are done announcing and the channel is messed with, Kablooeee.  So we use Masq to prevent this.  */
 
-	ast_masq_park_call(chan, NULL, timeout, &lot);
+	res = ast_masq_park_call(chan, NULL, timeout, &lot);
+	if (res == -1)
+		return res;
 
 	ast_verb(3, "Call Parking Called, lot: %d, timeout: %d, context: %s\n", lot, timeout, args.return_context);
 

Modified: team/russell/iax2_media/apps/app_queue.c
URL: http://svn.digium.com/view/asterisk/team/russell/iax2_media/apps/app_queue.c?view=diff&rev=123330&r1=123329&r2=123330
==============================================================================
--- team/russell/iax2_media/apps/app_queue.c (original)
+++ team/russell/iax2_media/apps/app_queue.c Tue Jun 17 12:55:07 2008
@@ -483,7 +483,7 @@
 	int numperiodicannounce;            /*!< The number of periodic announcements configured */
 	int randomperiodicannounce;         /*!< Are periodic announcments randomly chosen */
 	int roundingseconds;                /*!< How many seconds do we round to? */
-	int holdtime;                       /*!< Current avg holdtime, based on recursive boxcar filter */
+	int holdtime;                       /*!< Current avg holdtime, based on an exponential average */
 	int callscompleted;                 /*!< Number of queue calls completed */
 	int callsabandoned;                 /*!< Number of queue calls abandoned */
 	int servicelevel;                   /*!< seconds setting for servicelevel*/
@@ -529,6 +529,7 @@
 static void update_realtime_members(struct call_queue *q);
 static int set_member_paused(const char *queuename, const char *interface, const char *reason, int paused);
 
+static void queue_transfer_fixup(void *data, struct ast_channel *old_chan, struct ast_channel *new_chan); 
 /*! \brief sets the QUEUESTATUS channel variable */
 static void set_queue_result(struct ast_channel *chan, enum queue_result res)
 {
@@ -1861,8 +1862,9 @@
 
 	/* If the hold time is >1 min, if it's enabled, and if it's not
 	   supposed to be only once and we have already said it, say it */
-	if ((avgholdmins+avgholdsecs) > 0 && (qe->parent->announceholdtime) &&
-		(!(qe->parent->announceholdtime == ANNOUNCEHOLDTIME_ONCE) && qe->last_pos)) {
+    if ((avgholdmins+avgholdsecs) > 0 && qe->parent->announceholdtime &&
+        ((qe->parent->announceholdtime == ANNOUNCEHOLDTIME_ONCE && !qe->last_pos) ||
+        !(qe->parent->announceholdtime == ANNOUNCEHOLDTIME_ONCE))) {
 		res = play_file(qe->chan, qe->parent->sound_holdtime);
 		if (res)
 			goto playout;
@@ -1925,7 +1927,7 @@
 {
 	int oldvalue;
 

[... 5467 lines stripped ...]



More information about the svn-commits mailing list