[asterisk-commits] oej: branch oej/adb-appleraision-1.8-mark-2 r403147 - in /team/oej/adb-appler...

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Mon Nov 25 04:54:03 CST 2013


Author: oej
Date: Mon Nov 25 04:53:54 2013
New Revision: 403147

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=403147
Log:
Reset

Added:
    team/oej/adb-appleraision-1.8-mark-2/doc/CODING-GUIDELINES
      - copied unchanged from r382942, branches/1.8/doc/CODING-GUIDELINES
    team/oej/adb-appleraision-1.8-mark-2/tests/test_astobj2_thrash.c
      - copied unchanged from r382942, branches/1.8/tests/test_astobj2_thrash.c
    team/oej/adb-appleraision-1.8-mark-2/tests/test_hashtab_thrash.c
      - copied unchanged from r382942, branches/1.8/tests/test_hashtab_thrash.c
    team/oej/adb-appleraision-1.8-mark-2/tests/test_xml_escape.c
      - copied unchanged from r382942, branches/1.8/tests/test_xml_escape.c
Modified:
    team/oej/adb-appleraision-1.8-mark-2/   (props changed)
    team/oej/adb-appleraision-1.8-mark-2/CHANGES
    team/oej/adb-appleraision-1.8-mark-2/Makefile
    team/oej/adb-appleraision-1.8-mark-2/Makefile.rules
    team/oej/adb-appleraision-1.8-mark-2/README-SERIOUSLY.bestpractices.txt
    team/oej/adb-appleraision-1.8-mark-2/UPGRADE.txt
    team/oej/adb-appleraision-1.8-mark-2/addons/app_mysql.c
    team/oej/adb-appleraision-1.8-mark-2/addons/cdr_mysql.c
    team/oej/adb-appleraision-1.8-mark-2/addons/chan_mobile.c
    team/oej/adb-appleraision-1.8-mark-2/addons/chan_ooh323.c
    team/oej/adb-appleraision-1.8-mark-2/addons/ooh323c/src/ooGkClient.c
    team/oej/adb-appleraision-1.8-mark-2/addons/ooh323c/src/ooh323ep.c
    team/oej/adb-appleraision-1.8-mark-2/addons/res_config_mysql.c
    team/oej/adb-appleraision-1.8-mark-2/apps/app_celgenuserevent.c
    team/oej/adb-appleraision-1.8-mark-2/apps/app_chanspy.c
    team/oej/adb-appleraision-1.8-mark-2/apps/app_confbridge.c
    team/oej/adb-appleraision-1.8-mark-2/apps/app_db.c
    team/oej/adb-appleraision-1.8-mark-2/apps/app_dial.c
    team/oej/adb-appleraision-1.8-mark-2/apps/app_dictate.c
    team/oej/adb-appleraision-1.8-mark-2/apps/app_directed_pickup.c
    team/oej/adb-appleraision-1.8-mark-2/apps/app_festival.c
    team/oej/adb-appleraision-1.8-mark-2/apps/app_followme.c
    team/oej/adb-appleraision-1.8-mark-2/apps/app_getcpeid.c
    team/oej/adb-appleraision-1.8-mark-2/apps/app_jack.c
    team/oej/adb-appleraision-1.8-mark-2/apps/app_macro.c
    team/oej/adb-appleraision-1.8-mark-2/apps/app_meetme.c
    team/oej/adb-appleraision-1.8-mark-2/apps/app_minivm.c
    team/oej/adb-appleraision-1.8-mark-2/apps/app_mixmonitor.c
    team/oej/adb-appleraision-1.8-mark-2/apps/app_osplookup.c
    team/oej/adb-appleraision-1.8-mark-2/apps/app_page.c
    team/oej/adb-appleraision-1.8-mark-2/apps/app_parkandannounce.c
    team/oej/adb-appleraision-1.8-mark-2/apps/app_playback.c
    team/oej/adb-appleraision-1.8-mark-2/apps/app_queue.c
    team/oej/adb-appleraision-1.8-mark-2/apps/app_record.c
    team/oej/adb-appleraision-1.8-mark-2/apps/app_senddtmf.c
    team/oej/adb-appleraision-1.8-mark-2/apps/app_sms.c
    team/oej/adb-appleraision-1.8-mark-2/apps/app_stack.c
    team/oej/adb-appleraision-1.8-mark-2/apps/app_voicemail.c
    team/oej/adb-appleraision-1.8-mark-2/apps/app_waitforring.c
    team/oej/adb-appleraision-1.8-mark-2/apps/app_while.c
    team/oej/adb-appleraision-1.8-mark-2/autoconf/ast_check_pwlib.m4
    team/oej/adb-appleraision-1.8-mark-2/bridges/bridge_softmix.c
    team/oej/adb-appleraision-1.8-mark-2/build_tools/make_version
    team/oej/adb-appleraision-1.8-mark-2/cel/cel_pgsql.c
    team/oej/adb-appleraision-1.8-mark-2/channels/chan_agent.c
    team/oej/adb-appleraision-1.8-mark-2/channels/chan_alsa.c
    team/oej/adb-appleraision-1.8-mark-2/channels/chan_dahdi.c
    team/oej/adb-appleraision-1.8-mark-2/channels/chan_gtalk.c
    team/oej/adb-appleraision-1.8-mark-2/channels/chan_iax2.c
    team/oej/adb-appleraision-1.8-mark-2/channels/chan_jingle.c
    team/oej/adb-appleraision-1.8-mark-2/channels/chan_local.c
    team/oej/adb-appleraision-1.8-mark-2/channels/chan_misdn.c
    team/oej/adb-appleraision-1.8-mark-2/channels/chan_oss.c
    team/oej/adb-appleraision-1.8-mark-2/channels/chan_sip.c
    team/oej/adb-appleraision-1.8-mark-2/channels/chan_skinny.c
    team/oej/adb-appleraision-1.8-mark-2/channels/chan_unistim.c
    team/oej/adb-appleraision-1.8-mark-2/channels/iax2-provision.c
    team/oej/adb-appleraision-1.8-mark-2/channels/iax2.h
    team/oej/adb-appleraision-1.8-mark-2/channels/misdn/isdn_lib.c
    team/oej/adb-appleraision-1.8-mark-2/channels/misdn/isdn_lib.h
    team/oej/adb-appleraision-1.8-mark-2/channels/misdn/isdn_msg_parser.c
    team/oej/adb-appleraision-1.8-mark-2/channels/sig_analog.c
    team/oej/adb-appleraision-1.8-mark-2/channels/sig_analog.h
    team/oej/adb-appleraision-1.8-mark-2/channels/sig_pri.c
    team/oej/adb-appleraision-1.8-mark-2/channels/sig_ss7.c
    team/oej/adb-appleraision-1.8-mark-2/channels/sip/config_parser.c
    team/oej/adb-appleraision-1.8-mark-2/channels/sip/include/reqresp_parser.h
    team/oej/adb-appleraision-1.8-mark-2/channels/sip/include/sip.h
    team/oej/adb-appleraision-1.8-mark-2/channels/sip/reqresp_parser.c
    team/oej/adb-appleraision-1.8-mark-2/channels/sip/sdp_crypto.c
    team/oej/adb-appleraision-1.8-mark-2/config.guess
    team/oej/adb-appleraision-1.8-mark-2/config.sub
    team/oej/adb-appleraision-1.8-mark-2/configure.ac
    team/oej/adb-appleraision-1.8-mark-2/funcs/func_audiohookinherit.c
    team/oej/adb-appleraision-1.8-mark-2/funcs/func_channel.c
    team/oej/adb-appleraision-1.8-mark-2/funcs/func_curl.c
    team/oej/adb-appleraision-1.8-mark-2/funcs/func_cut.c
    team/oej/adb-appleraision-1.8-mark-2/funcs/func_devstate.c
    team/oej/adb-appleraision-1.8-mark-2/funcs/func_global.c
    team/oej/adb-appleraision-1.8-mark-2/funcs/func_lock.c
    team/oej/adb-appleraision-1.8-mark-2/funcs/func_logic.c
    team/oej/adb-appleraision-1.8-mark-2/funcs/func_math.c
    team/oej/adb-appleraision-1.8-mark-2/funcs/func_odbc.c
    team/oej/adb-appleraision-1.8-mark-2/funcs/func_realtime.c
    team/oej/adb-appleraision-1.8-mark-2/funcs/func_shell.c
    team/oej/adb-appleraision-1.8-mark-2/funcs/func_strings.c
    team/oej/adb-appleraision-1.8-mark-2/funcs/func_volume.c
    team/oej/adb-appleraision-1.8-mark-2/include/asterisk/_private.h
    team/oej/adb-appleraision-1.8-mark-2/include/asterisk/astdb.h
    team/oej/adb-appleraision-1.8-mark-2/include/asterisk/astmm.h
    team/oej/adb-appleraision-1.8-mark-2/include/asterisk/astobj2.h
    team/oej/adb-appleraision-1.8-mark-2/include/asterisk/autoconfig.h.in
    team/oej/adb-appleraision-1.8-mark-2/include/asterisk/causes.h
    team/oej/adb-appleraision-1.8-mark-2/include/asterisk/channel.h
    team/oej/adb-appleraision-1.8-mark-2/include/asterisk/compat.h
    team/oej/adb-appleraision-1.8-mark-2/include/asterisk/devicestate.h
    team/oej/adb-appleraision-1.8-mark-2/include/asterisk/doxyref.h
    team/oej/adb-appleraision-1.8-mark-2/include/asterisk/event_defs.h
    team/oej/adb-appleraision-1.8-mark-2/include/asterisk/features.h
    team/oej/adb-appleraision-1.8-mark-2/include/asterisk/hashtab.h
    team/oej/adb-appleraision-1.8-mark-2/include/asterisk/linkedlists.h
    team/oej/adb-appleraision-1.8-mark-2/include/asterisk/lock.h
    team/oej/adb-appleraision-1.8-mark-2/include/asterisk/rtp_engine.h
    team/oej/adb-appleraision-1.8-mark-2/include/asterisk/strings.h
    team/oej/adb-appleraision-1.8-mark-2/include/asterisk/tcptls.h
    team/oej/adb-appleraision-1.8-mark-2/include/asterisk/time.h
    team/oej/adb-appleraision-1.8-mark-2/include/asterisk/timing.h
    team/oej/adb-appleraision-1.8-mark-2/include/asterisk/utils.h
    team/oej/adb-appleraision-1.8-mark-2/main/Makefile
    team/oej/adb-appleraision-1.8-mark-2/main/app.c
    team/oej/adb-appleraision-1.8-mark-2/main/asterisk.c
    team/oej/adb-appleraision-1.8-mark-2/main/astmm.c
    team/oej/adb-appleraision-1.8-mark-2/main/astobj2.c
    team/oej/adb-appleraision-1.8-mark-2/main/bridging.c
    team/oej/adb-appleraision-1.8-mark-2/main/ccss.c
    team/oej/adb-appleraision-1.8-mark-2/main/cdr.c
    team/oej/adb-appleraision-1.8-mark-2/main/channel.c
    team/oej/adb-appleraision-1.8-mark-2/main/cli.c
    team/oej/adb-appleraision-1.8-mark-2/main/config.c
    team/oej/adb-appleraision-1.8-mark-2/main/data.c
    team/oej/adb-appleraision-1.8-mark-2/main/db.c
    team/oej/adb-appleraision-1.8-mark-2/main/devicestate.c
    team/oej/adb-appleraision-1.8-mark-2/main/dial.c
    team/oej/adb-appleraision-1.8-mark-2/main/dsp.c
    team/oej/adb-appleraision-1.8-mark-2/main/event.c
    team/oej/adb-appleraision-1.8-mark-2/main/features.c
    team/oej/adb-appleraision-1.8-mark-2/main/frame.c
    team/oej/adb-appleraision-1.8-mark-2/main/http.c
    team/oej/adb-appleraision-1.8-mark-2/main/image.c
    team/oej/adb-appleraision-1.8-mark-2/main/indications.c
    team/oej/adb-appleraision-1.8-mark-2/main/loader.c
    team/oej/adb-appleraision-1.8-mark-2/main/manager.c
    team/oej/adb-appleraision-1.8-mark-2/main/say.c
    team/oej/adb-appleraision-1.8-mark-2/main/security_events.c
    team/oej/adb-appleraision-1.8-mark-2/main/ssl.c
    team/oej/adb-appleraision-1.8-mark-2/main/stdtime/localtime.c
    team/oej/adb-appleraision-1.8-mark-2/main/taskprocessor.c
    team/oej/adb-appleraision-1.8-mark-2/main/threadstorage.c
    team/oej/adb-appleraision-1.8-mark-2/main/timing.c
    team/oej/adb-appleraision-1.8-mark-2/main/udptl.c
    team/oej/adb-appleraision-1.8-mark-2/main/utils.c
    team/oej/adb-appleraision-1.8-mark-2/pbx/pbx_ael.c
    team/oej/adb-appleraision-1.8-mark-2/pbx/pbx_config.c
    team/oej/adb-appleraision-1.8-mark-2/pbx/pbx_dundi.c
    team/oej/adb-appleraision-1.8-mark-2/pbx/pbx_lua.c
    team/oej/adb-appleraision-1.8-mark-2/pbx/pbx_realtime.c
    team/oej/adb-appleraision-1.8-mark-2/pbx/pbx_spool.c
    team/oej/adb-appleraision-1.8-mark-2/sounds/Makefile
    team/oej/adb-appleraision-1.8-mark-2/tests/test_db.c
    team/oej/adb-appleraision-1.8-mark-2/tests/test_linkedlists.c

