[asterisk-commits] oej: branch oej/videocaps r128116 - in /team/oej/videocaps: ./ apps/ build_to...

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Fri Jul 4 15:21:54 CDT 2008


Author: oej
Date: Fri Jul  4 15:21:53 2008
New Revision: 128116

URL: http://svn.digium.com/view/asterisk?view=rev&rev=128116
Log:
Update to current trunk, resolve conflicts and reset automerge.
Time to test, Christer!

Added:
    team/oej/videocaps/apps/app_dahdibarge.c
      - copied unchanged from r127995, trunk/apps/app_dahdibarge.c
    team/oej/videocaps/apps/app_dahdiras.c
      - copied unchanged from r127995, trunk/apps/app_dahdiras.c
    team/oej/videocaps/apps/app_dahdiscan.c
      - copied unchanged from r127995, trunk/apps/app_dahdiscan.c
    team/oej/videocaps/channels/chan_dahdi.c
      - copied unchanged from r127995, trunk/channels/chan_dahdi.c
    team/oej/videocaps/codecs/codec_dahdi.c
      - copied unchanged from r127995, trunk/codecs/codec_dahdi.c
    team/oej/videocaps/configs/chan_dahdi.conf.sample
      - copied unchanged from r127995, trunk/configs/chan_dahdi.conf.sample
    team/oej/videocaps/doc/lang/
      - copied from r127995, trunk/doc/lang/
    team/oej/videocaps/doc/lang/hebrew.ods
      - copied unchanged from r127995, trunk/doc/lang/hebrew.ods
    team/oej/videocaps/doc/video_console.txt
      - copied unchanged from r127995, trunk/doc/video_console.txt
    team/oej/videocaps/include/asterisk/timing.h
      - copied unchanged from r127995, trunk/include/asterisk/timing.h
    team/oej/videocaps/main/timing.c
      - copied unchanged from r127995, trunk/main/timing.c
    team/oej/videocaps/res/res_curl.c
      - copied unchanged from r127995, trunk/res/res_curl.c
    team/oej/videocaps/res/res_timing_dahdi.c
      - copied unchanged from r127995, trunk/res/res_timing_dahdi.c
    team/oej/videocaps/res/res_timing_pthread.c
      - copied unchanged from r127995, trunk/res/res_timing_pthread.c
Removed:
    team/oej/videocaps/apps/app_zapbarge.c
    team/oej/videocaps/apps/app_zapras.c
    team/oej/videocaps/apps/app_zapscan.c
    team/oej/videocaps/channels/chan_zap.c
    team/oej/videocaps/codecs/codec_zap.c
    team/oej/videocaps/configs/zapata.conf.sample
    team/oej/videocaps/include/asterisk/zapata.h
