[asterisk-commits] may: branch may/chan_ooh323_evo r315047 - in /team/may/chan_ooh323_evo: ./ ad...

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Sat Apr 23 12:35:36 CDT 2011


Author: may
Date: Sat Apr 23 12:34:45 2011
New Revision: 315047

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=315047
Log:
merged up to current trunk

Added:
    team/may/chan_ooh323_evo/apps/confbridge/
      - copied from r315000, trunk/apps/confbridge/
    team/may/chan_ooh323_evo/apps/confbridge/conf_config_parser.c
      - copied unchanged from r315000, trunk/apps/confbridge/conf_config_parser.c
    team/may/chan_ooh323_evo/apps/confbridge/include/
      - copied from r315000, trunk/apps/confbridge/include/
    team/may/chan_ooh323_evo/apps/confbridge/include/confbridge.h
      - copied unchanged from r315000, trunk/apps/confbridge/include/confbridge.h
    team/may/chan_ooh323_evo/codecs/speex/
      - copied from r309996, trunk/codecs/speex/
    team/may/chan_ooh323_evo/codecs/speex/arch.h
      - copied unchanged from r309996, trunk/codecs/speex/arch.h
    team/may/chan_ooh323_evo/codecs/speex/fixed_generic.h
      - copied unchanged from r309996, trunk/codecs/speex/fixed_generic.h
    team/may/chan_ooh323_evo/codecs/speex/resample.c
      - copied unchanged from r309996, trunk/codecs/speex/resample.c
    team/may/chan_ooh323_evo/codecs/speex/resample_sse.h
      - copied unchanged from r309996, trunk/codecs/speex/resample_sse.h
    team/may/chan_ooh323_evo/codecs/speex/speex_resampler.h
      - copied unchanged from r309996, trunk/codecs/speex/speex_resampler.h
    team/may/chan_ooh323_evo/codecs/speex/stack_alloc.h
      - copied unchanged from r309996, trunk/codecs/speex/stack_alloc.h
    team/may/chan_ooh323_evo/configs/confbridge.conf.sample
      - copied unchanged from r315000, trunk/configs/confbridge.conf.sample
    team/may/chan_ooh323_evo/formats/format_attr_silk.c
      - copied unchanged from r309996, trunk/formats/format_attr_silk.c
    team/may/chan_ooh323_evo/funcs/func_jitterbuffer.c
      - copied unchanged from r315000, trunk/funcs/func_jitterbuffer.c
    team/may/chan_ooh323_evo/include/asterisk/format_cap.h
      - copied, changed from r306010, trunk/include/asterisk/format_cap.h
    team/may/chan_ooh323_evo/include/asterisk/format_pref.h
      - copied unchanged from r306010, trunk/include/asterisk/format_pref.h
    team/may/chan_ooh323_evo/include/asterisk/silk.h
      - copied unchanged from r309996, trunk/include/asterisk/silk.h
    team/may/chan_ooh323_evo/main/format.c
      - copied, changed from r306010, trunk/main/format.c
    team/may/chan_ooh323_evo/main/format_cap.c
      - copied, changed from r306010, trunk/main/format_cap.c
    team/may/chan_ooh323_evo/main/format_pref.c
      - copied, changed from r306010, trunk/main/format_pref.c