Propchange: team/oej/adb-appleraision-1.8-mark-2/
------------------------------------------------------------------------------
    automerge = Is-there-life-off-net?

Propchange: team/oej/adb-appleraision-1.8-mark-2/
            ('svnmerge-integrated' removed)

Modified: team/oej/adb-appleraision-1.8-mark-2/CHANGES
URL: http://svnview.digium.com/svn/asterisk/team/oej/adb-appleraision-1.8-mark-2/CHANGES?view=diff&rev=403147&r1=403146&r2=403147
==============================================================================
--- team/oej/adb-appleraision-1.8-mark-2/CHANGES (original)
+++ team/oej/adb-appleraision-1.8-mark-2/CHANGES Mon Nov 25 04:53:54 2013
@@ -7,6 +7,18 @@
 === and the other UPGRADE files for older releases.
 ===
 ======================================================================
+
+------------------------------------------------------------------------------
+--- Functionality changes since Asterisk 1.8.12.0 ----------------------------
+------------------------------------------------------------------------------
+
+Build System
+------------
+ * The optimization portion of the build system has been reworked to avoid
+   broken builds on certain architectures.  All architecture-specific
+   optimization has been removed in favor of using -march=native to allow gcc
+   to detect the environment in which it is running when possible.  This can
+   be toggled as BUILD_NATIVE under "Compiler Flags" in menuselect.
 
 ------------------------------------------------------------------------------
 --- Functionality changes since Asterisk 1.8.10.0 ----------------------------