Modified:
    team/oej/videocaps/   (props changed)
    team/oej/videocaps/CHANGES
    team/oej/videocaps/Makefile
    team/oej/videocaps/README
    team/oej/videocaps/UPGRADE.txt
    team/oej/videocaps/acinclude.m4
    team/oej/videocaps/apps/Makefile
    team/oej/videocaps/apps/app_chanisavail.c
    team/oej/videocaps/apps/app_chanspy.c
    team/oej/videocaps/apps/app_dial.c
    team/oej/videocaps/apps/app_directory.c
    team/oej/videocaps/apps/app_externalivr.c
    team/oej/videocaps/apps/app_flash.c
    team/oej/videocaps/apps/app_forkcdr.c
    team/oej/videocaps/apps/app_getcpeid.c
    team/oej/videocaps/apps/app_meetme.c
    team/oej/videocaps/apps/app_minivm.c
    team/oej/videocaps/apps/app_page.c
    team/oej/videocaps/apps/app_parkandannounce.c
    team/oej/videocaps/apps/app_queue.c
    team/oej/videocaps/apps/app_rpt.c
    team/oej/videocaps/apps/app_stack.c
    team/oej/videocaps/apps/app_talkdetect.c
    team/oej/videocaps/apps/app_voicemail.c
    team/oej/videocaps/build_tools/cflags.xml
    team/oej/videocaps/build_tools/menuselect-deps.in
    team/oej/videocaps/build_tools/strip_nonapi
    team/oej/videocaps/cdr/cdr_csv.c
    team/oej/videocaps/cdr/cdr_pgsql.c
    team/oej/videocaps/cdr/cdr_tds.c
    team/oej/videocaps/channels/chan_agent.c
    team/oej/videocaps/channels/chan_features.c
    team/oej/videocaps/channels/chan_h323.c
    team/oej/videocaps/channels/chan_iax2.c
    team/oej/videocaps/channels/chan_local.c
    team/oej/videocaps/channels/chan_mgcp.c
    team/oej/videocaps/channels/chan_oss.c
    team/oej/videocaps/channels/chan_sip.c
    team/oej/videocaps/channels/chan_skinny.c
    team/oej/videocaps/channels/chan_unistim.c
    team/oej/videocaps/channels/console_board.c
    team/oej/videocaps/channels/console_gui.c
    team/oej/videocaps/channels/console_video.c
    team/oej/videocaps/channels/console_video.h
    team/oej/videocaps/channels/misdn/isdn_lib.c
    team/oej/videocaps/channels/vcodecs.c
    team/oej/videocaps/channels/vgrabbers.c
    team/oej/videocaps/codecs/codec_a_mu.c
    team/oej/videocaps/codecs/codec_adpcm.c
    team/oej/videocaps/codecs/codec_alaw.c
    team/oej/videocaps/codecs/codec_g722.c
    team/oej/videocaps/codecs/codec_g726.c
    team/oej/videocaps/codecs/codec_gsm.c
    team/oej/videocaps/codecs/codec_ilbc.c
    team/oej/videocaps/codecs/codec_lpc10.c
    team/oej/videocaps/codecs/codec_resample.c
    team/oej/videocaps/codecs/codec_speex.c
    team/oej/videocaps/codecs/codec_ulaw.c
    team/oej/videocaps/configs/agents.conf.sample
    team/oej/videocaps/configs/extensions.ael.sample
    team/oej/videocaps/configs/extensions.conf.sample
    team/oej/videocaps/configs/extensions.lua.sample
    team/oej/videocaps/configs/http.conf.sample
    team/oej/videocaps/configs/meetme.conf.sample
    team/oej/videocaps/configs/modules.conf.sample
    team/oej/videocaps/configs/muted.conf.sample
    team/oej/videocaps/configs/queues.conf.sample
    team/oej/videocaps/configs/rpt.conf.sample
    team/oej/videocaps/configs/sip.conf.sample
    team/oej/videocaps/configs/sla.conf.sample
    team/oej/videocaps/configs/smdi.conf.sample
    team/oej/videocaps/configs/users.conf.sample
    team/oej/videocaps/configs/vpb.conf.sample
    team/oej/videocaps/configure
    team/oej/videocaps/configure.ac
    team/oej/videocaps/contrib/init.d/rc.mandrake.asterisk
    team/oej/videocaps/contrib/init.d/rc.mandrake.zaptel
    team/oej/videocaps/contrib/init.d/rc.suse.asterisk
    team/oej/videocaps/contrib/scripts/astcli
    team/oej/videocaps/contrib/scripts/autosupport
    team/oej/videocaps/contrib/scripts/dbsep.cgi
    team/oej/videocaps/contrib/scripts/loadtest.tcl
    team/oej/videocaps/contrib/utils/zones2indications.c
    team/oej/videocaps/doc/CODING-GUIDELINES
    team/oej/videocaps/doc/asterisk-mib.txt
    team/oej/videocaps/doc/asterisk.8
    team/oej/videocaps/doc/asterisk.sgml
    team/oej/videocaps/doc/backtrace.txt
    team/oej/videocaps/doc/digium-mib.txt
    team/oej/videocaps/doc/janitor-projects.txt
    team/oej/videocaps/doc/manager_1_1.txt
    team/oej/videocaps/doc/osp.txt
    team/oej/videocaps/doc/siptls.txt
    team/oej/videocaps/doc/sms.txt
    team/oej/videocaps/doc/ss7.txt
    team/oej/videocaps/doc/tex/ael.tex
    team/oej/videocaps/doc/tex/app-sms.tex
    team/oej/videocaps/doc/tex/backtrace.tex
    team/oej/videocaps/doc/tex/channelvariables.tex
    team/oej/videocaps/doc/tex/configuration.tex
    team/oej/videocaps/doc/tex/enum.tex
    team/oej/videocaps/doc/tex/freetds.tex
    team/oej/videocaps/doc/tex/hardware.tex
    team/oej/videocaps/doc/tex/localchannel.tex
    team/oej/videocaps/doc/tex/manager.tex
    team/oej/videocaps/doc/tex/privacy.tex
    team/oej/videocaps/doc/tex/queuelog.tex
    team/oej/videocaps/doc/tex/queues-with-callback-members.tex
    team/oej/videocaps/doc/tex/security.tex
    team/oej/videocaps/doc/tex/sla.tex
    team/oej/videocaps/doc/video.txt
    team/oej/videocaps/funcs/func_cdr.c
    team/oej/videocaps/funcs/func_channel.c
    team/oej/videocaps/funcs/func_curl.c
    team/oej/videocaps/funcs/func_devstate.c
    team/oej/videocaps/funcs/func_realtime.c
    team/oej/videocaps/images/kpad2.jpg
    team/oej/videocaps/include/asterisk/_private.h
    team/oej/videocaps/include/asterisk/app.h
    team/oej/videocaps/include/asterisk/astobj2.h
    team/oej/videocaps/include/asterisk/autoconfig.h.in
    team/oej/videocaps/include/asterisk/callerid.h
    team/oej/videocaps/include/asterisk/cdr.h
    team/oej/videocaps/include/asterisk/channel.h
    team/oej/videocaps/include/asterisk/compiler.h
    team/oej/videocaps/include/asterisk/config.h
    team/oej/videocaps/include/asterisk/devicestate.h
    team/oej/videocaps/include/asterisk/dnsmgr.h
    team/oej/videocaps/include/asterisk/doxyref.h
    team/oej/videocaps/include/asterisk/dsp.h
    team/oej/videocaps/include/asterisk/http.h
    team/oej/videocaps/include/asterisk/jabber.h
    team/oej/videocaps/include/asterisk/lock.h
    team/oej/videocaps/include/asterisk/logger.h
    team/oej/videocaps/include/asterisk/network.h
    team/oej/videocaps/include/asterisk/options.h
    team/oej/videocaps/include/asterisk/pbx.h
    team/oej/videocaps/include/asterisk/sched.h
    team/oej/videocaps/include/asterisk/slinfactory.h
    team/oej/videocaps/include/asterisk/strings.h
    team/oej/videocaps/include/asterisk/tcptls.h
    team/oej/videocaps/include/asterisk/threadstorage.h
    team/oej/videocaps/include/asterisk/time.h
    team/oej/videocaps/include/asterisk/translate.h
    team/oej/videocaps/main/Makefile
    team/oej/videocaps/main/acl.c
    team/oej/videocaps/main/app.c
    team/oej/videocaps/main/ast_expr2.fl
    team/oej/videocaps/main/ast_expr2f.c
    team/oej/videocaps/main/asterisk.c
    team/oej/videocaps/main/astobj2.c
    team/oej/videocaps/main/autoservice.c
    team/oej/videocaps/main/callerid.c
    team/oej/videocaps/main/cdr.c
    team/oej/videocaps/main/channel.c
    team/oej/videocaps/main/dial.c
    team/oej/videocaps/main/editline/np/vis.c
    team/oej/videocaps/main/features.c
    team/oej/videocaps/main/file.c
    team/oej/videocaps/main/http.c
    team/oej/videocaps/main/libresample/include/libresample.h
    team/oej/videocaps/main/loader.c
    team/oej/videocaps/main/logger.c
    team/oej/videocaps/main/manager.c
    team/oej/videocaps/main/netsock.c
    team/oej/videocaps/main/pbx.c
    team/oej/videocaps/main/rtp.c
    team/oej/videocaps/main/say.c
    team/oej/videocaps/main/taskprocessor.c
    team/oej/videocaps/main/tcptls.c
    team/oej/videocaps/main/translate.c
    team/oej/videocaps/main/utils.c
    team/oej/videocaps/makeopts.in
    team/oej/videocaps/pbx/Makefile
    team/oej/videocaps/pbx/pbx_config.c
    team/oej/videocaps/pbx/pbx_gtkconsole.c
    team/oej/videocaps/pbx/pbx_lua.c
    team/oej/videocaps/pbx/pbx_realtime.c
    team/oej/videocaps/pbx/pbx_spool.c
    team/oej/videocaps/res/Makefile
    team/oej/videocaps/res/ais/ais.h
    team/oej/videocaps/res/res_agi.c
    team/oej/videocaps/res/res_ais.c
    team/oej/videocaps/res/res_config_curl.c
    team/oej/videocaps/res/res_config_ldap.c
    team/oej/videocaps/res/res_config_pgsql.c
    team/oej/videocaps/res/res_jabber.c
    team/oej/videocaps/res/res_musiconhold.c
    team/oej/videocaps/res/res_realtime.c
    team/oej/videocaps/utils/Makefile
    team/oej/videocaps/utils/extconf.c