Modified:
    team/may/chan_ooh323_evo/   (props changed)
    team/may/chan_ooh323_evo/CHANGES
    team/may/chan_ooh323_evo/CREDITS
    team/may/chan_ooh323_evo/Makefile
    team/may/chan_ooh323_evo/UPGRADE-1.8.txt
    team/may/chan_ooh323_evo/UPGRADE.txt
    team/may/chan_ooh323_evo/addons/cdr_mysql.c
    team/may/chan_ooh323_evo/addons/chan_ooh323.c
    team/may/chan_ooh323_evo/addons/ooh323c/src/ooCalls.h
    team/may/chan_ooh323_evo/addons/ooh323c/src/ooCapability.c
    team/may/chan_ooh323_evo/addons/ooh323c/src/ooGkClient.c
    team/may/chan_ooh323_evo/addons/ooh323c/src/ooGkClient.h
    team/may/chan_ooh323_evo/addons/ooh323c/src/ooLogChan.c
    team/may/chan_ooh323_evo/addons/ooh323c/src/ooLogChan.h
    team/may/chan_ooh323_evo/addons/ooh323c/src/ooSocket.c
    team/may/chan_ooh323_evo/addons/ooh323c/src/ooSocket.h
    team/may/chan_ooh323_evo/addons/ooh323c/src/oochannels.c
    team/may/chan_ooh323_evo/addons/ooh323c/src/ooh245.c
    team/may/chan_ooh323_evo/addons/ooh323c/src/ooh323.c
    team/may/chan_ooh323_evo/addons/ooh323c/src/ooh323ep.h
    team/may/chan_ooh323_evo/addons/ooh323c/src/ooports.c
    team/may/chan_ooh323_evo/addons/ooh323c/src/ooq931.c
    team/may/chan_ooh323_evo/addons/ooh323c/src/ootypes.h
    team/may/chan_ooh323_evo/apps/Makefile
    team/may/chan_ooh323_evo/apps/app_chanspy.c
    team/may/chan_ooh323_evo/apps/app_confbridge.c
    team/may/chan_ooh323_evo/apps/app_dial.c
    team/may/chan_ooh323_evo/apps/app_dumpchan.c
    team/may/chan_ooh323_evo/apps/app_externalivr.c
    team/may/chan_ooh323_evo/apps/app_followme.c
    team/may/chan_ooh323_evo/apps/app_jack.c
    team/may/chan_ooh323_evo/apps/app_meetme.c
    team/may/chan_ooh323_evo/apps/app_mixmonitor.c
    team/may/chan_ooh323_evo/apps/app_voicemail.c
    team/may/chan_ooh323_evo/bridges/bridge_builtin_features.c
    team/may/chan_ooh323_evo/bridges/bridge_multiplexed.c
    team/may/chan_ooh323_evo/bridges/bridge_softmix.c
    team/may/chan_ooh323_evo/cel/cel_odbc.c
    team/may/chan_ooh323_evo/channels/chan_agent.c
    team/may/chan_ooh323_evo/channels/chan_dahdi.c
    team/may/chan_ooh323_evo/channels/chan_gtalk.c
    team/may/chan_ooh323_evo/channels/chan_iax2.c
    team/may/chan_ooh323_evo/channels/chan_jingle.c
    team/may/chan_ooh323_evo/channels/chan_misdn.c
    team/may/chan_ooh323_evo/channels/chan_nbs.c
    team/may/chan_ooh323_evo/channels/chan_sip.c
    team/may/chan_ooh323_evo/channels/chan_skinny.c
    team/may/chan_ooh323_evo/channels/chan_unistim.c
    team/may/chan_ooh323_evo/channels/iax2.h
    team/may/chan_ooh323_evo/channels/sig_analog.c
    team/may/chan_ooh323_evo/channels/sig_pri.c
    team/may/chan_ooh323_evo/channels/sig_pri.h
    team/may/chan_ooh323_evo/channels/sig_ss7.c
    team/may/chan_ooh323_evo/channels/sig_ss7.h
    team/may/chan_ooh323_evo/channels/sip/dialplan_functions.c
    team/may/chan_ooh323_evo/channels/sip/include/sip.h
    team/may/chan_ooh323_evo/channels/sip/reqresp_parser.c
    team/may/chan_ooh323_evo/codecs/Makefile
    team/may/chan_ooh323_evo/codecs/codec_a_mu.c
    team/may/chan_ooh323_evo/codecs/codec_adpcm.c
    team/may/chan_ooh323_evo/codecs/codec_alaw.c
    team/may/chan_ooh323_evo/codecs/codec_dahdi.c
    team/may/chan_ooh323_evo/codecs/codec_g722.c
    team/may/chan_ooh323_evo/codecs/codec_g726.c
    team/may/chan_ooh323_evo/codecs/codec_gsm.c
    team/may/chan_ooh323_evo/codecs/codec_ilbc.c
    team/may/chan_ooh323_evo/codecs/codec_lpc10.c
    team/may/chan_ooh323_evo/codecs/codec_resample.c
    team/may/chan_ooh323_evo/codecs/codec_speex.c
    team/may/chan_ooh323_evo/codecs/codec_ulaw.c
    team/may/chan_ooh323_evo/codecs/ex_adpcm.h
    team/may/chan_ooh323_evo/codecs/ex_alaw.h
    team/may/chan_ooh323_evo/codecs/ex_g722.h
    team/may/chan_ooh323_evo/codecs/ex_g726.h
    team/may/chan_ooh323_evo/codecs/ex_gsm.h
    team/may/chan_ooh323_evo/codecs/ex_lpc10.h
    team/may/chan_ooh323_evo/codecs/ex_speex.h
    team/may/chan_ooh323_evo/codecs/ex_ulaw.h
    team/may/chan_ooh323_evo/codecs/gsm/Makefile
    team/may/chan_ooh323_evo/codecs/lpc10/Makefile
    team/may/chan_ooh323_evo/configs/calendar.conf.sample
    team/may/chan_ooh323_evo/configs/ccss.conf.sample
    team/may/chan_ooh323_evo/configs/cdr_mysql.conf.sample
    team/may/chan_ooh323_evo/configs/chan_dahdi.conf.sample
    team/may/chan_ooh323_evo/configs/codecs.conf.sample
    team/may/chan_ooh323_evo/configs/extensions.lua.sample
    team/may/chan_ooh323_evo/configs/http.conf.sample
    team/may/chan_ooh323_evo/configs/iax.conf.sample
    team/may/chan_ooh323_evo/configs/indications.conf.sample
    team/may/chan_ooh323_evo/configs/manager.conf.sample
    team/may/chan_ooh323_evo/configs/sip.conf.sample
    team/may/chan_ooh323_evo/configs/skinny.conf.sample
    team/may/chan_ooh323_evo/configs/users.conf.sample
    team/may/chan_ooh323_evo/configure
    team/may/chan_ooh323_evo/configure.ac
    team/may/chan_ooh323_evo/formats/format_g719.c
    team/may/chan_ooh323_evo/formats/format_g723.c
    team/may/chan_ooh323_evo/formats/format_g726.c
    team/may/chan_ooh323_evo/formats/format_g729.c
    team/may/chan_ooh323_evo/formats/format_gsm.c
    team/may/chan_ooh323_evo/formats/format_h263.c
    team/may/chan_ooh323_evo/formats/format_h264.c
    team/may/chan_ooh323_evo/formats/format_ilbc.c
    team/may/chan_ooh323_evo/formats/format_jpeg.c
    team/may/chan_ooh323_evo/formats/format_ogg_vorbis.c
    team/may/chan_ooh323_evo/formats/format_pcm.c
    team/may/chan_ooh323_evo/formats/format_siren14.c
    team/may/chan_ooh323_evo/formats/format_siren7.c
    team/may/chan_ooh323_evo/formats/format_sln.c
    team/may/chan_ooh323_evo/formats/format_sln16.c
    team/may/chan_ooh323_evo/formats/format_vox.c
    team/may/chan_ooh323_evo/formats/format_wav.c
    team/may/chan_ooh323_evo/formats/format_wav_gsm.c
    team/may/chan_ooh323_evo/funcs/func_channel.c
    team/may/chan_ooh323_evo/funcs/func_odbc.c
    team/may/chan_ooh323_evo/funcs/func_pitchshift.c
    team/may/chan_ooh323_evo/funcs/func_speex.c
    team/may/chan_ooh323_evo/funcs/func_volume.c
    team/may/chan_ooh323_evo/include/asterisk/_private.h
    team/may/chan_ooh323_evo/include/asterisk/abstract_jb.h
    team/may/chan_ooh323_evo/include/asterisk/audiohook.h
    team/may/chan_ooh323_evo/include/asterisk/autoconfig.h.in
    team/may/chan_ooh323_evo/include/asterisk/bridging.h
    team/may/chan_ooh323_evo/include/asterisk/bridging_features.h
    team/may/chan_ooh323_evo/include/asterisk/bridging_technology.h
    team/may/chan_ooh323_evo/include/asterisk/calendar.h
    team/may/chan_ooh323_evo/include/asterisk/callerid.h
    team/may/chan_ooh323_evo/include/asterisk/channel.h
    team/may/chan_ooh323_evo/include/asterisk/dsp.h
    team/may/chan_ooh323_evo/include/asterisk/file.h
    team/may/chan_ooh323_evo/include/asterisk/format.h
    team/may/chan_ooh323_evo/include/asterisk/frame.h
    team/may/chan_ooh323_evo/include/asterisk/frame_defs.h
    team/may/chan_ooh323_evo/include/asterisk/rtp_engine.h
    team/may/chan_ooh323_evo/include/asterisk/select.h
    team/may/chan_ooh323_evo/include/asterisk/slin.h
    team/may/chan_ooh323_evo/include/asterisk/slinfactory.h
    team/may/chan_ooh323_evo/include/asterisk/time.h
    team/may/chan_ooh323_evo/include/asterisk/translate.h
    team/may/chan_ooh323_evo/main/abstract_jb.c
    team/may/chan_ooh323_evo/main/app.c
    team/may/chan_ooh323_evo/main/ast_expr2.fl
    team/may/chan_ooh323_evo/main/ast_expr2f.c
    team/may/chan_ooh323_evo/main/asterisk.c
    team/may/chan_ooh323_evo/main/audiohook.c
    team/may/chan_ooh323_evo/main/bridging.c
    team/may/chan_ooh323_evo/main/callerid.c
    team/may/chan_ooh323_evo/main/ccss.c
    team/may/chan_ooh323_evo/main/channel.c
    team/may/chan_ooh323_evo/main/cli.c
    team/may/chan_ooh323_evo/main/data.c
    team/may/chan_ooh323_evo/main/dial.c
    team/may/chan_ooh323_evo/main/dsp.c
    team/may/chan_ooh323_evo/main/features.c
    team/may/chan_ooh323_evo/main/file.c
    team/may/chan_ooh323_evo/main/frame.c
    team/may/chan_ooh323_evo/main/http.c
    team/may/chan_ooh323_evo/main/image.c
    team/may/chan_ooh323_evo/main/indications.c
    team/may/chan_ooh323_evo/main/lock.c
    team/may/chan_ooh323_evo/main/manager.c
    team/may/chan_ooh323_evo/main/pbx.c
    team/may/chan_ooh323_evo/main/rtp_engine.c
    team/may/chan_ooh323_evo/main/slinfactory.c
    team/may/chan_ooh323_evo/main/tcptls.c
    team/may/chan_ooh323_evo/main/translate.c
    team/may/chan_ooh323_evo/main/udptl.c
    team/may/chan_ooh323_evo/main/utils.c
    team/may/chan_ooh323_evo/makeopts.in
    team/may/chan_ooh323_evo/pbx/pbx_ael.c
    team/may/chan_ooh323_evo/pbx/pbx_config.c
    team/may/chan_ooh323_evo/pbx/pbx_lua.c
    team/may/chan_ooh323_evo/res/res_adsi.c
    team/may/chan_ooh323_evo/res/res_agi.c
    team/may/chan_ooh323_evo/res/res_calendar.c
    team/may/chan_ooh323_evo/res/res_clioriginate.c
    team/may/chan_ooh323_evo/res/res_config_odbc.c
    team/may/chan_ooh323_evo/res/res_fax.c
    team/may/chan_ooh323_evo/res/res_fax_spandsp.c
    team/may/chan_ooh323_evo/res/res_jabber.c
    team/may/chan_ooh323_evo/res/res_musiconhold.c
    team/may/chan_ooh323_evo/res/res_mutestream.c
    team/may/chan_ooh323_evo/res/res_phoneprov.c
    team/may/chan_ooh323_evo/res/res_rtp_asterisk.c
    team/may/chan_ooh323_evo/res/res_rtp_multicast.c
    team/may/chan_ooh323_evo/res/res_speech.c