@@ -621,6 +633,9 @@
    rate changes during translation are now avoided unless absolutely necessary.
  * The addition of the res_stun_monitor module for monitoring and reacting to network
    changes while behind a NAT.
+ * DTMF: Normal and Reverse Twist acceptance values can be set in dsp.conf.
+   DTMF Valid/Invalid number of hits/misses can be set in dsp.conf.
+   These allow support for any Administration. Default is AT&T values.
 
 CLI Changes
 -----------

Modified: team/oej/adb-appleraision-1.8-mark-2/Makefile
URL: http://svnview.digium.com/svn/asterisk/team/oej/adb-appleraision-1.8-mark-2/Makefile?view=diff&rev=403147&r1=403146&r2=403147
==============================================================================
--- team/oej/adb-appleraision-1.8-mark-2/Makefile (original)
+++ team/oej/adb-appleraision-1.8-mark-2/Makefile Mon Nov 25 04:53:54 2013
@@ -204,7 +204,7 @@
   _ASTCFLAGS+=-Wcast-align -DSOLARIS -I../include/solaris-compat -I/opt/ssl/include -I/usr/local/ssl/include -D_XPG4_2 -D__EXTENSIONS__
 endif
 
-ASTERISKVERSION:=$(shell GREP=$(GREP) AWK=$(AWK) build_tools/make_version .)
+ASTERISKVERSION:=$(shell GREP=$(GREP) AWK=$(AWK) GIT=$(GIT) build_tools/make_version .)
 
 ifneq ($(wildcard .version),)
   ASTERISKVERSIONNUM:=$(shell $(AWK) -F. '{printf "%01d%02d%02d", $$1, $$2, $$3}' .version)

Modified: team/oej/adb-appleraision-1.8-mark-2/Makefile.rules
URL: http://svnview.digium.com/svn/asterisk/team/oej/adb-appleraision-1.8-mark-2/Makefile.rules?view=diff&rev=403147&r1=403146&r2=403147
==============================================================================
--- team/oej/adb-appleraision-1.8-mark-2/Makefile.rules (original)
+++ team/oej/adb-appleraision-1.8-mark-2/Makefile.rules Mon Nov 25 04:53:54 2013
@@ -37,6 +37,7 @@
 
 OPTIMIZE?=-O6
 ifneq ($(findstring darwin,$(OSARCH)),)
+  OPTIMIZE=-O4
   ifeq ($(shell if test `/usr/bin/sw_vers -productVersion | cut -c4` -gt 5; then echo 6; else echo 0; fi),6)
     # Snow Leopard/Lion has an issue with this optimization flag on large files (like chan_sip)
     OPTIMIZE+=-fno-inline-functions

Modified: team/oej/adb-appleraision-1.8-mark-2/README-SERIOUSLY.bestpractices.txt
URL: http://svnview.digium.com/svn/asterisk/team/oej/adb-appleraision-1.8-mark-2/README-SERIOUSLY.bestpractices.txt?view=diff&rev=403147&r1=403146&r2=403147
==============================================================================
--- team/oej/adb-appleraision-1.8-mark-2/README-SERIOUSLY.bestpractices.txt (original)
+++ team/oej/adb-appleraision-1.8-mark-2/README-SERIOUSLY.bestpractices.txt Mon Nov 25 04:53:54 2013
@@ -22,6 +22,9 @@
 
 * Reducing Pattern Match Typos: 
         Using the 'same' prefix, or using Goto()
+
+* Manager Class Authorizations:
+        Recognizing potential issues with certain classes of authorization
 
 ----------------
 Additional Links