Propchange: team/oej/videocaps/
------------------------------------------------------------------------------
    automerge = http://www.codename-pineapple.org/

Propchange: team/oej/videocaps/
------------------------------------------------------------------------------
Binary property 'branch-1.4-blocked' - no diff available.

Propchange: team/oej/videocaps/
------------------------------------------------------------------------------
Binary property 'branch-1.4-merged' - no diff available.

Propchange: team/oej/videocaps/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Fri Jul  4 15:21:53 2008
@@ -1,1 +1,1 @@
-/trunk:1-122020
+/trunk:1-127995

Modified: team/oej/videocaps/CHANGES
URL: http://svn.digium.com/view/asterisk/team/oej/videocaps/CHANGES?view=diff&rev=128116&r1=128115&r2=128116
==============================================================================
--- team/oej/videocaps/CHANGES (original)
+++ team/oej/videocaps/CHANGES Fri Jul  4 15:21:53 2008
@@ -93,6 +93,15 @@
  * PrivacyManager now takes an option where you can specify a context where the 
    given number will be matched. This way you have more control over who is allowed
    and it stops the people who blindly enter 10 digits.
+ * ForkCDR has new options: 'a' updates the answer time on the new CDR; 'A' locks
+   answer times, disposition, on orig CDR against updates; 'D' Copies the disposition
+   from the orig CDR to the new CDR after reset; 'e' sets the 'end' time on the
+   original CDR; 'R' prevents the new CDR from being reset; 's(var=val)' adds/changes
+   the 'var' variable on the original CDR; 'T' forces ast_cdr_end(), ast_cdr_answer(),
+   obey the LOCKED flag on cdr's in the chain, and also the ast_cdr_setvar() func.
+ * The Dial() application no longer copies the language used by the caller to the callee's
+   channel. If you desire for the caller's channel's language to be used for file playback
+   to the callee, then the file specified may be prepended with "${CHANNEL(language)}/" .
 
 SIP Changes
 -----------