Propchange: team/may/chan_ooh323_evo/
------------------------------------------------------------------------------
--- branch-1.8-blocked (original)
+++ branch-1.8-blocked Sat Apr 23 12:34:45 2011
@@ -1,1 +1,1 @@
-/branches/1.8:299531
+/branches/1.8:299531,313436

Propchange: team/may/chan_ooh323_evo/
------------------------------------------------------------------------------
Binary property 'branch-1.8-merged' - no diff available.

Propchange: team/may/chan_ooh323_evo/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Sat Apr 23 12:34:45 2011
@@ -1,1 +1,1 @@
-/trunk:1-308372
+/trunk:1-315001

Modified: team/may/chan_ooh323_evo/CHANGES
URL: http://svnview.digium.com/svn/asterisk/team/may/chan_ooh323_evo/CHANGES?view=diff&rev=315047&r1=315046&r2=315047
==============================================================================
--- team/may/chan_ooh323_evo/CHANGES (original)
+++ team/may/chan_ooh323_evo/CHANGES Sat Apr 23 12:34:45 2011
@@ -23,10 +23,18 @@
    for chan_dahdi ISDN channels.
  * Added new action MeetmeListRooms to list active conferences (shows same
    data as "meetme list" at the CLI).
+ * DAHDIShowChannels, SIPshowpeer, SIPpeers, and IAXpeers now contains a
+   Description field that is set by 'description' in the channel configuration
+   file.
 
 Asterisk HTTP Server
 --------------------------
  * The HTTP Server can bind to IPv6 addresses.
+
+chan_dahdi
+--------------------------
+ * Busy tone patterns featuring 2 silence and 2 tone lengths can now be used
+   with busydetect.  usage example: busypattern=200,200,200,600
 
 CLI Changes
 --------------------------
@@ -34,11 +42,28 @@
    gtalk.conf.
  * The 'logger reload' command now supports an optional argument, specifying an
    alternate configuration file to use.
+ * 'dialplan add extension' command will now automatically create a context if
+   the specified context does not exist with a message indicated it did so.
+ * 'sip show peers', 'iax show peers', and 'dahdi show peers' now contains a
+   Description field which can be populated with 'description' in the channel
+   configuration files (sip.conf, iax2.conf, and chan_dahdi.conf).
 
 CDR
 --------------------------
  * The filter option in cdr_adaptive_odbc now supports negating the argument,
    thus allowing records which do NOT match the specified filter.
+
+CODECS
+--------------------------
+ * Ability to define custom SILK formats in codecs.conf.
+ * Addition of speex32 audio format with translation.
+
+ConfBridge
+--------------------------
+ * New highly optimized and customizable ConfBridge application capable of
+   mixing audio at sample rates ranging from 8khz-96khz.
+ * CONFBRIDGE dialplan function capable of creating dynamic ConfBridge user
+   and bridge profiles on a channel.
 
 Dialplan Variables
 ------------------
@@ -48,6 +73,10 @@
 
 Dialplan Functions
 ------------------
+ * Addition of the JITTERBUFFER dialplan function. This function allows
+   for jitterbuffering to occur on the read side of a channel.  By using
+   this function conference applications such as ConfBridge and MeetMe can
+   have the rx streams jitterbuffered before conference mixing occurs.
  * Added DB_KEYS, which lists the next set of keys in the Asterisk database
    hierarchy.
 
@@ -59,6 +88,25 @@
    is handled.  To send display text from the dialplan use the SendText()
    application when the option is enabled.
  * Added mcid_send option to allow sending a MCID request on a span.