@@ -293,3 +296,51 @@
 exten => error,1,Verbose(2,Unable to lookup technology or device for extension)
 same => n,Playback(silence/1&num-not-in-db)
 same => n,Hangup()
+
+
+============================
+Manager Class Authorizations
+============================
+
+Manager accounts have associated class authorizations that define what actions
+and events that account can execute/receive.  In order to run Asterisk commands
+or dialplan applications that affect the system Asterisk executes on, the
+"system" class authorization should be set on the account.
+
+However, Manager commands that originate new calls into the Asterisk dialplan
+have the potential to alter or affect the system as well, even though the
+class authorization for origination commands is "originate".  Take, for example,
+the Originate manager command:
+
+Action: Originate
+Channel: SIP/foo
+Exten: s
+Context: default
+Priority: 1
+Application: System
+Data: echo hello world!
+
+This manager command will attempt to execute an Asterisk application, System,
+which is normally associated with the "system" class authorication.  While some
+checks have been put into Asterisk to take this into account, certain dialplan
+configurations and/or clever manipulation of the Originate manager action can
+circumvent these checks.  For example, take the following dialplan:
+
+exten => s,1,Verbose(Incoming call)
+same => n,MixMonitor(foo.wav,,${EXEC_COMMAND})
+same => n,Dial(SIP/bar)
+same => n,Hangup()
+
+Whatever has been defined in the variable EXEC_COMMAND will be executed after
+MixMonitor has finished recording the call.  The dialplan writer may have
+intended that this variable to be set by some other location in the dialplan;
+however, the Manager action Originate allows for channel variables to be set by
+the account initiating the new call.  This could allow the Originate action to
+execute some command on the system by setting the EXEC_COMMAND dialplan variable
+in the Variable: header.
+
+In general, you should treat the Manager class authorization "originate" the
+same as the class authorization "system".  Good system configuration, such as
+not running Asterisk as root, can prevent serious problems from arising when
+allowing external connections to originate calls into Asterisk.
+

Modified: team/oej/adb-appleraision-1.8-mark-2/UPGRADE.txt
URL: http://svnview.digium.com/svn/asterisk/team/oej/adb-appleraision-1.8-mark-2/UPGRADE.txt?view=diff&rev=403147&r1=403146&r2=403147
==============================================================================
--- team/oej/adb-appleraision-1.8-mark-2/UPGRADE.txt (original)
+++ team/oej/adb-appleraision-1.8-mark-2/UPGRADE.txt Mon Nov 25 04:53:54 2013
@@ -18,6 +18,46 @@
 ===
 ===========================================================
 
+from 1.8.21.0 to 1.8.22.0:
+* Added the 'n' option to MeetMe to prevent application of the DENOISE function
+  to a channel joining a conference. Some channel drivers that vary the number
+  of audio samples in a voice frame will experience significant quality problems
+  if a denoiser is attached to the channel; this option gives them the ability
+  to remove the denoiser without having to unload func_speex.
+
+* The Registry AMI event for SIP registrations will now always include the
+  Username field. A previous bug fix missed an instance where it was not
+  included; that has been corrected in this release.
+
+from 1.8.20.0 to 1.8.20.1:
+* Asterisk would previously not output certain error messages when a remote
+  console attempted to connect to Asterisk and no instance of Asterisk was
+  running. This error message is displayed on stderr; as a result, some
+  initialization scripts that used remote consoles to test for the presence
+  of a running Asterisk instance started to display erroneous error messages.
+  The init.d scripts and the safe_asterisk have been updated in the contrib
+  folder to account for this.
+
+from 1.8.19 to 1.8.20:
+* Asterisk has always had code to ignore dash '-' characters that are not
+  part of a character set in the dialplan extensions.  The code now
+  consistently ignores these characters when matching dialplan extensions.
+
+from 1.8.18 to 1.8.19:
+* Queue strategy rrmemory now has a predictable order similar to strategy
+  rrordered. Members will be called in the order that they are added to the
+  queue.
+
+From 1.8.13 to 1.8.14:
+* permitdirectmedia/denydirectmedia now controls whether peers can be
+  bridged via directmedia by comparing the ACL to the bridging peer's
+  address rather than its own address.
+
+From 1.8.12 to 1.8.13:
+* The complex processor detection and optimization has been removed from
+  the makefile in favor of using native optimization suppport when available.
+  BUILD_NATIVE can be disabled via menuselect under "Compiler Flags".
+
 From 1.8.11 to 1.8.12:
 * In AEL dialplans, the "h" extension will now be inherited from prior
   calling contexts, just as it had in 1.4.  If you have created an AEL

Modified: team/oej/adb-appleraision-1.8-mark-2/addons/app_mysql.c
URL: http://svnview.digium.com/svn/asterisk/team/oej/adb-appleraision-1.8-mark-2/addons/app_mysql.c?view=diff&rev=403147&r1=403146&r2=403147
==============================================================================
--- team/oej/adb-appleraision-1.8-mark-2/addons/app_mysql.c (original)
+++ team/oej/adb-appleraision-1.8-mark-2/addons/app_mysql.c Mon Nov 25 04:53:54 2013
@@ -106,7 +106,7 @@
 static void mysql_ds_destroy(void *data);
 static void mysql_ds_fixup(void *data, struct ast_channel *oldchan, struct ast_channel *newchan);
 