@@ -115,6 +124,9 @@
    lost packets.
  * Added t38pt_usertpsource option. See sip.conf.sample for details.
  * Added SIPnotify AMI command, for sending arbitrary SIP notify commands.
+ * 'sip show peers' and 'sip show users' display their entries sorted in
+    alphabetical order, as opposed to the order they were in, in the config 
+    file or database. 
 
 IAX Changes
 -----------
@@ -146,6 +158,14 @@
   * res_odbc no longer has a limit of 1023 total possible unshared connections,
     as some people were running into this limit.  This limit has been increased
     to 4.2 billion.
+
+Queue changes
+-------------
+  * The TRANSFER queue log entry now includes the the caller's original
+    position in the transferred-from queue.
+  * 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
 
 ------------------------------------------------------------------------------
 --- Functionality changes from Asterisk 1.4.X to Asterisk 1.6.0  -------------
@@ -361,6 +381,13 @@
   * A 'b' option has been added which causes chan_local to return the actual channel
      that is behind it when queried. This is useful for transfer scenarios as the
      actual channel will be transferred, not the Local channel.
+
+Agent channel changes
+----------------------
+  * The ackcall and endcall options are now supplemented with options acceptdtmf
+    and enddtmf. These allow for the DTMF keypress to be configurable. The options
+	default to their old hard-coded values ('#' and '*' respectively) so this should
+	not break any existing agent installations.
 
 Zaptel channel driver (chan_zap) Changes
 ----------------------------------------
@@ -776,3 +803,5 @@
   * If compiled with DEBUG_THREADS enabled and if you have glibc, then issuing
      the "core show locks" CLI command will give lock information output as well
      as a backtrace of the stack which led to the lock calls.
+  * users.conf now sports an optional alternateexts property, which permits
+    allocation of additional extensions which will reach the specified user.

Modified: team/oej/videocaps/Makefile
URL: http://svn.digium.com/view/asterisk/team/oej/videocaps/Makefile?view=diff&rev=128116&r1=128115&r2=128116
==============================================================================
--- team/oej/videocaps/Makefile (original)
+++ team/oej/videocaps/Makefile Fri Jul  4 15:21:53 2008
@@ -73,12 +73,12 @@
 export NOISY_BUILD		# Used in Makefile.rules
 export MENUSELECT_CFLAGS	# Options selected in menuselect.
 export AST_DEVMODE		# Set to "yes" for additional compiler
-				# and runtime checks
+                                # and runtime checks
 
 export SOLINK			# linker flags for shared objects
 export STATIC_BUILD		# Additional cflags, set to -static
-				# for static builds. Probably
-				# should go directly to ASTLDFLAGS
+                                # for static builds. Probably
+                                # should go directly to ASTLDFLAGS
 
 #--- paths to various commands
 export CC
@@ -304,7 +304,7 @@
 endif
 
 ifeq ($(OSARCH),SunOS)
-  SOLINK=-shared -fpic -L/usr/local/ssl/lib
+  SOLINK=-shared -fpic -L/usr/local/ssl/lib -lrt
 endif
 
 # comment to print directories during submakes
@@ -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]" ; \
@@ -825,8 +826,18 @@
 
 nmenuconfig: nmenuselect
 
-menuselect: menuselect/menuselect menuselect-tree
-	- at menuselect/menuselect menuselect.makeopts $(GLOBAL_MAKEOPTS) $(USER_MAKEOPTS) && (echo "menuselect changes saved!"; rm -f channels/h323/Makefile.ast main/asterisk) || echo "menuselect changes NOT saved!"
+menuselect: menuselect/cmenuselect menuselect/nmenuselect menuselect/gmenuselect
+	@if [ -x menuselect/nmenuselect ]; then \
+		$(MAKE) nmenuselect; \
+	elif [ -x menuselect/cmenuselect ]; then \
+		$(MAKE) cmenuselect; \
+	elif [ -x menuselect/gmenuselect ]; then \
+		$(MAKE) gmenuselect; \
+	else \
+		echo "No menuselect user interface found. Install ncurses,"; \
+		echo "newt or GTK libraries to build one and re-rerun"; \
+		echo "'make menuselect'."; \
+	fi
 
 cmenuselect: menuselect/cmenuselect menuselect-tree
 	- at menuselect/cmenuselect menuselect.makeopts $(GLOBAL_MAKEOPTS) $(USER_MAKEOPTS) && (echo "menuselect changes saved!"; rm -f channels/h323/Makefile.ast main/asterisk) || echo "menuselect changes NOT saved!"
@@ -841,7 +852,7 @@
 MAKE_MENUSELECT=CC="$(HOST_CC)" CXX="$(CXX)" LD="" AR="" RANLIB="" CFLAGS="" $(MAKE) -C menuselect CONFIGURE_SILENT="--silent"
 
 menuselect/menuselect: menuselect/makeopts
-	$(MAKE_MENUSELECT)
+	$(MAKE_MENUSELECT) menuselect
 
 menuselect/cmenuselect: menuselect/makeopts
 	$(MAKE_MENUSELECT) cmenuselect