+
+Calendaring
+--------------------------
+ * Added setvar option to calendar.conf to allow setting channel variables on
+   notification channels.
+
+MixMonitor
+--------------------------
+ * Added two new options, r and t with file name arguments to record 
+   single direction (unmixed) audio recording separate from the bidirectional
+   (mixed) recording.  The mixed file name argument is optional now as long
+   as at least one recording option is used.
+
+FollowMe
+--------------------------
+ * Added a new option, l, which will disable local call optimization for
+   channels involved with the FollowMe thread.  Use this option to improve
+   compatability for a FollowMe call with certain dialplan apps, options, and
+   functions.
 
 ------------------------------------------------------------------------------
 --- Functionality changes from Asterisk 1.6.2 to Asterisk 1.8 ----------------

Modified: team/may/chan_ooh323_evo/CREDITS
URL: http://svnview.digium.com/svn/asterisk/team/may/chan_ooh323_evo/CREDITS?view=diff&rev=315047&r1=315046&r2=315047
==============================================================================
--- team/may/chan_ooh323_evo/CREDITS (original)
+++ team/may/chan_ooh323_evo/CREDITS Sat Apr 23 12:34:45 2011
@@ -222,6 +222,8 @@
 Despegar.com, Argentina - AstData API implementation, also sponsored by Google as part of the
 	gsoc/2009 program (developed by Eliel)
 
+Philippe Lindheimer - DEV_STATE additions to CCSS
+
 === OTHER CONTRIBUTIONS ===
 John Todd - Monkey sounds and associated teletorture prompt
 Michael Jerris - bug marshaling

Modified: team/may/chan_ooh323_evo/Makefile
URL: http://svnview.digium.com/svn/asterisk/team/may/chan_ooh323_evo/Makefile?view=diff&rev=315047&r1=315046&r2=315047
==============================================================================
--- team/may/chan_ooh323_evo/Makefile (original)
+++ team/may/chan_ooh323_evo/Makefile Sat Apr 23 12:34:45 2011
@@ -223,8 +223,12 @@
 endif
 
 ifeq ($(findstring -march,$(_ASTCFLAGS) $(ASTCFLAGS)),)
-  ifneq ($(PROC),ultrasparc)
-    _ASTCFLAGS+=$(shell if $(CC) -march=$(PROC) -S -o /dev/null -xc /dev/null >/dev/null 2>&1; then echo "-march=$(PROC)"; fi)
+  ifneq ($(AST_MARCH_NATIVE),)
+    _ASTCFLAGS+=$(AST_MARCH_NATIVE)
+  else
+    ifneq ($(PROC),ultrasparc)
+      _ASTCFLAGS+=$(shell if $(CC) -march=$(PROC) -S -o /dev/null -xc /dev/null >/dev/null 2>&1; then echo "-march=$(PROC)"; fi)
+    endif
   endif
 endif
 
@@ -233,8 +237,10 @@
 endif
 
 ifeq ($(OSARCH),FreeBSD)
-  ifeq ($(PROC),i386)
-    _ASTCFLAGS+=-march=i686
+  ifeq ($(findstring -march,$(_ASTCFLAGS) $(ASTCFLAGS)),)
+    ifeq ($(PROC),i386)
+      _ASTCFLAGS+=-march=i686
+    endif
   endif
   # -V is understood by BSD Make, not by GNU make.
   BSDVERSION=$(shell make -V OSVERSION -f /usr/share/mk/bsd.port.subdir.mk)

Modified: team/may/chan_ooh323_evo/UPGRADE-1.8.txt
URL: http://svnview.digium.com/svn/asterisk/team/may/chan_ooh323_evo/UPGRADE-1.8.txt?view=diff&rev=315047&r1=315046&r2=315047
==============================================================================
--- team/may/chan_ooh323_evo/UPGRADE-1.8.txt (original)
+++ team/may/chan_ooh323_evo/UPGRADE-1.8.txt Sat Apr 23 12:34:45 2011
@@ -71,6 +71,15 @@
   collisions, the channel name format is changed.
   The new channel naming for PRI channels is:
   DAHDI/i<span>/<number>[:<subaddress>]-<sequence-number>
+
+* Added CHANNEL(dahdi_span), CHANNEL(dahdi_channel), and CHANNEL(dahdi_type)
+  so the dialplan can determine the B channel currently in use by the channel.
+  Use CHANNEL(no_media_path) to determine if the channel even has a B channel.
+
+* Added AMI event DAHDIChannel to associate a DAHDI channel with an Asterisk
+  channel so AMI applications can passively determine the B channel currently
+  in use.  Calls with "no-media" as the DAHDIChannel do not have an associated
+  B channel.  No-media calls are either on hold or call-waiting.
 
 * The ChanIsAvail application has been changed so the AVAILSTATUS variable
   no longer contains both the device state and cause code. The cause code

Modified: team/may/chan_ooh323_evo/UPGRADE.txt
URL: http://svnview.digium.com/svn/asterisk/team/may/chan_ooh323_evo/UPGRADE.txt?view=diff&rev=315047&r1=315046&r2=315047
==============================================================================
--- team/may/chan_ooh323_evo/UPGRADE.txt (original)
+++ team/may/chan_ooh323_evo/UPGRADE.txt Sat Apr 23 12:34:45 2011
@@ -21,6 +21,10 @@
 
 From 1.8 to 1.10:
 
+ConfBridge
+ - ConfBridge's dialplan arguments have changed and are not
+   backwards compatible.
+
 HTTP:
  - A bindaddr must be specified in order for the HTTP server
    to run. Previous versions would default to 0.0.0.0 if no

Modified: team/may/chan_ooh323_evo/addons/cdr_mysql.c
URL: http://svnview.digium.com/svn/asterisk/team/may/chan_ooh323_evo/addons/cdr_mysql.c?view=diff&rev=315047&r1=315046&r2=315047
==============================================================================
--- team/may/chan_ooh323_evo/addons/cdr_mysql.c (original)
+++ team/may/chan_ooh323_evo/addons/cdr_mysql.c Sat Apr 23 12:34:45 2011
@@ -428,7 +428,7 @@
 	int res;
 	struct ast_config *cfg;
 	struct ast_variable *var;
-	struct ast_flags config_flags = { reload ? CONFIG_FLAG_FILEUNCHANGED : 0 };
+	struct ast_flags config_flags = { 0 };
 	struct column *entry;
 	char *temp;
 	struct ast_str *compat;
@@ -439,6 +439,9 @@
 	my_bool my_bool_true = 1;
 #endif
 