-static struct ast_datastore_info mysql_ds_info = {
+static const struct ast_datastore_info mysql_ds_info = {
 	.type = "APP_ADDON_SQL_MYSQL",
 	.destroy = mysql_ds_destroy,
 	.chan_fixup = mysql_ds_fixup,
@@ -295,7 +295,7 @@
 	AST_NONSTANDARD_APP_ARGS(args, data, ' ');
 
 	if (args.argc == 3) {
-		var = alloca(6 + strlen(args.variable) + 1);
+		var = ast_alloca(6 + strlen(args.variable) + 1);
 		sprintf(var, "MYSQL_%s", args.variable);
 
 		/* Make the parameter case-insensitive */

Modified: team/oej/adb-appleraision-1.8-mark-2/addons/cdr_mysql.c
URL: http://svnview.digium.com/svn/asterisk/team/oej/adb-appleraision-1.8-mark-2/addons/cdr_mysql.c?view=diff&rev=403147&r1=403146&r2=403147
==============================================================================
--- team/oej/adb-appleraision-1.8-mark-2/addons/cdr_mysql.c (original)
+++ team/oej/adb-appleraision-1.8-mark-2/addons/cdr_mysql.c Mon Nov 25 04:53:54 2013
@@ -430,6 +430,9 @@
 	int res;
 	struct ast_config *cfg;
 	struct ast_variable *var;
+	/* CONFIG_STATUS_FILEUNCHANGED is impossible when config_flags is always 0,
+	 * and it has to be zero, so a reload can be sent to tell the driver to
+	 * rescan the table layout. */
 	struct ast_flags config_flags = { 0 };
 	struct column *entry;
 	char *temp;
@@ -445,11 +448,13 @@
 	 * 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) {
+	if (cfg == CONFIG_STATUS_FILEMISSING) {
 		ast_log(LOG_WARNING, "Unable to load config for mysql CDR's: %s\n", config);
 		return AST_MODULE_LOAD_SUCCESS;
-	} else if (cfg == CONFIG_STATUS_FILEUNCHANGED)
-		return AST_MODULE_LOAD_SUCCESS;
+	} else if (cfg == CONFIG_STATUS_FILEINVALID) {
+		ast_log(LOG_ERROR, "Unable to load configuration file '%s'\n", config);
+		return AST_MODULE_LOAD_DECLINE;
+	}
 
 	if (reload) {
 		AST_RWLIST_WRLOCK(&columns);

Modified: team/oej/adb-appleraision-1.8-mark-2/addons/chan_mobile.c
URL: http://svnview.digium.com/svn/asterisk/team/oej/adb-appleraision-1.8-mark-2/addons/chan_mobile.c?view=diff&rev=403147&r1=403146&r2=403147
==============================================================================
--- team/oej/adb-appleraision-1.8-mark-2/addons/chan_mobile.c (original)
+++ team/oej/adb-appleraision-1.8-mark-2/addons/chan_mobile.c Mon Nov 25 04:53:54 2013
@@ -558,7 +558,7 @@
 	max_rsp = 255;
 	flags = IREQ_CACHE_FLUSH;
 
-	ii = alloca(max_rsp * sizeof(inquiry_info));
+	ii = ast_alloca(max_rsp * sizeof(inquiry_info));
 	num_rsp = hci_inquiry(adapter->dev_id, len, max_rsp, NULL, &ii, flags);
 	if (num_rsp > 0) {
 		ast_cli(a->fd, FORMAT1, "Address", "Name", "Usable", "Type", "Port");
@@ -1371,7 +1371,7 @@
 	memset(&addr, 0, sizeof(addr));
 	addr.rc_family = AF_BLUETOOTH;
 	bacpy(&addr.rc_bdaddr, &src);
-	addr.rc_channel = (uint8_t) 1;
+	addr.rc_channel = (uint8_t) 0;
 	if (bind(s, (struct sockaddr *)&addr, sizeof(addr)) < 0) {
 		ast_debug(1, "bind() failed (%d).\n", errno);
 		close(s);
@@ -2233,6 +2233,7 @@
 			if (buf[i] == '"') {
 				state++;
 			}
+			break;
 		case 2: /* mark the start of the number */
 			if (from_number) {
 				*from_number = &buf[i];

Modified: team/oej/adb-appleraision-1.8-mark-2/addons/chan_ooh323.c
URL: http://svnview.digium.com/svn/asterisk/team/oej/adb-appleraision-1.8-mark-2/addons/chan_ooh323.c?view=diff&rev=403147&r1=403146&r2=403147
==============================================================================
--- team/oej/adb-appleraision-1.8-mark-2/addons/chan_ooh323.c (original)
+++ team/oej/adb-appleraision-1.8-mark-2/addons/chan_ooh323.c Mon Nov 25 04:53:54 2013
@@ -1245,13 +1245,11 @@
 	case AST_CONTROL_CONGESTION:
 		if (!ast_test_flag(p, H323_ALREADYGONE)) {
 			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);
-			ast_set_flag(p, H323_ALREADYGONE);
 		}
 		break;
 	case AST_CONTROL_HOLD:

Modified: team/oej/adb-appleraision-1.8-mark-2/addons/ooh323c/src/ooGkClient.c
URL: http://svnview.digium.com/svn/asterisk/team/oej/adb-appleraision-1.8-mark-2/addons/ooh323c/src/ooGkClient.c?view=diff&rev=403147&r1=403146&r2=403147
==============================================================================
--- team/oej/adb-appleraision-1.8-mark-2/addons/ooh323c/src/ooGkClient.c (original)
+++ team/oej/adb-appleraision-1.8-mark-2/addons/ooh323c/src/ooGkClient.c Mon Nov 25 04:53:54 2013
@@ -809,6 +809,9 @@
    if(pGatekeeperConfirm->m.gatekeeperIdentifierPresent) 
    {
       pGkClient->gkId.nchars = pGatekeeperConfirm->gatekeeperIdentifier.nchars;
+      if (pGkClient->gkId.data) {
+         memFreePtr(&pGkClient->ctxt, pGkClient->gkId.data);
+      }
       pGkClient->gkId.data = (ASN116BITCHAR*)memAlloc(&pGkClient->ctxt,
                               sizeof(ASN116BITCHAR)*pGkClient->gkId.nchars);
       if(!pGkClient->gkId.data)
@@ -1279,6 +1282,8 @@
    unsigned int x=0;
    DListNode *pNode = NULL;
    OOTimer *pTimer = NULL;
+   ooGkClientTimerCb *cbData=NULL;
+
    /* First delete the corresponding RRQ timer */
    for(x=0; x<pGkClient->timerList.count; x++)
    {
@@ -1368,8 +1373,40 @@
    default:
       OOTRACEINFO1("RRQ Rejected - Invalid Reason\n");
    }
-   pGkClient->state = GkClientGkErr;
+
+   /* send again GRQ/RRQ's */
+   ast_mutex_lock(&pGkClient->Lock);
+   pGkClient->state = GkClientUnregistered;
+   pGkClient->rrqRetries = 0;
+   pGkClient->grqRetries = 0;
+   pGkClient->discoveryComplete = FALSE;
+
+   cbData = (ooGkClientTimerCb*) memAlloc
+                               (&pGkClient->ctxt, sizeof(ooGkClientTimerCb));
+   if(!cbData)
+   {
+      OOTRACEERR1("Error:Failed to allocate memory to GRQ timer callback\n");
+      pGkClient->state = GkClientFailed;
+      ast_mutex_unlock(&pGkClient->Lock);
+      return OO_FAILED;
+   }
+   cbData->timerType = OO_GRQ_TIMER;
+   cbData->pGkClient = pGkClient;
+   if(!ooTimerCreate(&pGkClient->ctxt, &pGkClient->timerList,
+                     &ooGkClientGRQTimerExpired, pGkClient->grqTimeout,
+                     cbData, FALSE))
+   {
+      OOTRACEERR1("Error:Unable to create GRQ timer.\n ");
+      memFreePtr(&pGkClient->ctxt, cbData);
+      pGkClient->state = GkClientFailed;
+      ast_mutex_unlock(&pGkClient->Lock);
+      return OO_FAILED;
+   }
+
+   ast_mutex_unlock(&pGkClient->Lock);
+
    return OO_OK;
+
 }
 
 

Modified: team/oej/adb-appleraision-1.8-mark-2/addons/ooh323c/src/ooh323ep.c
URL: http://svnview.digium.com/svn/asterisk/team/oej/adb-appleraision-1.8-mark-2/addons/ooh323c/src/ooh323ep.c?view=diff&rev=403147&r1=403146&r2=403147
==============================================================================
--- team/oej/adb-appleraision-1.8-mark-2/addons/ooh323c/src/ooh323ep.c (original)
+++ team/oej/adb-appleraision-1.8-mark-2/addons/ooh323c/src/ooh323ep.c Mon Nov 25 04:53:54 2013
@@ -56,7 +56,7 @@
       strcpy(gH323ep.traceFile, DEFAULT_TRACEFILE);      
    }
 
-   gH323ep.fptraceFile = fopen(gH323ep.traceFile, "w");
+   gH323ep.fptraceFile = fopen(gH323ep.traceFile, "a");
    if(gH323ep.fptraceFile == NULL)
    {
       printf("Error:Failed to open trace file %s for write.\n", 

Modified: team/oej/adb-appleraision-1.8-mark-2/addons/res_config_mysql.c
URL: http://svnview.digium.com/svn/asterisk/team/oej/adb-appleraision-1.8-mark-2/addons/res_config_mysql.c?view=diff&rev=403147&r1=403146&r2=403147
==============================================================================
--- team/oej/adb-appleraision-1.8-mark-2/addons/res_config_mysql.c (original)
+++ team/oej/adb-appleraision-1.8-mark-2/addons/res_config_mysql.c Mon Nov 25 04:53:54 2013
@@ -144,7 +144,7 @@
 		if (for_write) {
 			whichdb = ast_strdupa(ptr + 1);
 		} else {
-			whichdb = alloca(ptr - database + 1);
+			whichdb = ast_alloca(ptr - database + 1);
 			strncpy(whichdb, database, ptr - database);
 			whichdb[ptr - database] = '\0';
 		}
@@ -343,9 +343,7 @@
 	}
 
 	/* Get the first parameter and first value in our list of passed paramater/value pairs */
-	newparam = va_arg(ap, const char *);
-	newval = va_arg(ap, const char *);
-	if (!newparam || !newval)  {
+	if (!(newparam = va_arg(ap, const char *)) || !(newval = va_arg(ap, const char *)))  {
 		ast_log(LOG_WARNING, "MySQL RealTime: Realtime retrieval requires at least 1 parameter and 1 value to search on.\n");
 		release_database(dbh);
 		return NULL;
@@ -376,7 +374,6 @@
 		ESCAPE_STRING(buf, newval);
 		ast_str_append(&sql, 0, " AND %s%s '%s'", newparam, op, ast_str_buffer(buf));
 	}
-	va_end(ap);
 
 	ast_debug(1, "MySQL RealTime: Retrieve SQL: %s\n", ast_str_buffer(sql));
 
@@ -457,9 +454,7 @@
 	}
 
 	/* Get the first parameter and first value in our list of passed paramater/value pairs */
-	newparam = va_arg(ap, const char *);
-	newval = va_arg(ap, const char *);
-	if (!newparam || !newval)  {
+	if (!(newparam = va_arg(ap, const char *)) || !(newval = va_arg(ap, const char *)))  {
 		ast_log(LOG_WARNING, "MySQL RealTime: Realtime retrieval requires at least 1 parameter and 1 value to search on.\n");
 		ast_config_destroy(cfg);
 		release_database(dbh);
@@ -467,7 +462,7 @@
 	}
 
 	initfield = ast_strdupa(newparam);
-	if (initfield && (op = strchr(initfield, ' '))) {
+	if ((op = strchr(initfield, ' '))) {
 		*op = '\0';
 	}
 
@@ -498,8 +493,6 @@
 	if (initfield) {
 		ast_str_append(&sql, 0, " ORDER BY %s", initfield);
 	}
-
-	va_end(ap);
 
 	ast_debug(1, "MySQL RealTime: Retrieve SQL: %s\n", ast_str_buffer(sql));
 
@@ -581,9 +574,7 @@
 	}
 
 	/* Get the first parameter and first value in our list of passed paramater/value pairs */
-	newparam = va_arg(ap, const char *);
-	newval = va_arg(ap, const char *);
-	if (!newparam || !newval)  {
+	if (!(newparam = va_arg(ap, const char *)) || !(newval = va_arg(ap, const char *)))  {
 		ast_log(LOG_WARNING, "MySQL RealTime: Realtime update requires at least 1 parameter and 1 value to update.\n");
 		release_table(table);
 		release_database(dbh);
@@ -633,7 +624,6 @@
 			internal_require(database, tablename, newparam, RQ_CHAR, ast_str_strlen(buf), SENTINEL);
 		}
 	}
-	va_end(ap);
 
 	ESCAPE_STRING(buf, lookup);
 	ast_str_append(&sql, 0, " WHERE `%s` = '%s'", keyfield, ast_str_buffer(buf));
@@ -667,7 +657,7 @@
 {
 	struct mysql_conn *dbh;
 	my_ulonglong numrows;
-	int first = 1;
+	int first;
 	const char *newparam, *newval;
 	struct ast_str *sql = ast_str_thread_get(&sql_buf, 100), *buf = ast_str_thread_get(&scratch_buf, 100);
 	struct ast_str *where = ast_str_thread_get(&sql2_buf, 100);
@@ -706,6 +696,7 @@
 		return -1;
 	}
 
+	first = 1;
 	while ((newparam = va_arg(ap, const char *))) {
 		if (!(column = find_column(table, newparam))) {
 			ast_log(LOG_ERROR, "Updating on column '%s', but that column does not exist within the table '%s'!\n", newparam, tablename);
@@ -753,7 +744,7 @@
 			internal_require(database, tablename, newparam, RQ_CHAR, ast_str_strlen(buf), SENTINEL);
 		}
 	}
-	va_end(ap);
+
 	release_table(table);
 
 	ast_str_append(&sql, 0, " %s", ast_str_buffer(where));
@@ -802,9 +793,7 @@
 		return -1;
 	}
 	/* Get the first parameter and first value in our list of passed paramater/value pairs */
-	newparam = va_arg(ap, const char *);
-	newval = va_arg(ap, const char *);
-	if (!newparam || !newval)  {
+	if (!(newparam = va_arg(ap, const char *)) || !(newval = va_arg(ap, const char *))) {
 		ast_log(LOG_WARNING, "MySQL RealTime: Realtime storage requires at least 1 parameter and 1 value to search on.\n");
 		release_database(dbh);
 		return -1;
@@ -833,7 +822,6 @@
 			ast_str_append(&sql2, 0, ", '%s'", ast_str_buffer(buf));
 		}
 	}
-	va_end(ap);
 	ast_str_append(&sql, 0, "%s)", ast_str_buffer(sql2));
 	ast_debug(1,"MySQL RealTime: Insert SQL: %s\n", ast_str_buffer(sql));
 
@@ -901,7 +889,6 @@
 		ESCAPE_STRING(buf, newval);
 		ast_str_append(&sql, 0, " AND `%s` = '%s'", newparam, ast_str_buffer(buf));
 	}
-	va_end(ap);
 
 	ast_debug(1, "MySQL RealTime: Delete SQL: %s\n", ast_str_buffer(sql));
 
@@ -950,7 +937,7 @@
 		return NULL;
 	}
 
-	ast_str_set(&sql, 0, "SELECT category, var_name, var_val, cat_metric FROM %s WHERE filename='%s' and commented=0 ORDER BY filename, cat_metric desc, var_metric asc, category, var_name, var_val, id", table, file);
+	ast_str_set(&sql, 0, "SELECT category, var_name, var_val, cat_metric FROM %s WHERE filename='%s' and commented=0 ORDER BY filename, category, cat_metric desc, var_metric asc, var_name, var_val, id", table, file);
 
 	ast_debug(1, "MySQL RealTime: Static SQL: %s\n", ast_str_buffer(sql));
 
@@ -1395,9 +1382,6 @@
 	if (option_verbose > 1)
 		ast_verbose(VERBOSE_PREFIX_2 "MySQL RealTime unloaded.\n");
 
-	ast_module_user_hangup_all();
-
-	usleep(1);
 	AST_RWLIST_WRLOCK(&databases);
 	while ((cur = AST_RWLIST_REMOVE_HEAD(&databases, list))) {
 		mysql_close(&cur->handle);

Modified: team/oej/adb-appleraision-1.8-mark-2/apps/app_celgenuserevent.c
URL: http://svnview.digium.com/svn/asterisk/team/oej/adb-appleraision-1.8-mark-2/apps/app_celgenuserevent.c?view=diff&rev=403147&r1=403146&r2=403147
==============================================================================
--- team/oej/adb-appleraision-1.8-mark-2/apps/app_celgenuserevent.c (original)
+++ team/oej/adb-appleraision-1.8-mark-2/apps/app_celgenuserevent.c Mon Nov 25 04:53:54 2013
@@ -80,13 +80,8 @@
 
 static int unload_module(void)
 {
-	int res;
-
-	res = ast_unregister_application(app);
-
-	ast_module_user_hangup_all();
-
-	return res;
+	ast_unregister_application(app);
+	return 0;
 }
 
 static int load_module(void)

Modified: team/oej/adb-appleraision-1.8-mark-2/apps/app_chanspy.c
URL: http://svnview.digium.com/svn/asterisk/team/oej/adb-appleraision-1.8-mark-2/apps/app_chanspy.c?view=diff&rev=403147&r1=403146&r2=403147
==============================================================================
--- team/oej/adb-appleraision-1.8-mark-2/apps/app_chanspy.c (original)
+++ team/oej/adb-appleraision-1.8-mark-2/apps/app_chanspy.c Mon Nov 25 04:53:54 2013
@@ -1020,6 +1020,7 @@
 					}
 				}
 			} else if (res == 0 && ast_test_flag(flags, OPTION_EXITONHANGUP)) {
+				ast_autochan_destroy(autochan);
 				iter = ast_channel_iterator_destroy(iter);
 				goto exit;
 			}

Modified: team/oej/adb-appleraision-1.8-mark-2/apps/app_confbridge.c
URL: http://svnview.digium.com/svn/asterisk/team/oej/adb-appleraision-1.8-mark-2/apps/app_confbridge.c?view=diff&rev=403147&r1=403146&r2=403147
==============================================================================
--- team/oej/adb-appleraision-1.8-mark-2/apps/app_confbridge.c (original)
+++ team/oej/adb-appleraision-1.8-mark-2/apps/app_confbridge.c Mon Nov 25 04:53:54 2013
@@ -486,7 +486,7 @@
 
 	/* Set the device state for this conference */
 	if (conference_bridge->users == 1) {
-		ast_devstate_changed(AST_DEVICE_INUSE, "confbridge:%s", conference_bridge->name);
+		ast_devstate_changed(AST_DEVICE_INUSE, AST_DEVSTATE_CACHABLE, "confbridge:%s", conference_bridge->name);
 	}
 
 	/* If the caller is a marked user or is waiting for a marked user to enter pass 'em off, otherwise pass them off to do regular joining stuff */
@@ -568,7 +568,7 @@
 		}
 	} else {
 		/* Set device state to "not in use" */
-		ast_devstate_changed(AST_DEVICE_NOT_INUSE, "confbridge:%s", conference_bridge->name);
+		ast_devstate_changed(AST_DEVICE_NOT_INUSE, AST_DEVSTATE_CACHABLE, "confbridge:%s", conference_bridge->name);
 
 		ao2_unlink(conference_bridges, conference_bridge);
 	}