@@ -861,8 +872,8 @@
 	@echo >> $@
 	@echo "<menu name=\"Asterisk Module and Build Option Selection\">" >> $@
 	@for dir in $(sort $(filter-out main,$(MOD_SUBDIRS))); do $(SUBMAKE) -C $${dir} SUBDIR=$${dir} moduleinfo >> $@; done
+	@cat build_tools/cflags.xml >> $@
 	@for dir in $(sort $(filter-out main,$(MOD_SUBDIRS))); do $(SUBMAKE) -C $${dir} SUBDIR=$${dir} makeopts >> $@; done
-	@cat build_tools/cflags.xml >> $@
 	@if [ "${AST_DEVMODE}" = "yes" ]; then \
 		cat build_tools/cflags-devmode.xml >> $@; \
 	fi

Modified: team/oej/videocaps/README
URL: http://svn.digium.com/view/asterisk/team/oej/videocaps/README?view=diff&rev=128116&r1=128115&r2=128116
==============================================================================
--- team/oej/videocaps/README (original)
+++ team/oej/videocaps/README Fri Jul  4 15:21:53 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/oej/videocaps/UPGRADE.txt
URL: http://svn.digium.com/view/asterisk/team/oej/videocaps/UPGRADE.txt?view=diff&rev=128116&r1=128115&r2=128116
==============================================================================
--- team/oej/videocaps/UPGRADE.txt (original)
+++ team/oej/videocaps/UPGRADE.txt Fri Jul  4 15:21:53 2008
@@ -155,6 +155,9 @@
   possible values the systemname prefix could be.  In the past, if the
   systemname was too long, the uniqueid would have been truncated.
 
+* The cdr_tds module now supports all versions of FreeTDS that contain
+  the db-lib frontend.
+
 Formats:
 
 * format_wav: The GAIN preprocessor definition and source code that used it
@@ -181,6 +184,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
@@ -217,12 +223,18 @@
   output of the SIPpeers command.
 
 * cdr_manager now reports at the "cdr" level, not at "call"  You may need to
-   change your manager.conf to add the level to existing AMI users, if they
-   want to see the CDR events generated.
+  change your manager.conf to add the level to existing AMI users, if they
+  want to see the CDR events generated.
 
 * The Originate command now requires the Originate write permission.  For
-   Originate with the Application parameter, you need the additional System
-   privilege if you want to do anything that calls out to a subshell.
+  Originate with the Application parameter, you need the additional System
+  privilege if you want to do anything that calls out to a subshell.
+
+Queues:
+
+* New queue log events ADDMEMBER and REMOVEMEMBER have been added.  Also, a
+  new value has been added to the TRANSFER event that indicates the caller's
+  original position in the queue they are being transfered from.
 
 iLBC Codec:
 

Modified: team/oej/videocaps/acinclude.m4
URL: http://svn.digium.com/view/asterisk/team/oej/videocaps/acinclude.m4?view=diff&rev=128116&r1=128115&r2=128116
==============================================================================
--- team/oej/videocaps/acinclude.m4 (original)
+++ team/oej/videocaps/acinclude.m4 Fri Jul  4 15:21:53 2008
@@ -192,7 +192,7 @@
          $1_HEADER_FOUND="1"
       else				# check for the header
          saved_cppflags="${CPPFLAGS}"
-         CPPFLAGS="${CPPFLAGS} ${$1_INCLUDE} $6"
+         CPPFLAGS="${CPPFLAGS} ${$1_INCLUDE}"
 	 AC_CHECK_HEADER([$4], [$1_HEADER_FOUND=1], [$1_HEADER_FOUND=0])
          CPPFLAGS="${saved_cppflags}"
       fi

Modified: team/oej/videocaps/apps/Makefile
URL: http://svn.digium.com/view/asterisk/team/oej/videocaps/apps/Makefile?view=diff&rev=128116&r1=128115&r2=128116
==============================================================================
--- team/oej/videocaps/apps/Makefile (original)
+++ team/oej/videocaps/apps/Makefile Fri Jul  4 15:21:53 2008
@@ -25,11 +25,6 @@
   MENUSELECT_DEPENDS_app_directory+=$(MENUSELECT_DEPENDS_IMAP_STORAGE)
 endif
 
-ifeq (SunOS,$(shell uname))
-  MENUSELECT_DEPENDS_app_chanspy+=RT
-  RT_LIB=-lrt
-endif
-
 all: _all
 
 include $(ASTTOPDIR)/Makefile.moddir_rules

Modified: team/oej/videocaps/apps/app_chanisavail.c
URL: http://svn.digium.com/view/asterisk/team/oej/videocaps/apps/app_chanisavail.c?view=diff&rev=128116&r1=128115&r2=128116
==============================================================================
--- team/oej/videocaps/apps/app_chanisavail.c (original)
+++ team/oej/videocaps/apps/app_chanisavail.c Fri Jul  4 15:21:53 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/oej/videocaps/apps/app_chanspy.c
URL: http://svn.digium.com/view/asterisk/team/oej/videocaps/apps/app_chanspy.c?view=diff&rev=128116&r1=128115&r2=128116
==============================================================================
--- team/oej/videocaps/apps/app_chanspy.c (original)
+++ team/oej/videocaps/apps/app_chanspy.c Fri Jul  4 15:21:53 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
@@ -321,7 +322,7 @@
 	char *name;
 	struct ast_frame *f;
 	struct ast_silence_generator *silgen = NULL;