+	/* Cannot use a conditionally different flag, because the table layout may
+	 * have changed, which is not detectable by config file change detection,
+	 * but should still cause the configuration to be re-parsed. */
 	cfg = ast_config_load(config, config_flags);
 	if (!cfg) {
 		ast_log(LOG_WARNING, "Unable to load config for mysql CDR's: %s\n", config);

Modified: team/may/chan_ooh323_evo/addons/chan_ooh323.c
URL: http://svnview.digium.com/svn/asterisk/team/may/chan_ooh323_evo/addons/chan_ooh323.c?view=diff&rev=315047&r1=315046&r2=315047
==============================================================================
--- team/may/chan_ooh323_evo/addons/chan_ooh323.c (original)
+++ team/may/chan_ooh323_evo/addons/chan_ooh323.c Sat Apr 23 12:34:45 2011
@@ -143,7 +143,7 @@
 	int faxmode;
 	int t38_tx_enable;
 	int t38_init;
-	struct sockaddr_in udptlredirip;
+	struct ast_sockaddr udptlredirip;
 	time_t lastTxT38;
 	int chmodepend;
 
@@ -212,7 +212,7 @@
 	int	    t38support;
 	int         rtptimeout;
 	int         mUseIP;        /* Use IP address or H323-ID to search user */
-	char        mIP[20];
+	char        mIP[4*8+7+2];  /* Max for IPv6 - 2 brackets, 8 4hex, 7 - : */
 	struct OOH323Regex	    *rtpmask;
 	char	    rtpmaskstr[120];
 	int	    rtdrcount, rtdrinterval;
@@ -235,7 +235,7 @@
 	int	    dtmfcodec;
 	int	    t38support;
 	int         mFriend;    /* indicates defined as friend */
-	char        ip[20];
+	char        ip[4*8+7+2]; /* Max for IPv6 - 2 brackets, 8 4hex, 7 - : */
 	int         port;
 	char        *h323id;    /* H323-ID alias, which asterisk will register with gk to reach this peer*/
 	char        *email;     /* Email alias, which asterisk will register with gk to reach this peer*/
@@ -286,7 +286,9 @@
 
 static char gLogFile[256] = DEFAULT_LOGFILE;
 static int  gPort = 1720;
-static char gIP[20];
+static char gIP[2+8*4+7];	/* Max for IPv6 addr */
+struct ast_sockaddr bindaddr;
+int v6mode = 0;
 static char gCallerID[AST_MAX_EXTENSION] = "";
 static struct ooAliases *gAliasList;
 static struct ast_format_cap *gCap;
@@ -373,10 +375,6 @@
 		ast_format_copy(&ch->rawwriteformat, &tmpfmt);
 		ast_format_copy(&ch->rawreadformat, &tmpfmt);
 
-		ast_channel_set_fd(ch, 0, ast_rtp_instance_fd(i->rtp, 0));
-		ast_channel_set_fd(ch, 1, ast_rtp_instance_fd(i->rtp, 1));
-		ast_channel_set_fd(ch, 5, ast_udptl_fd(i->udptl));
-
 		ast_jb_configure(ch, &global_jbconf);
 
 		if (state == AST_STATE_RING)
@@ -468,9 +466,7 @@
 static struct ooh323_pvt *ooh323_alloc(int callref, char *callToken) 
 {
 	struct ooh323_pvt *pvt = NULL;
-	struct sockaddr_in ouraddr;
-	struct ast_sockaddr tmp;
-	struct in_addr ipAddr;
+
 	if (gH323Debug)
 		ast_verbose("---   ooh323_alloc\n");
 
@@ -487,39 +483,6 @@
 	ast_mutex_init(&pvt->lock);
 	ast_mutex_lock(&pvt->lock);
 
-
-	if (!inet_aton(gIP, &ipAddr)) {
-		ast_log(LOG_ERROR, "Invalid OOH323 driver ip address\n");
-		ast_mutex_unlock(&pvt->lock);
-		ast_mutex_destroy(&pvt->lock);
-		ast_free(pvt);
-		return NULL;
-	}
-
-	ouraddr.sin_family = AF_INET;
-	ouraddr.sin_addr = ipAddr;
-	ast_sockaddr_from_sin(&tmp, &ouraddr);
-	if (!(pvt->rtp = ast_rtp_instance_new("asterisk", sched, &tmp, NULL))) {
-		ast_log(LOG_WARNING, "Unable to create RTP session: %s\n", 
-				  strerror(errno));
-		ast_mutex_unlock(&pvt->lock);
-		ast_mutex_destroy(&pvt->lock);
-		ast_free(pvt);
-		return NULL;
-	}
- 
-	ast_rtp_instance_set_qos(pvt->rtp, gTOS, 0, "ooh323-rtp");
-
-	if (!(pvt->udptl = ast_udptl_new_with_bindaddr(sched, io, 0, &tmp))) {
-		ast_log(LOG_WARNING, "Unable to create UDPTL session: %s\n",
-				strerror(errno));
-		ast_mutex_unlock(&pvt->lock);
-		ast_mutex_destroy(&pvt->lock);
-		ast_free(pvt);
-		return NULL;
-	}
-
-	ast_udptl_set_error_correction_scheme(pvt->udptl, UDPTL_ERROR_CORRECTION_NONE);
 	pvt->faxmode = 0;
 	pvt->t38support = gT38Support;
 	pvt->rtptimeout = gRTPTimeout;
@@ -1045,13 +1008,13 @@
 
 		if (gH323Debug)
 			ast_verbose("    hanging %s with cause: %d\n", p->username, q931cause);
-		ast->tech_pvt = NULL;
+		ast->tech_pvt = NULL; 
 		if (!ast_test_flag(p, H323_ALREADYGONE)) {
-			ooHangCall(p->callToken,
+         		ooHangCall(p->callToken, 
 				ooh323_convert_hangupcause_asteriskToH323(q931cause), q931cause);
 			ast_set_flag(p, H323_ALREADYGONE);
 			/* ast_mutex_unlock(&p->lock); */
-		} else
+      		} else 
 			ast_set_flag(p, H323_NEEDDESTROY);
 		/* detach channel here */
 		if (p->owner) {
@@ -1067,11 +1030,11 @@
 
 		/* Notify the module monitors that use count for resource has changed */
 		ast_update_use_count();
-
+	  
 	} else {
 		ast_debug(1, "No call to hangup\n" );
 	}
-
+	
 	if (gH323Debug)
 		ast_verbose("+++   ooh323_hangup\n");
 
@@ -1091,7 +1054,8 @@
 		if (ast->_state != AST_STATE_UP) {
 			ast_channel_lock(ast);
 			ast_setstate(ast, AST_STATE_UP);
-			ast_debug(1, "ooh323_answer(%s)\n", ast->name);
+      			if (option_debug)
+				ast_debug(1, "ooh323_answer(%s)\n", ast->name);
 			ast_channel_unlock(ast);
 			ooAnswerCall(p->callToken);
 		}
@@ -1140,10 +1104,11 @@
 			return res;
 		}
 
+	
 		if (f->frametype == AST_FRAME_VOICE) {
 /* sending progress for first */
 			if (!ast_test_flag(p, H323_OUTGOING) && !p->progsent &&
-					p->callToken) {
+			 		p->callToken) {
 				ooManualProgress(p->callToken);
 				p->progsent = 1;
 			}
@@ -1192,6 +1157,7 @@
 
 	struct ooh323_pvt *p = (struct ooh323_pvt *) ast->tech_pvt;
 	char *callToken = (char *)NULL;
+	int res = -1;
 
 	if (!p) return -1;
 
@@ -1207,39 +1173,39 @@
 
 	if (gH323Debug)
 		ast_verbose("----- ooh323_indicate %d on call %s\n", condition, callToken);
-
-	ast_mutex_lock(&p->lock);
+	 
+   	ast_mutex_lock(&p->lock);
 	switch (condition) {
 	case AST_CONTROL_CONGESTION:
 		if (!ast_test_flag(p, H323_ALREADYGONE)) {
-			ooHangCall(callToken, OO_REASON_LOCAL_CONGESTED,
+            		ooHangCall(callToken, OO_REASON_LOCAL_CONGESTED, 
 						AST_CAUSE_SWITCH_CONGESTION);
 			ast_set_flag(p, H323_ALREADYGONE);
 		}
 		break;
 	case AST_CONTROL_BUSY:
 		if (!ast_test_flag(p, H323_ALREADYGONE)) {
-			ooHangCall(callToken, OO_REASON_LOCAL_BUSY, AST_CAUSE_USER_BUSY);
+            		ooHangCall(callToken, OO_REASON_LOCAL_BUSY, AST_CAUSE_USER_BUSY);
 			ast_set_flag(p, H323_ALREADYGONE);
 		}
 		break;
 	case AST_CONTROL_HOLD:
-		ast_moh_start(ast, data, NULL);
+		ast_moh_start(ast, data, NULL);		
 		break;
 	case AST_CONTROL_UNHOLD:
 		ast_moh_stop(ast);
 		break;
 	case AST_CONTROL_PROGRESS:
 		if (ast->_state != AST_STATE_UP) {
-			if (!p->progsent) {
-				if (gH323Debug) {
+	    		if (!p->progsent) {
+	     			if (gH323Debug) {
 					ast_debug(1, "Sending manual progress for %s, res = %d\n", callToken,
-					ooManualProgress(callToken));
+             				ooManualProgress(callToken));	
 				} else {
-					ooManualProgress(callToken);
+	     				ooManualProgress(callToken);
 				}
-				p->progsent = 1;
-			}
+	     			p->progsent = 1;
+	    		}
 		}
 	    break;
       case AST_CONTROL_RINGING:
@@ -1257,10 +1223,14 @@
 		}
 	 break;
 	case AST_CONTROL_SRCUPDATE:
-		ast_rtp_instance_update_source(p->rtp);
+		if (p->rtp) {
+			ast_rtp_instance_update_source(p->rtp);
+		}
 		break;
 	case AST_CONTROL_SRCCHANGE:
-		ast_rtp_instance_change_source(p->rtp);
+		if (p->rtp) {
+			ast_rtp_instance_change_source(p->rtp);
+		}
 		break;
 	case AST_CONTROL_CONNECTED_LINE:
 		if (!ast->connected.id.name.valid
@@ -1296,6 +1266,7 @@
 				if (!p->chmodepend && !p->faxmode) {
 					ooRequestChangeMode(p->callToken, 1);
 					p->chmodepend = 1;
+					res = 0;
 				}
 				break;
 
@@ -1304,6 +1275,7 @@
 				if (!p->chmodepend && p->faxmode) {
 					ooRequestChangeMode(p->callToken, 0);
 					p->chmodepend = 1;
+					res = 0;
 				}
 				break;
 
@@ -1329,7 +1301,7 @@
 		ast_verbose("++++  ooh323_indicate %d on %s\n", condition, callToken);
 
    	free(callToken);
-	return -1;
+	return res;
 }
 
 static int ooh323_queryoption(struct ast_channel *ast, int option, void *data, int *datalen)
@@ -1385,8 +1357,8 @@
 
 	if (gH323Debug)
 		ast_verbose("+++++ ooh323_queryoption %d on channel %s\n", option, ast->name);
-
-	ast_mutex_unlock(&p->lock);
+	 
+   	ast_mutex_unlock(&p->lock);
 
 	return res;
 }
@@ -1430,9 +1402,9 @@
 	char formats[FORMAT_STRING_SIZE];
 
 	if (gH323Debug)
-		ast_verbose("---   ooh323_update_writeformat %s/%d\n",
+		ast_verbose("---   ooh323_update_writeformat %s/%d\n", 
 				ast_getformatname(fmt), txframes);
-
+	
 	p = find_call(call);
 	if (!p) {
 		ast_log(LOG_ERROR, "No matching call found for %s\n", call->callToken);
@@ -1445,7 +1417,7 @@
 
 	if (p->owner) {
 		while (p->owner && ast_channel_trylock(p->owner)) {
-			ast_debug(1, "Failed to grab lock, trying again\n");
+			ast_debug(1,"Failed to grab lock, trying again\n");
 			DEADLOCK_AVOIDANCE(&p->lock);
 		}
 		if (!p->owner) {
@@ -1454,7 +1426,7 @@
 			return;
 		}
 		if (gH323Debug)
-			ast_verbose("Writeformat before update %s/%s\n",
+	  		ast_verbose("Writeformat before update %s/%s\n", 
 			  ast_getformatname(&p->owner->writeformat),
 			  ast_getformatname_multiple(formats, sizeof(formats), p->owner->nativeformats));
 		if (txframes)
@@ -1490,7 +1462,7 @@
 	if (gH323Debug)
 		ast_verbose("---   ooh323_update_readformat %s\n", 
 				ast_getformatname(fmt));
-
+	
 	p = find_call(call);
 	if (!p) {
 		ast_log(LOG_ERROR, "No matching call found for %s\n", call->callToken);
@@ -1503,7 +1475,7 @@
 
 	if (p->owner) {
 		while (p->owner && ast_channel_trylock(p->owner)) {
-			ast_debug(1, "Failed to grab lock, trying again\n");
+			ast_debug(1,"Failed to grab lock, trying again\n");
 			DEADLOCK_AVOIDANCE(&p->lock);
 		}
 		if (!p->owner) {
@@ -1513,12 +1485,12 @@
 		}
 
 		if (gH323Debug)
-			ast_verbose("Readformat before update %s\n",
+	  		ast_verbose("Readformat before update %s\n", 
 				  ast_getformatname(&p->owner->readformat));
 		ast_format_cap_set(p->owner->nativeformats, fmt);
-		ast_set_read_format(p->owner, &p->owner->readformat);
+	  	ast_set_read_format(p->owner, &p->owner->readformat);
 		ast_channel_unlock(p->owner);
-	} else
+   	} else
 		ast_log(LOG_ERROR, "No owner found\n");
 
 	ast_mutex_unlock(&p->lock);
@@ -1536,12 +1508,12 @@
 	if (gH323Debug)
 		ast_verbose("--- onAlerting %s\n", call->callToken);
 
-	p = find_call(call);
-
-	if(!p) {
+   	p = find_call(call);
+
+   	if(!p) {
 		ast_log(LOG_ERROR, "No matching call found\n");
 		return -1;
-	}
+	}  
 	ast_mutex_lock(&p->lock);
 	if (!p->owner) {
 		ast_mutex_unlock(&p->lock);
@@ -1592,12 +1564,12 @@
 	if (gH323Debug)
 		ast_verbose("--- onProgress %s\n", call->callToken);
 
-	p = find_call(call);
-
-	if(!p) {
+   	p = find_call(call);
+
+   	if(!p) {
 		ast_log(LOG_ERROR, "No matching call found\n");
 		return -1;
-	}
+	}  
 	ast_mutex_lock(&p->lock);
 	if (!p->owner) {
 		ast_mutex_unlock(&p->lock);
@@ -1631,8 +1603,8 @@
 		ast_setstate(c, AST_STATE_RINGING);
 
 	ast_queue_control(c, AST_CONTROL_PROGRESS);
-	ast_channel_unlock(c);
-	ast_mutex_unlock(&p->lock);
+      	ast_channel_unlock(c);
+      	ast_mutex_unlock(&p->lock);
 
 	if (gH323Debug)
 		ast_verbose("+++ onProgress %s\n", call->callToken);
@@ -1811,10 +1783,14 @@
 	} else {
 	  ast_mutex_unlock(&p->lock);
 	  ast_log(LOG_ERROR, "Unacceptable ip %s\n", call->remoteIP);
-	  if (!user) 
+	  if (!user) {
 	   ooHangCall(call->callToken, ooh323_convert_hangupcause_asteriskToH323(AST_CAUSE_CALL_REJECTED), AST_CAUSE_CALL_REJECTED);
-	  else
+	   call->callEndReason = OO_REASON_REMOTE_REJECTED;
+	  }
+	  else {
 	   ooHangCall(call->callToken, ooh323_convert_hangupcause_asteriskToH323(AST_CAUSE_NORMAL_CIRCUIT_CONGESTION), AST_CAUSE_NORMAL_CIRCUIT_CONGESTION);
+	   call->callEndReason = OO_REASON_REMOTE_REJECTED;
+	  }
 	  ast_set_flag(p, H323_NEEDDESTROY);
 	  return -1;
 	 }
@@ -1822,15 +1798,19 @@
 
 	ooh323c_set_capability_for_call(call, &p->prefs, p->cap, p->dtmfmode, p->dtmfcodec,
 					 p->t38support, p->g729onlyA);
-	configure_local_rtp(p, call);
-
 /* Incoming call */
   	c = ooh323_new(p, AST_STATE_RING, p->username, 0, NULL);
   	if(!c) {
    	ast_mutex_unlock(&p->lock);
    	ast_log(LOG_ERROR, "Could not create ast_channel\n");
          return -1;
-  }
+  	}
+	if (!configure_local_rtp(p, call)) {
+		ast_mutex_unlock(&p->lock);
+		ast_log(LOG_ERROR, "Couldn't create rtp structure\n");
+		return -1;
+	}
+
 	ast_mutex_unlock(&p->lock);
 
 	if (gH323Debug)
@@ -1901,6 +1881,11 @@
 			ast_copy_string(call->rtpMaskStr, p->rtpmaskstr, sizeof(call->rtpMaskStr));
 		}
 
+		if (!configure_local_rtp(p, call)) {
+			ast_mutex_unlock(&p->lock);
+			return OO_FAILED;
+		}
+
 		ast_mutex_unlock(&p->lock);
 	}
 
@@ -1990,7 +1975,7 @@
       		ooh323c_set_capability_for_call(call, &p->prefs, p->cap,
                                      p->dtmfmode, p->dtmfcodec, p->t38support, p->g729onlyA);
 
-		configure_local_rtp(p, call);
+		/* configure_local_rtp(p, call); */
 		ast_mutex_unlock(&p->lock);
 	}
 
@@ -2013,14 +1998,14 @@
 		return -1;
 	}
 
-	if(ast_test_flag(p, H323_OUTGOING)) {
+   	if(ast_test_flag(p, H323_OUTGOING)) {
 		ast_mutex_lock(&p->lock);
 		if (!p->owner) {
 			ast_mutex_unlock(&p->lock);
 			ast_log(LOG_ERROR, "Channel has no owner\n");
 			return -1;
 		}
-
+	
 		while (p->owner && ast_channel_trylock(p->owner)) {
 			ast_debug(1, "Failed to grab lock, trying again\n");
 			DEADLOCK_AVOIDANCE(&p->lock);
@@ -2042,7 +2027,7 @@
 			}
 
 			ast_queue_control(c, AST_CONTROL_ANSWER);
-			ast_channel_unlock(p->owner);
+   			ast_channel_unlock(p->owner);
 			manager_event(EVENT_FLAG_SYSTEM,"ChannelUpdate","Channel: %s\r\nChanneltype: %s\r\n"
 				"CallRef: %d\r\n", c->name, "OOH323", p->call_reference);
 		}
@@ -2067,42 +2052,42 @@
 
    if ((p = find_call(call))) {
 	ast_mutex_lock(&p->lock);
-
+  
 	while (p->owner) {
 		if (ast_channel_trylock(p->owner)) {
 			ooTrace(OOTRCLVLINFO, "Failed to grab lock, trying again\n");
-			ast_debug(1, "Failed to grab lock, trying again\n");
+         		ast_debug(1, "Failed to grab lock, trying again\n");
 			DEADLOCK_AVOIDANCE(&p->lock);
 		} else {
-			ownerLock = 1; break;
+         		ownerLock = 1; break;
 		}
 	}
 
 	if (ownerLock) {
-		if (!ast_test_flag(p, H323_ALREADYGONE)) {
+		if (!ast_test_flag(p, H323_ALREADYGONE)) { 
 
 			ast_set_flag(p, H323_ALREADYGONE);
 			p->owner->hangupcause = call->q931cause;
 			p->owner->_softhangup |= AST_SOFTHANGUP_DEV;
 			ast_queue_hangup_with_cause(p->owner,call->q931cause);
 		}
-	}
-
-	if(p->owner) {
-		p->owner->tech_pvt = NULL;
+   	}
+
+   	if(p->owner) {
+    		p->owner->tech_pvt = NULL;
 		ast_channel_unlock(p->owner);
-		p->owner = NULL;
+    		p->owner = NULL;
 		ast_module_unref(myself);
 	}
 
 	ast_set_flag(p, H323_NEEDDESTROY);
 
-	ooh323c_stop_call_thread(call);
+   	ooh323c_stop_call_thread(call);
 
 	ast_mutex_unlock(&p->lock);
-	ast_mutex_lock(&usecnt_lock);
-	usecnt--;
-	ast_mutex_unlock(&usecnt_lock);
+   	ast_mutex_lock(&usecnt_lock);
+   	usecnt--;
+   	ast_mutex_unlock(&usecnt_lock);
 
     }
 
@@ -2257,12 +2242,14 @@
 					 user->cap,  tcodecs, 1);
 			} else if (!strcasecmp(v->name, "amaflags")) {
 				user->amaflags = ast_cdr_amaflags2int(v->value);
-			} else if (!strcasecmp(v->name, "ip")) {
-            			strncpy(user->mIP, v->value, sizeof(user->mIP)-1);
+         		} else if (!strcasecmp(v->name, "ip") || !strcasecmp(v->name, "host")) {
+				struct ast_sockaddr p;
+				if (!ast_parse_arg(v->value, PARSE_ADDR, &p)) {
+					ast_copy_string(user->mIP, ast_sockaddr_stringify_addr(&p), sizeof(user->mIP)-1);
+				} else {	
+            				ast_copy_string(user->mIP, v->value, sizeof(user->mIP)-1);
+				}
             			user->mUseIP = 1;
-         		} else if (!strcasecmp(v->name, "host")) {
-            			strncpy(user->mIP, v->value, sizeof(user->mIP)-1);
-				user->mUseIP = 1;
 	 		} else if (!strcasecmp(v->name, "dtmfmode")) {
 				if (!strcasecmp(v->value, "rfc2833"))
 					user->dtmfmode = H323_DTMF_RFC2833;
@@ -2363,10 +2350,14 @@
 				}
 			} else if (!strcasecmp(v->name, "port")) {
 				peer->port = atoi(v->value);
-			} else if (!strcasecmp(v->name, "ip")) {
-				ast_copy_string(peer->ip, v->value, sizeof(peer->ip));
-         		} else if (!strcasecmp(v->name, "host")) {
-            			ast_copy_string(peer->ip, v->value, sizeof(peer->ip));
+         		} else if (!strcasecmp(v->name, "host") || !strcasecmp(v->name, "ip")) {
+				struct ast_sockaddr p;
+				if (!ast_parse_arg(v->value, PARSE_ADDR, &p)) {
+					ast_copy_string(peer->ip, ast_sockaddr_stringify_host(&p), sizeof(peer->ip));
+				} else {	
+            				ast_copy_string(peer->ip, v->value, sizeof(peer->ip));
+				}
+			
 			} else if (!strcasecmp(v->name, "outgoinglimit")) {
             			peer->outgoinglimit = atoi(v->value);
             			if (peer->outgoinglimit < 0)
@@ -2575,6 +2566,13 @@
 			gPort = (int)strtol(v->value, NULL, 10);
 		} else if (!strcasecmp(v->name, "bindaddr")) {
 			ast_copy_string(gIP, v->value, sizeof(gIP));
+			if (ast_parse_arg(v->value, PARSE_ADDR, &bindaddr)) {
+				ast_log(LOG_WARNING, "Invalid address: %s\n", v->value);
+				return 1;
+			}
+			if (ast_sockaddr_is_ipv6(&bindaddr)) {
+				v6mode = 1;
+			}
 		} else if (!strcasecmp(v->name, "h225portrange")) {
 			char* endlimit = 0;
          		char temp[512];
@@ -2794,7 +2792,7 @@
 	/* Determine ip address if neccessary */
 	if (ast_strlen_zero(gIP)) {
 		ooGetLocalIPAddress(gIP);
-		if (!strcmp(gIP, "127.0.0.1")) {
+		if (!strcmp(gIP, "127.0.0.1") || !strcmp(gIP, "::1")) {
 			ast_log(LOG_NOTICE, "Failed to determine local ip address. Please "
 									 "specify it in ooh323.conf. OOH323 Disabled\n");
 			return 1;
@@ -3312,6 +3310,9 @@
 		ooH323EpSetH225MsgCallbacks(h225Callbacks);
       		ooH323EpSetTraceLevel(gTRCLVL);
 		ooH323EpSetLocalAddress(gIP, gPort);
+		if (v6mode) {
+			ast_debug(1, "OOH323 channel is in IP6 mode\n");
+		}
 		ooH323EpSetCallerID(gCallerID);
  
       if(ooH323EpSetTCPPortRange(ooconfig.mTCPPortStart, 
@@ -3549,7 +3550,7 @@
 			free(cur->callerid_name);
 			cur->callerid_name = 0;
 		}
-
+		
 		if (cur->callerid_num) {
 			free(cur->callerid_num);
 			cur->callerid_num = 0;
@@ -3564,20 +3565,20 @@
 			ast_udptl_destroy(cur->udptl);
 			cur->udptl = NULL;
 		}
-
+	
 		/* Unlink us from the owner if we have one */
 		if (cur->owner) {
-			while(ast_channel_trylock(cur->owner)) {
-				ast_debug(1, "Failed to grab lock, trying again\n");
+         		while(ast_channel_trylock(cur->owner)) {
+            			ast_debug(1, "Failed to grab lock, trying again\n");
 				DEADLOCK_AVOIDANCE(&cur->lock);
-			}
+         		}           
 			ast_debug(1, "Detaching from %s\n", cur->owner->name);
 			cur->owner->tech_pvt = NULL;
 			ast_channel_unlock(cur->owner);
 			cur->owner = NULL;
 			ast_module_unref(myself);
 		}
-
+  
 		if (cur->vad) {
 			ast_dsp_free(cur->vad);
 			cur->vad = NULL;
@@ -3902,8 +3903,6 @@
 {
 	/* XXX Deal with Video */
 	struct ooh323_pvt *p;
-	struct sockaddr_in them;
-	struct sockaddr_in us;
 	struct ast_sockaddr tmp;
 	int mode;
 
@@ -3921,10 +3920,13 @@
 		return -1;
 	}

[... 33508 lines stripped ...]



More information about the asterisk-commits mailing list