Modified: team/oej/adb-appleraision-1.8-mark-2/apps/app_db.c
URL: http://svnview.digium.com/svn/asterisk/team/oej/adb-appleraision-1.8-mark-2/apps/app_db.c?view=diff&rev=403147&r1=403146&r2=403147
==============================================================================
--- team/oej/adb-appleraision-1.8-mark-2/apps/app_db.c (original)
+++ team/oej/adb-appleraision-1.8-mark-2/apps/app_db.c Mon Nov 25 04:53:54 2013
@@ -106,13 +106,15 @@
 		keytree = 0;
 	}
 
-	if (keytree)
+	if (keytree) {
 		ast_verb(3, "DBdeltree: family=%s, keytree=%s\n", family, keytree);
-	else
+	} else {
 		ast_verb(3, "DBdeltree: family=%s\n", family);
+	}
 
-	if (ast_db_deltree(family, keytree))
+	if (ast_db_deltree(family, keytree) < 0) {
 		ast_verb(3, "DBdeltree: Error deleting key from database.\n");
+	}
 
 	return 0;
 }

Modified: team/oej/adb-appleraision-1.8-mark-2/apps/app_dial.c
URL: http://svnview.digium.com/svn/asterisk/team/oej/adb-appleraision-1.8-mark-2/apps/app_dial.c?view=diff&rev=403147&r1=403146&r2=403147
==============================================================================
--- team/oej/adb-appleraision-1.8-mark-2/apps/app_dial.c (original)
+++ team/oej/adb-appleraision-1.8-mark-2/apps/app_dial.c Mon Nov 25 04:53:54 2013
@@ -672,7 +672,7 @@
 	struct ast_aoc_decoded *aoc_s_rate_list;
 };
 