-	struct ast_channel *spyee = NULL;
+	struct ast_channel *spyee = NULL, *spyee_bridge = NULL;
 	const char *spyer_name;
 
 	ast_channel_lock(chan);
@@ -358,17 +359,24 @@
 		return 0;
 	}
 
+ 	ast_audiohook_init(&csth.whisper_audiohook, AST_AUDIOHOOK_TYPE_WHISPER, "ChanSpy");
+	ast_audiohook_init(&csth.bridge_whisper_audiohook, AST_AUDIOHOOK_TYPE_WHISPER, "Chanspy");
+  	if (start_spying(spyee, spyer_name, &csth.whisper_audiohook)) {
+		ast_log(LOG_WARNING, "Unable to attach whisper audiohook to spyee %s. Whisper mode disabled!\n", spyee->name);
+	}
+	if ((spyee_bridge = ast_bridged_channel(spyee))) {
+		ast_channel_lock(spyee_bridge);
+		if (start_spying(spyee_bridge, spyer_name, &csth.bridge_whisper_audiohook)) {
+			ast_log(LOG_WARNING, "Unable to attach barge audiohook on spyee %s. Barge mode disabled!\n", spyee->name);
+		}
+		ast_channel_unlock(spyee_bridge);
+	}
+	ast_channel_unlock(spyee);
+	spyee = NULL;
+
 	ast_channel_lock(chan);
 	ast_set_flag(chan, AST_FLAG_END_DTMF_ONLY);
 	ast_channel_unlock(chan);
-
- 	ast_audiohook_init(&csth.whisper_audiohook, AST_AUDIOHOOK_TYPE_WHISPER, "ChanSpy");
-	ast_audiohook_init(&csth.bridge_whisper_audiohook, AST_AUDIOHOOK_TYPE_WHISPER, "Chanspy");
-  	start_spying(spyee, spyer_name, &csth.whisper_audiohook); /* Unlocks spyee */
-	start_spying(ast_bridged_channel(spyee), spyer_name, &csth.bridge_whisper_audiohook);
-
-	ast_channel_unlock(spyee);
-	spyee = NULL;
 
 	csth.volfactor = *volfactor;
 
@@ -587,6 +595,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 +608,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/oej/videocaps/apps/app_dial.c
URL: http://svn.digium.com/view/asterisk/team/oej/videocaps/apps/app_dial.c?view=diff&rev=128116&r1=128115&r2=128116
==============================================================================
--- team/oej/videocaps/apps/app_dial.c (original)
+++ team/oej/videocaps/apps/app_dial.c Fri Jul  4 15:21:53 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"
@@ -485,8 +485,11 @@
 		*stuff++ = '\0';
 		tech = tmpchan;
 	} else {
-		const char *forward_context = pbx_builtin_getvar_helper(c, "FORWARD_CONTEXT");
+		const char *forward_context;
+		ast_channel_lock(c);
+		forward_context = pbx_builtin_getvar_helper(c, "FORWARD_CONTEXT");
 		snprintf(tmpchan, sizeof(tmpchan), "%s@%s", c->call_forward, forward_context ? forward_context : c->context);
+		ast_channel_unlock(c);
 		stuff = tmpchan;
 		tech = "Local";
 	}
@@ -637,7 +640,7 @@
 						OPT_CALLEE_PARK | OPT_CALLER_PARK |
 						OPT_CALLEE_MIXMONITOR | OPT_CALLER_MIXMONITOR |
 						DIAL_NOFORWARDHTML);
-					ast_copy_string(c->dialcontext, "", sizeof(c->dialcontext));
+					ast_string_field_set(c, dialcontext, "");
 					ast_copy_string(c->exten, "", sizeof(c->exten));
 				}
 				continue;
@@ -675,7 +678,7 @@
 							OPT_CALLEE_PARK | OPT_CALLER_PARK |
 							OPT_CALLEE_MIXMONITOR | OPT_CALLER_MIXMONITOR |
 							DIAL_NOFORWARDHTML);
-						ast_copy_string(c->dialcontext, "", sizeof(c->dialcontext));
+						ast_string_field_set(c, dialcontext, "");
 						ast_copy_string(c->exten, "", sizeof(c->exten));
 						if (CAN_EARLY_BRIDGE(peerflags))
 							/* Setup early bridge if appropriate */
@@ -806,7 +809,9 @@
 			/* now f is guaranteed non-NULL */
 			if (f->frametype == AST_FRAME_DTMF) {
 				if (ast_test_flag64(peerflags, OPT_DTMF_EXIT)) {
-					const char *context = pbx_builtin_getvar_helper(in, "EXITCONTEXT");
+					const char *context;
+					ast_channel_lock(in);
+					context = pbx_builtin_getvar_helper(in, "EXITCONTEXT");
 					if (onedigit_goto(in, context, (char) f->subclass, 1)) {
 						ast_verb(3, "User hit %c to disconnect call.\n", f->subclass);
 						*to = 0;
@@ -814,8 +819,10 @@
 						*result = f->subclass;
 						strcpy(pa->status, "CANCEL");
 						ast_frfree(f);
+						ast_channel_unlock(in);
 						return NULL;
 					}
+					ast_channel_unlock(in);
 				}
 
 				if (ast_test_flag64(peerflags, OPT_CALLER_HANGUP) &&
@@ -930,8 +937,11 @@
 				config->play_warning = config->warning_freq = 0;
 		}
 	}
+	
+	ast_channel_lock(chan);
 
 	var = pbx_builtin_getvar_helper(chan, "LIMIT_PLAYAUDIO_CALLER");
+
 	play_to_caller = var ? ast_true(var) : 1;
 
 	var = pbx_builtin_getvar_helper(chan, "LIMIT_PLAYAUDIO_CALLEE");
@@ -941,17 +951,21 @@
 		play_to_caller = 1;
 
 	var = pbx_builtin_getvar_helper(chan, "LIMIT_WARNING_FILE");
-	config->warning_sound = S_OR(var, "timeleft");
+	config->warning_sound = !ast_strlen_zero(var) ? ast_strdupa(var) : "timeleft";
 
 	/* The code looking at config wants a NULL, not just "", to decide
 	 * that the message should not be played, so we replace "" with NULL.
 	 * Note, pbx_builtin_getvar_helper _can_ return NULL if the variable is
 	 * not found.
 	 */
+
 	var = pbx_builtin_getvar_helper(chan, "LIMIT_TIMEOUT_FILE");
-	config->end_sound = S_OR(var, NULL);
+	config->end_sound = !ast_strlen_zero(var) ? ast_strdupa(var) : NULL;
+
 	var = pbx_builtin_getvar_helper(chan, "LIMIT_CONNECT_FILE");
-	config->start_sound = S_OR(var, NULL);
+	config->start_sound = !ast_strlen_zero(var) ? ast_strdupa(var) : NULL;
+
+	ast_channel_unlock(chan);
 
 	/* undo effect of S(x) in case they are both used */
 	*calldurationlimit = 0;
@@ -1332,13 +1346,15 @@
 		*continue_exec = 0;
 
 	/* If a channel group has been specified, get it for use when we create peer channels */
+
+	ast_channel_lock(chan);
 	if ((outbound_group = pbx_builtin_getvar_helper(chan, "OUTBOUND_GROUP_ONCE"))) {
+		outbound_group = ast_strdupa(outbound_group);	
+		pbx_builtin_setvar_helper(chan, "OUTBOUND_GROUP_ONCE", NULL);
+	} else if ((outbound_group = pbx_builtin_getvar_helper(chan, "OUTBOUND_GROUP"))) {
 		outbound_group = ast_strdupa(outbound_group);
-		pbx_builtin_setvar_helper(chan, "OUTBOUND_GROUP_ONCE", NULL);
-	} else {
-		outbound_group = pbx_builtin_getvar_helper(chan, "OUTBOUND_GROUP");
-	}
-
+	}
+	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 */
@@ -1488,8 +1504,6 @@
 		S_REPLACE(tc->cid.cid_ani, ast_strdup(chan->cid.cid_ani));
 		S_REPLACE(tc->cid.cid_rdnis, ast_strdup(chan->cid.cid_rdnis));
 		
-		/* Copy language from incoming to outgoing */
-		ast_string_field_set(tc, language, chan->language);
 		ast_string_field_set(tc, accountcode, chan->accountcode);
 		tc->cdrflags = chan->cdrflags;
 		if (ast_strlen_zero(tc->musicclass))
@@ -1507,10 +1521,7 @@
 			ast_app_group_set_channel(tc, outbound_group);
 
 		/* Inherit context and extension */
-		if (!ast_strlen_zero(chan->macrocontext))
-			ast_copy_string(tc->dialcontext, chan->macrocontext, sizeof(tc->dialcontext));
-		else
-			ast_copy_string(tc->dialcontext, chan->context, sizeof(tc->dialcontext));
+		ast_string_field_set(tc, dialcontext, ast_strlen_zero(chan->macrocontext) ? chan->context : chan->macrocontext);
 		if (!ast_strlen_zero(chan->macroexten))
 			ast_copy_string(tc->exten, chan->macroexten, sizeof(tc->exten));
 		else
@@ -1652,11 +1663,14 @@
 			ast_cdr_setdestchan(chan->cdr, peer->name);
 		if (peer->name)
 			pbx_builtin_setvar_helper(chan, "DIALEDPEERNAME", peer->name);
-
-		number = pbx_builtin_getvar_helper(peer, "DIALEDPEERNUMBER");
+		
+		ast_channel_lock(peer);
+		number = pbx_builtin_getvar_helper(peer, "DIALEDPEERNUMBER"); 
 		if (!number)
 			number = numsubst;
 		pbx_builtin_setvar_helper(chan, "DIALEDPEERNUMBER", number);