-static int detect_disconnect(struct ast_channel *chan, char code, struct ast_str *featurecode);
+static int detect_disconnect(struct ast_channel *chan, char code, struct ast_str **featurecode);
 
 static void chanlist_free(struct chanlist *outgoing)
 {
@@ -1055,6 +1055,7 @@
 	int is_cc_recall;
 	int cc_frame_received = 0;
 	int num_ringing = 0;
+	struct timeval start = ast_tvnow();
 
 	ast_party_connected_line_init(&connected_caller);
 	if (single) {
@@ -1095,7 +1096,7 @@
 		ast_poll_channel_add(in, epollo->chan);
 #endif
 
-	while (*to && !peer) {
+	while ((*to = ast_remaining_ms(start, orig)) && !peer) {
 		struct chanlist *o;
 		int pos = 0; /* how many channels do we handle */
 		int numlines = prestart;
@@ -1532,7 +1533,7 @@
 				}
 
 				if (ast_test_flag64(peerflags, OPT_CALLER_HANGUP) &&
-					detect_disconnect(in, f->subclass.integer, featurecode)) {
+					detect_disconnect(in, f->subclass.integer, &featurecode)) {
 					ast_verb(3, "User requested call disconnect.\n");
 					*to = 0;
 					strcpy(pa->status, "CANCEL");
@@ -1626,10 +1627,13 @@
 skip_frame:;
 			ast_frfree(f);
 		}
-		if (!*to)
-			ast_verb(3, "Nobody picked up in %d ms\n", orig);
-		if (!*to || ast_check_hangup(in))
-			ast_cdr_noanswer(in->cdr);
+	}
+
+	if (!*to) {
+		ast_verb(3, "Nobody picked up in %d ms\n", orig);
+	}
+	if (!*to || ast_check_hangup(in)) {
+		ast_cdr_noanswer(in->cdr);
 	}
 
 #ifdef HAVE_EPOLL
@@ -1645,18 +1649,18 @@
 	return peer;
 }
 
-static int detect_disconnect(struct ast_channel *chan, char code, struct ast_str *featurecode)
+static int detect_disconnect(struct ast_channel *chan, char code, struct ast_str **featurecode)
 {
 	struct ast_flags features = { AST_FEATURE_DISCONNECT }; /* only concerned with disconnect feature */
 	struct ast_call_feature feature = { 0, };
 	int res;
 
-	ast_str_append(&featurecode, 1, "%c", code);
-
-	res = ast_feature_detect(chan, &features, ast_str_buffer(featurecode), &feature);
+	ast_str_append(featurecode, 1, "%c", code);
+
+	res = ast_feature_detect(chan, &features, ast_str_buffer(*featurecode), &feature);
 
 	if (res != AST_FEATURE_RETURN_STOREDIGITS) {
-		ast_str_reset(featurecode);
+		ast_str_reset(*featurecode);
 	}
 	if (feature.feature_mask & AST_FEATURE_DISCONNECT) {
 		return 1;
@@ -2795,8 +2799,7 @@
 						 ast_exists_extension(peer, opt_args[OPT_ARG_CALLEE_GOSUB], "~~s~~", 1, S_COR(peer->caller.id.number.valid, peer->caller.id.number.str, NULL))) {
 						what_is_s = "~~s~~";
 					}
-					if (asprintf(&gosub_args, "%s,%s,1(%s)", opt_args[OPT_ARG_CALLEE_GOSUB], what_is_s, gosub_argstart + 1) < 0) {
-						ast_log(LOG_WARNING, "asprintf() failed: %s\n", strerror(errno));
+					if (ast_asprintf(&gosub_args, "%s,%s,1(%s)", opt_args[OPT_ARG_CALLEE_GOSUB], what_is_s, gosub_argstart + 1) < 0) {
 						gosub_args = NULL;
 					}
 					*gosub_argstart = ',';
@@ -2806,8 +2809,7 @@
 						 ast_exists_extension(peer, opt_args[OPT_ARG_CALLEE_GOSUB], "~~s~~", 1, S_COR(peer->caller.id.number.valid, peer->caller.id.number.str, NULL))) {
 						what_is_s = "~~s~~";
 					}

[... 22894 lines stripped ...]



More information about the asterisk-commits mailing list