+		ast_channel_unlock(peer);
+
 		if (!ast_strlen_zero(args.url) && ast_channel_supports_html(peer) ) {
 			ast_debug(1, "app_dial: sendurl=%s.\n", args.url);
 			ast_channel_sendurl( peer, args.url );
@@ -1729,6 +1743,8 @@
 				ast_log(LOG_ERROR, "Could not stop autoservice on calling channel\n");
 				res = -1;
 			}
+
+			ast_channel_lock(peer);
 
 			if (!res && (macro_result = pbx_builtin_getvar_helper(peer, "MACRO_RESULT"))) {
 				char *macro_transfer_dest;
@@ -1761,6 +1777,8 @@
 					}
 				}
 			}
+
+			ast_channel_unlock(peer);
 		}
 
 		if (ast_test_flag64(&opts, OPT_CALLEE_GOSUB) && !ast_strlen_zero(opt_args[OPT_ARG_CALLEE_GOSUB])) {
@@ -1776,7 +1794,7 @@
 
 			theapp = pbx_findapp("Gosub");
 
-			if (theapp && !res) { /* XXX why check res here ? */
+			if (theapp && !res) {
 				replace_macro_delimiter(opt_args[OPT_ARG_CALLEE_GOSUB]);
 
 				/* Set where we came from */
@@ -1803,7 +1821,7 @@
 					ast_log(LOG_ERROR, "Could not Allocate string for Gosub arguments -- Gosub Call Aborted!\n");
 
 				res = 0;
-			} else {
+			} else if (!res) {
 				ast_log(LOG_ERROR, "Could not find application Gosub\n");
 				res = -1;
 			}
@@ -1812,6 +1830,8 @@
 				ast_log(LOG_ERROR, "Could not stop autoservice on calling channel\n");
 				res = -1;
 			}
+			
+			ast_channel_lock(peer);
 
 			if (!res && (gosub_result = pbx_builtin_getvar_helper(peer, "GOSUB_RESULT"))) {
 				char *gosub_transfer_dest;
@@ -1844,6 +1864,8 @@
 					}
 				}
 			}
+
+			ast_channel_unlock(peer);	
 		}
 
 		if (!res) {
@@ -1903,9 +1925,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;
@@ -2031,7 +2053,10 @@
 	if (!loops)
 		loops = -1; /* run forever */
 
+	ast_channel_lock(chan);
 	context = pbx_builtin_getvar_helper(chan, "EXITCONTEXT");
+	context = !ast_strlen_zero(context) ? ast_strdupa(context) : NULL;
+	ast_channel_unlock(chan);
 
 	res = 0;
 	while (loops) {
@@ -2106,7 +2131,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/oej/videocaps/apps/app_directory.c
URL: http://svn.digium.com/view/asterisk/team/oej/videocaps/apps/app_directory.c?view=diff&rev=128116&r1=128115&r2=128116
==============================================================================
--- team/oej/videocaps/apps/app_directory.c (original)
+++ team/oej/videocaps/apps/app_directory.c Fri Jul  4 15:21:53 2008
@@ -366,7 +366,7 @@
 
 	/* Get realtime entries, categorized by their mailbox number
 	   and present in the requested context */
-	rtdata = ast_load_realtime_multientry("voicemail", "mailbox LIKE", "%", "context", context, NULL);
+	rtdata = ast_load_realtime_multientry("voicemail", "mailbox LIKE", "%", "context", context, SENTINEL);
 
 	/* if there are no results, just return the entries from the config file */
 	if (!rtdata)

Modified: team/oej/videocaps/apps/app_externalivr.c
URL: http://svn.digium.com/view/asterisk/team/oej/videocaps/apps/app_externalivr.c?view=diff&rev=128116&r1=128115&r2=128116
==============================================================================
--- team/oej/videocaps/apps/app_externalivr.c (original)
+++ team/oej/videocaps/apps/app_externalivr.c Fri Jul  4 15:21:53 2008
@@ -118,7 +118,7 @@
 
 	ast_str_append(&tmp, 0, "%c,%10d", event, (int)time(NULL));
 	if (data) {
-		ast_str_append(&tmp, 0, "%s", data);
+		ast_str_append(&tmp, 0, ",%s", data);
 	}
 
 	fprintf(handle, "%s\n", tmp->str);
@@ -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 */
@@ -515,8 +515,7 @@
 	if (child_stderr[1])
 		close(child_stderr[1]);
 	if (ser) {
-		fclose(ser->f);
-		ast_tcptls_session_instance_destroy(ser);
+		ao2_ref(ser, -1);
 	}
 	while ((entry = AST_LIST_REMOVE_HEAD(&u->playlist, list)))
 		ast_free(entry);

Modified: team/oej/videocaps/apps/app_flash.c
URL: http://svn.digium.com/view/asterisk/team/oej/videocaps/apps/app_flash.c?view=diff&rev=128116&r1=128115&r2=128116
==============================================================================
--- team/oej/videocaps/apps/app_flash.c (original)
+++ team/oej/videocaps/apps/app_flash.c Fri Jul  4 15:21:53 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 <dahdi/user.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/oej/videocaps/apps/app_forkcdr.c

[... 18733 lines stripped ...]



More information about the asterisk-commits mailing list