[asterisk-commits] may: branch may/ooh323_qsig r378196 - in /team/may/ooh323_qsig: ./ apps/ apps...

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Fri Dec 21 15:44:32 CST 2012


Author: may
Date: Fri Dec 21 15:44:16 2012
New Revision: 378196

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=378196
Log:
Multiple revisions 377841,377844,377846,377867,377878,377880,377884,377906,377911,377915,377925,377966,377971-377975,377977,377981,377986,377994,378000-378002,378006,378011,378029,378039,378063-378064,378072,378074,378081,378091,378095,378122,378166

........
  r377841 | rmudgett | 2012-12-12 00:46:23 +0400 (Wed, 12 Dec 2012) | 20 lines
  
  Cleanup taskprocessor on exit.
  
  * Cleanup CLI commands on exit.
  
  (issue ASTERISK-20649)
  Reported by: Corey Farrell
  Patches:
        taskprocessor-cleanup-1_8-11-trunk.patch (license #5909) patch uploaded by Corey Farrell
        taskprocessor-cleanup-10-only.patch (license #5909) patch uploaded by Corey Farrell
        Modified
  ........
  
  Merged revisions 377837 from http://svn.asterisk.org/svn/asterisk/branches/1.8
  ........
  
  Merged revisions 377838 from http://svn.asterisk.org/svn/asterisk/branches/10
  ........
  
  Merged revisions 377839 from http://svn.asterisk.org/svn/asterisk/branches/11
........
  r377844 | mmichelson | 2012-12-12 00:53:34 +0400 (Wed, 12 Dec 2012) | 19 lines
  
  Fix crash that can occur if CLI registration fails for an aliased command.
  
  A recent memory leak fix in main/cli.c causes an ast_cli_entry's command
  field to be freed and NULLed if ast_cli_register() fails. res_clialiases
  was ignoring the return value of ast_cli_register() and was then passing
  the NULL command off to a a hash function. This resulted in a crash.
  
  The fix is not to ignore the erroneous return value. If ast_cli_register()
  fails, then we do not continue trying to process the current alias.
  ........
  
  Merged revisions 377840 from http://svn.asterisk.org/svn/asterisk/branches/1.8
  ........
  
  Merged revisions 377842 from http://svn.asterisk.org/svn/asterisk/branches/10
  ........
  
  Merged revisions 377843 from http://svn.asterisk.org/svn/asterisk/branches/11
........
  r377846 | mmichelson | 2012-12-12 01:04:45 +0400 (Wed, 12 Dec 2012) | 13 lines
  
  Add UUID support to Asterisk.
  
  This provides a common API for dealing with unique identifiers.
  The API provides methods to create, parse, copy, and stringify UUIDs.
  
  An accompanying unit test is provided that tests all operations.
  
  (closes issue ASTERISK-20726)
  reported by Matt Jordan
  
  Review: https://reviewboard.asterisk.org/r/2217
........
  r377867 | rmudgett | 2012-12-12 01:22:45 +0400 (Wed, 12 Dec 2012) | 20 lines
  
  Cleanup udptl on exit.
  
  * Cleanup CLI commands on exit.
  
  (issue ASTERISK-20649)
  Reported by: Corey Farrell
  Patches:
        udptl-shutdown-1_8-10.patch (license #5909) patch uploaded by Corey Farrell
        udptl-shutdown-11-trunk.patch (license #5909) patch uploaded by Corey Farrell
        Modified
  ........
  
  Merged revisions 377847 from http://svn.asterisk.org/svn/asterisk/branches/1.8
  ........
  
  Merged revisions 377848 from http://svn.asterisk.org/svn/asterisk/branches/10
  ........
  
  Merged revisions 377849 from http://svn.asterisk.org/svn/asterisk/branches/11
........
  r377878 | mmichelson | 2012-12-12 01:47:53 +0400 (Wed, 12 Dec 2012) | 3 lines
  
  Remove automerge properties.
........
  r377880 | mmichelson | 2012-12-12 01:53:06 +0400 (Wed, 12 Dec 2012) | 3 lines
  
  And remove svnmerge-integrated property.
........
  r377884 | rmudgett | 2012-12-12 02:03:23 +0400 (Wed, 12 Dec 2012) | 16 lines
  
  Cleanup CLI commands on exit for several files.
  
  (issue ASTERISK-20649)
  Reported by: Corey Farrell
  Patches:
        unregister-cli-multiple-all.patch (license #5909) patch uploaded by Corey Farrell
  ........
  
  Merged revisions 377881 from http://svn.asterisk.org/svn/asterisk/branches/1.8
  ........
  
  Merged revisions 377882 from http://svn.asterisk.org/svn/asterisk/branches/10
  ........
  
  Merged revisions 377883 from http://svn.asterisk.org/svn/asterisk/branches/11
........
  r377906 | mmichelson | 2012-12-12 02:42:11 +0400 (Wed, 12 Dec 2012) | 3 lines
  
  Add test events necessary for bridging tests to be able to properly run.
........
  r377911 | mmichelson | 2012-12-12 04:02:31 +0400 (Wed, 12 Dec 2012) | 22 lines
  
  Fix a potential deadlock in chan_sip during transfers.
  
  The issue comes from the fact that transfers may perform
  a redirecting update on a channel. The issue is that lock
  inversion between the channel and its tech_pvt occurs since
  the channel lock is released during the transfer process.
  
  The fix is to move when the redirecting update occurs to a
  place where neither the tech_pvt or the channel is locked so
  that the two can be locked in the proper order.
  
  (closes issue ASTERISK-20708)
  reported by Mark Michelson
  patches:
  	ASTERISK-20708-3.patch uploaded by Mark Michelson (License #5049)
  
  Tested by:
  	Tim Ringenbach at Asteria Solutions Group
  ........
  
  Merged revisions 377910 from http://svn.asterisk.org/svn/asterisk/branches/11
........
  r377915 | elguero | 2012-12-12 08:43:18 +0400 (Wed, 12 Dec 2012) | 17 lines
  
  Convert Dynamic Features Buffer To Use ast_str
  
  Currently, the buffer for the dynamic features list is set to a fixed size of
  128.  If the list is bigger than that, it results in the dynamic feature(s) not
  being recognized.
  
  This patch changes the buffer from a fixed size to a dynamic one.
  
  (closes issue ASTERISK-20680)
  Reported by: Clod Patry
  Tested by: Michael L. Young
  Patches: 
      asterisk-20680-dynamic-features-v2.diff 
                                       uploaded by Michael L. Young (license 5026)
  
  Review: https://reviewboard.asterisk.org/r/2221/
........
  r377925 | newtonr | 2012-12-13 02:43:40 +0400 (Thu, 13 Dec 2012) | 18 lines
  
  Incremented EXTRA_SOUNDS_VERSION in sounds/Makefile to 1.4.12 for new Extra Sounds releases
  
  See CHANGES-* files in English extra 1.4.12 tarballs for new sound prompts added.
  
  (closes ASTERISK-20328)
  Reported by: Matt Jordan
  (closes AST-755)
  Reported by: John Bigelow
  ........
  
  Merged revisions 377922 from http://svn.asterisk.org/svn/asterisk/branches/1.8
  ........
  
  Merged revisions 377923 from http://svn.asterisk.org/svn/asterisk/branches/10
  ........
  
  Merged revisions 377924 from http://svn.asterisk.org/svn/asterisk/branches/11
........
  r377966 | kmoore | 2012-12-13 18:28:57 +0400 (Thu, 13 Dec 2012) | 23 lines
  
  Ensure Min-SE is included in outbound INVITEs
  
  Asterisk now includes Min-SE in outbound INVITEs when the value is not
  90 (the default) and session timers are not disabled. This has the
  effect of Asterisk following RFC4028 more closely with regard to 422
  responses and preventing situations in which Asterisk would be forced
  to temporarily accept a call to tear it down based on a Session-Expires
  below the locally configured Min-SE.
  
  (issue SWP-5051)
  Review: https://reviewboard.asterisk.org/r/2222/
  Reported-by: Kinsey Moore
  Patch-by: Kinsey Moore
  ........
  
  Merged revisions 377946 from http://svn.asterisk.org/svn/asterisk/branches/1.8
  ........
  
  Merged revisions 377947 from http://svn.asterisk.org/svn/asterisk/branches/10
  ........
  
  Merged revisions 377948 from http://svn.asterisk.org/svn/asterisk/branches/11
........
  r377971 | beagles | 2012-12-13 19:22:27 +0400 (Thu, 13 Dec 2012) | 9 lines
  
  This change adds a SIP peer configuration feature to allow the peer's
  configured codecs to take precedence on an outgoing call.
  
  This change introduces a new peer configuration property named
  'ignore_requested_pref' that causes the requested codec to be ignored when
  determining the preferred codec for an outgoing call leg. The consequence is
  that Asterisk's usual efforts to prefer avoiding transcoding can be overridden
  on a peer-by-peer basis where appropriate. 
........
  r377972 | dlee | 2012-12-13 19:24:22 +0400 (Thu, 13 Dec 2012) | 5 lines
  
  Fixed configure.ac to look for proper uuid.h file
  
  Introduced in r377846, the configure script was looking for uuid.h instead
  of uuid/uuid.h.
........
  r377973 | mmichelson | 2012-12-13 19:37:45 +0400 (Thu, 13 Dec 2012) | 6 lines
  
  The UUID commit removed changes made in res_clialiases.c
  
  This puts back in the changes that are designed to work
  around a memory leak fix in the CLI code.
........
  r377974 | seanbright | 2012-12-13 19:37:55 +0400 (Thu, 13 Dec 2012) | 6 lines
  
  Use the UUID API to generate and validate UUIDs for res_calendar_exchange.
  
  Currently the res_calendar_exchange module uses its own method of generating
  UUIDs using ast_random().  Now that we have a UUID API we should use that
  instead.
........
  r377975 | mmichelson | 2012-12-13 19:40:03 +0400 (Thu, 13 Dec 2012) | 3 lines
  
  Re-add taskprocessor cleanup code that was removed by the UUID merge.
........
  r377977 | russell | 2012-12-13 20:18:52 +0400 (Thu, 13 Dec 2012) | 7 lines
  
  Remove compile time check HAVE_DEV_URANDOM.
  
  The code was doing a runtime check, anyway.  The compile time check isn't
  always valid (cross-compiling, packages).
  
  Review: https://reviewboard.asterisk.org/r/2245/
........
  r377981 | dlee | 2012-12-13 20:43:40 +0400 (Thu, 13 Dec 2012) | 1 line
  
  Bail configure if it can't find libuuid.
........
  r377986 | wedhorn | 2012-12-13 22:28:41 +0400 (Thu, 13 Dec 2012) | 14 lines
  
  Fix skinny debug tab completion
  
  Review the syntax of the 'skinny debug' command to show more than
  just 'show' for options to 'skinny debug' command.
  
  (closes issue ASTERISK-20789)
  Reported by: snuffy
  Tested by: snuffy, myself
  Patches:
      skinny-debug.diff uploaded by snuffy (license 5024)
  ........
  
  Merged revisions 377985 from http://svn.asterisk.org/svn/asterisk/branches/11
........
  r377994 | dlee | 2012-12-14 01:15:44 +0400 (Fri, 14 Dec 2012) | 1 line
  
  Fixed svn merge property breakage from r377986
........
  r378000 | seanbright | 2012-12-14 01:20:32 +0400 (Fri, 14 Dec 2012) | 8 lines
  
  Make generate_exchange_uuid() always return the passed ast_str pointer.
  
  I changed this code earlier to return NULL if it wasn't able to generate a UUID,
  whereas the earlier code would always return the ast_str that was passed in.
  Switch back to returning the ast_str, only set it to the empty string instead if
  UUID generation fails.  We still do a validity check later which will catch this
  and blow up if necessary.
........
  r378001 | wedhorn | 2012-12-14 01:25:31 +0400 (Fri, 14 Dec 2012) | 9 lines
  
  Minor fixes for chan_skinny
  
  Whitespace, change SUBSTATE_ONHOOK to correct SKINNY_ONHOOK and 
  correct len of 2 strcmp in skinny_setdebug(). (see opticron's review
  on https://reviewboard.asterisk.org/r/2240/)
  ........
  
  Merged revisions 377991 from http://svn.asterisk.org/svn/asterisk/branches/11
........
  r378002 | rmudgett | 2012-12-14 01:28:15 +0400 (Fri, 14 Dec 2012) | 35 lines
  
  confbridge: Fix MOH on simultaneous user entry to a new conference.
  
  When two users entered a new conference simultaneously, one of the callers
  hears MOH.  This happened if two unmarked users entered simultaneously and
  also if a waitmarked and a marked user entered simultaneously.
  
  * Created a confbridge internal MOH API to eliminate the inlined MOH
  handling code.  Note that the conference mixing bridge needs to be locked
  when actually starting/stopping MOH because there is a small window
  between the conference join unsuspend MOH and actually joining the mixing
  bridge.
  
  * Created the concept of suspended MOH so it can be interrupted while
  conference join announcements to the user and DTMF features can operate.
  
  * Suspend any MOH until the user is about to actually join the mixing
  bridge of the conference.  This way any pre-join file playback does not
  need to worry about MOH.
  
  * Made post-join actions only play deferred entry announcement files.
  Changing the user/conference state during that time is not protected or
  controlled by the state machine.
  
  (closes issue ASTERISK-20606)
  Reported by: Eugenia Belova
  Tested by: rmudgett
  
  Review: https://reviewboard.asterisk.org/r/2232/
  ........
  
  Merged revisions 377992 from http://svn.asterisk.org/svn/asterisk/branches/10
  ........
  
  Merged revisions 377993 from http://svn.asterisk.org/svn/asterisk/branches/11
........
  r378006 | wedhorn | 2012-12-14 05:02:15 +0400 (Fri, 14 Dec 2012) | 8 lines
  
  Add g722 codec support to skinny
  
  (closes issue ASTERISK-20788)
  Reported by: snuffy
  Tested by: snuffy, myself
  Patches: 
      skinny-g722.diff uploaded by snuffy (license 5024)
........
  r378011 | wedhorn | 2012-12-14 05:55:43 +0400 (Fri, 14 Dec 2012) | 15 lines
  
  Fix skinny to recognise vmexten in general section of conf
  
  Fixup the vmexten so if globally set in general section will be honored by
  chan_skinny. Also get rid of the 'global_' part of variable name to match
  regexten.
  
  (closes issue ASTERISK-20790)
  Reported by: snuffy
  Tested by: snuffy, myself
  Patches: 
      skinny-vm.diff uploaded by snuffy (license 5024)
  ........
  
  Merged revisions 378010 from http://svn.asterisk.org/svn/asterisk/branches/11
........
  r378029 | rmudgett | 2012-12-15 00:22:36 +0400 (Sat, 15 Dec 2012) | 1 line
  
  app_queue: Make update_status() not return anything.
........
  r378039 | rmudgett | 2012-12-15 01:35:44 +0400 (Sat, 15 Dec 2012) | 26 lines
  
  app_queue: Revert bad ringinuse=no patch.
  
  With the option ringinuse=no set, the patch committed for ASTERISK-16115
  causes non-SIP queue members to never be called because the device state
  is checked after a channel is created to determine if the member is busy.
  These queue members always get the "Member %s is busy, cannot dial"
  message.
  
  Most channel drivers other than chan_sip use the default device state
  handling.  The default device-state state is considered in use or unknown
  if the channel exists or not respectively.
  
  (closes issue ASTERISK-20801)
  Reported by: rmudgett
  Patches:
        jira_asterisk_16115_revert_r370418_v1.8.patch (license #5621) patch uploaded by rmudgett
  ........
  
  Merged revisions 378036 from http://svn.asterisk.org/svn/asterisk/branches/1.8
  ........
  
  Merged revisions 378037 from http://svn.asterisk.org/svn/asterisk/branches/10
  ........
  
  Merged revisions 378038 from http://svn.asterisk.org/svn/asterisk/branches/11
........
  r378063 | jrose | 2012-12-15 02:34:18 +0400 (Sat, 15 Dec 2012) | 8 lines
  
  Features: BRIDGE_FEATURES variable automixmonitor support and use proper party
  
  BRIDGE_FEATURES did not previously support the automixmonitor feature. Now it
  does. In addition, the BRIDGE_FEATURES variable would not apply features to
  the proper party based on whether the feature option letter was in caps or
  in lowercase (both ways would apply it to the caller). Now uppercase applies
  to the caller while lowercase applies to the callee (like with the dial option)
........
  r378064 | rmudgett | 2012-12-15 02:45:03 +0400 (Sat, 15 Dec 2012) | 4 lines
  
  chan_agent: Remove some duplicated code.
  
  No need to check for an agent twice.  Santa does that.
........
  r378072 | rmudgett | 2012-12-18 00:34:25 +0400 (Tue, 18 Dec 2012) | 9 lines
  
  chan_local: Misc lock and ref tweaks.
  
  * awesome_locking() does not need to thrash the pvt lock as much.
  
  * local_setoption() does not need to check for NULL pvt on cleanup since
  it will never be NULL.
  
  * Made ref the pvt before locking for consistency.
........
  r378074 | qwell | 2012-12-18 00:59:51 +0400 (Tue, 18 Dec 2012) | 10 lines
  
  Make libasteriskssl.so symlink use a relative path.
  
  This was causing issues when using DESTDIR, since the path to which the link
  pointed is not likely to exist (and not useful to exist) on the target system.
  
  (issue ASTNOW-284)
  ........
  
  Merged revisions 378073 from http://svn.asterisk.org/svn/asterisk/branches/11
........
  r378081 | rmudgett | 2012-12-18 01:22:21 +0400 (Tue, 18 Dec 2012) | 7 lines
  
  chan_local: Parse dial string consistently.
  
  * Fix local_alloc() unexpected limitation of exten and context length from
  a combined length of 80 characters to a normal 80 characters each.
  
  * Made local_alloc() and local_devicestate() parse the same way.
........
  r378091 | rmudgett | 2012-12-18 03:02:54 +0400 (Tue, 18 Dec 2012) | 22 lines
  
  Make chan_local module references tied to local_pvt lifetime.
  
  The chan_local module references were manually tied to the existence of
  the ;1 and ;2 channel links.
  
  * Made chan_local module references tied to the existence of the local_pvt
  structure as well as automatically take care of the module references.
  
  * Tweaked the wording of the local_fixup() failure warning message to make
  sense.
  
  Review: https://reviewboard.asterisk.org/r/2181/
  ........
  
  Merged revisions 378088 from http://svn.asterisk.org/svn/asterisk/branches/1.8
  ........
  
  Merged revisions 378089 from http://svn.asterisk.org/svn/asterisk/branches/10
  ........
  
  Merged revisions 378090 from http://svn.asterisk.org/svn/asterisk/branches/11
........
  r378095 | rmudgett | 2012-12-18 03:10:42 +0400 (Tue, 18 Dec 2012) | 11 lines
  
  Fix potential double free when unloading a module.
  ........
  
  Merged revisions 378092 from http://svn.asterisk.org/svn/asterisk/branches/1.8
  ........
  
  Merged revisions 378093 from http://svn.asterisk.org/svn/asterisk/branches/10
  ........
  
  Merged revisions 378094 from http://svn.asterisk.org/svn/asterisk/branches/11
........
  r378122 | kmoore | 2012-12-18 21:48:36 +0400 (Tue, 18 Dec 2012) | 17 lines
  
  Add test events for time limit-related hangups
  
  This patch adds hangup-related test events in order to support testing
  of time-limited bridges. This aids in testing the S() and L() bridge
  options.
  
  (issue SWP-4713)
  ........
  
  Merged revisions 378119 from http://svn.asterisk.org/svn/asterisk/branches/1.8
  ........
  
  Merged revisions 378120 from http://svn.asterisk.org/svn/asterisk/branches/10
  ........
  
  Merged revisions 378121 from http://svn.asterisk.org/svn/asterisk/branches/11
........
  r378166 | rmudgett | 2012-12-21 01:51:03 +0400 (Fri, 21 Dec 2012) | 8 lines
  
  Give the causes[] a struct name.
  ........
  
  Merged revisions 378164 from http://svn.asterisk.org/svn/asterisk/branches/1.8
  ........
  
  Merged revisions 378165 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 377841,377844,377846,377867,377878,377880,377884,377906,377911,377915,377925,377966,377971-377975,377977,377981,377986,377994,378000-378002,378006,378011,378029,378039,378063-378064,378072,378074,378081,378091,378095,378122,378166 from http://svn.asterisk.org/svn/asterisk/trunk

Added:
    team/may/ooh323_qsig/include/asterisk/uuid.h
      - copied unchanged from r378166, trunk/include/asterisk/uuid.h
    team/may/ooh323_qsig/main/uuid.c
      - copied unchanged from r378166, trunk/main/uuid.c
    team/may/ooh323_qsig/tests/test_uuid.c
      - copied unchanged from r378166, trunk/tests/test_uuid.c
Modified:
    team/may/ooh323_qsig/   (props changed)
    team/may/ooh323_qsig/CHANGES
    team/may/ooh323_qsig/UPGRADE.txt
    team/may/ooh323_qsig/apps/app_confbridge.c
    team/may/ooh323_qsig/apps/app_queue.c
    team/may/ooh323_qsig/apps/confbridge/conf_state.c
    team/may/ooh323_qsig/apps/confbridge/conf_state_multi_marked.c
    team/may/ooh323_qsig/apps/confbridge/include/confbridge.h
    team/may/ooh323_qsig/channels/chan_agent.c
    team/may/ooh323_qsig/channels/chan_local.c
    team/may/ooh323_qsig/channels/chan_sip.c
    team/may/ooh323_qsig/channels/chan_skinny.c
    team/may/ooh323_qsig/channels/sip/include/sip.h
    team/may/ooh323_qsig/configs/sip.conf.sample
    team/may/ooh323_qsig/configure
    team/may/ooh323_qsig/configure.ac
    team/may/ooh323_qsig/include/asterisk/autoconfig.h.in
    team/may/ooh323_qsig/include/asterisk/bridging.h
    team/may/ooh323_qsig/main/Makefile
    team/may/ooh323_qsig/main/aoc.c
    team/may/ooh323_qsig/main/asterisk.c
    team/may/ooh323_qsig/main/cel.c
    team/may/ooh323_qsig/main/channel.c
    team/may/ooh323_qsig/main/data.c
    team/may/ooh323_qsig/main/features.c
    team/may/ooh323_qsig/main/file.c
    team/may/ooh323_qsig/main/http.c
    team/may/ooh323_qsig/main/image.c
    team/may/ooh323_qsig/main/loader.c
    team/may/ooh323_qsig/main/stun.c
    team/may/ooh323_qsig/main/taskprocessor.c
    team/may/ooh323_qsig/main/timing.c
    team/may/ooh323_qsig/main/udptl.c
    team/may/ooh323_qsig/main/utils.c
    team/may/ooh323_qsig/res/res_calendar_exchange.c
    team/may/ooh323_qsig/res/res_clialiases.c
    team/may/ooh323_qsig/sounds/Makefile

Propchange: team/may/ooh323_qsig/
------------------------------------------------------------------------------
Binary property 'branch-11-merged' - no diff available.

Propchange: team/may/ooh323_qsig/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Dec 21 15:44:16 2012
@@ -1,1 +1,1 @@
-/trunk:376342-376345
+/trunk:376342-376345,377841-378166

Propchange: team/may/ooh323_qsig/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Fri Dec 21 15:44:16 2012
@@ -1,1 +1,1 @@
-/trunk:1-377813
+/trunk:1-378195

Modified: team/may/ooh323_qsig/CHANGES
URL: http://svnview.digium.com/svn/asterisk/team/may/ooh323_qsig/CHANGES?view=diff&rev=378196&r1=378195&r2=378196
==============================================================================
--- team/may/ooh323_qsig/CHANGES (original)
+++ team/may/ooh323_qsig/CHANGES Fri Dec 21 15:44:16 2012
@@ -30,6 +30,16 @@
    than 15 characters and no longer shows authorization requirement for commands.
    'Manager Show Command' now displays the privileges needed for using a given
    manager command instead.
+
+Features
+-------------------
+ * The BRIDGE_FEATURES channel variable would previously only set features for
+   the calling party and would set this feature regardless of whether the
+   feature was in caps or in lowercase. Use of a caps feature for a letter
+   will now apply the feature to the calling party while use of a lowercase
+   letter will apply that feature to the called party.
+
+ * Add support for automixmonitor to the BRIDGE_FEATURES channel variable.
 
 Logging
 -------------------

Modified: team/may/ooh323_qsig/UPGRADE.txt
URL: http://svnview.digium.com/svn/asterisk/team/may/ooh323_qsig/UPGRADE.txt?view=diff&rev=378196&r1=378195&r2=378196
==============================================================================
--- team/may/ooh323_qsig/UPGRADE.txt (original)
+++ team/may/ooh323_qsig/UPGRADE.txt Fri Dec 21 15:44:16 2012
@@ -64,6 +64,9 @@
  - 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.
+ - BRIDGE_FEATURES channel variable is now casesensitive for feature letter codes.
+   Uppercase variants apply them to the calling party while lowercase variants
+   apply them to the called party.
 
 From 10 to 11:
 

Modified: team/may/ooh323_qsig/apps/app_confbridge.c
URL: http://svnview.digium.com/svn/asterisk/team/may/ooh323_qsig/apps/app_confbridge.c?view=diff&rev=378196&r1=378195&r2=378196
==============================================================================
--- team/may/ooh323_qsig/apps/app_confbridge.c (original)
+++ team/may/ooh323_qsig/apps/app_confbridge.c Fri Dec 21 15:44:16 2012
@@ -909,6 +909,94 @@
 	return 0;
 }
 
+void conf_moh_stop(struct conference_bridge_user *user)
+{
+	user->playing_moh = 0;
+	if (!user->suspended_moh) {
+		int in_bridge;
+
+		/*
+		 * Locking the ast_bridge here is the only way to hold off the
+		 * call to ast_bridge_join() in confbridge_exec() from
+		 * interfering with the bridge and MOH operations here.
+		 */
+		ast_bridge_lock(user->conference_bridge->bridge);
+
+		/*
+		 * Temporarily suspend the user from the bridge so we have
+		 * control to stop MOH if needed.
+		 */
+		in_bridge = !ast_bridge_suspend(user->conference_bridge->bridge, user->chan);
+		ast_moh_stop(user->chan);
+		if (in_bridge) {
+			ast_bridge_unsuspend(user->conference_bridge->bridge, user->chan);
+		}
+
+		ast_bridge_unlock(user->conference_bridge->bridge);
+	}
+}
+
+void conf_moh_start(struct conference_bridge_user *user)
+{
+	user->playing_moh = 1;
+	if (!user->suspended_moh) {
+		int in_bridge;
+
+		/*
+		 * Locking the ast_bridge here is the only way to hold off the
+		 * call to ast_bridge_join() in confbridge_exec() from
+		 * interfering with the bridge and MOH operations here.
+		 */
+		ast_bridge_lock(user->conference_bridge->bridge);
+
+		/*
+		 * Temporarily suspend the user from the bridge so we have
+		 * control to start MOH if needed.
+		 */
+		in_bridge = !ast_bridge_suspend(user->conference_bridge->bridge, user->chan);
+		ast_moh_start(user->chan, user->u_profile.moh_class, NULL);
+		if (in_bridge) {
+			ast_bridge_unsuspend(user->conference_bridge->bridge, user->chan);
+		}
+
+		ast_bridge_unlock(user->conference_bridge->bridge);
+	}
+}
+
+/*!
+ * \internal
+ * \brief Unsuspend MOH for the conference user.
+ *
+ * \param user Conference user to unsuspend MOH on.
+ *
+ * \return Nothing
+ */
+static void conf_moh_unsuspend(struct conference_bridge_user *user)
+{
+	ao2_lock(user->conference_bridge);
+	if (--user->suspended_moh == 0 && user->playing_moh) {
+		ast_moh_start(user->chan, user->u_profile.moh_class, NULL);
+	}
+	ao2_unlock(user->conference_bridge);
+}
+
+/*!
+ * \internal
+ * \brief Suspend MOH for the conference user.
+ *
+ * \param user Conference user to suspend MOH on.
+ *
+ * \return Nothing
+ */
+static void conf_moh_suspend(struct conference_bridge_user *user)
+{
+	ao2_lock(user->conference_bridge);
+	if (user->suspended_moh++ == 0 && user->playing_moh) {
+		ast_moh_stop(user->chan);
+	}
+	ao2_unlock(user->conference_bridge);
+}
+
 int conf_handle_first_marked_common(struct conference_bridge_user *cbu)
 {
 	if (!ast_test_flag(&cbu->u_profile, USER_OPT_QUIET) && play_prompt_to_user(cbu, conf_get_sound(CONF_SOUND_PLACE_IN_CONF, cbu->b_profile.sounds))) {
@@ -919,18 +1007,11 @@
 
 int conf_handle_inactive_waitmarked(struct conference_bridge_user *cbu)
 {
-	/* Be sure we are muted so we can't talk to anybody else waiting */
-	cbu->features.mute = 1;
 	/* If we have not been quieted play back that they are waiting for the leader */
 	if (!ast_test_flag(&cbu->u_profile, USER_OPT_QUIET) && play_prompt_to_user(cbu,
 			conf_get_sound(CONF_SOUND_WAIT_FOR_LEADER, cbu->b_profile.sounds))) {
 		/* user hungup while the sound was playing */
 		return -1;
-	}
-	/* Start music on hold if needed */
-	if (ast_test_flag(&cbu->u_profile, USER_OPT_MUSICONHOLD)) {
-		ast_moh_start(cbu->chan, cbu->u_profile.moh_class, NULL);
-		cbu->playing_moh = 1;
 	}
 	return 0;
 }
@@ -970,11 +1051,8 @@
 	/* If we are the second participant we may need to stop music on hold on the first */
 	struct conference_bridge_user *first_participant = AST_LIST_FIRST(&conference_bridge->active_list);
 
-	/* Temporarily suspend the above participant from the bridge so we have control to stop MOH if needed */
-	if (ast_test_flag(&first_participant->u_profile, USER_OPT_MUSICONHOLD) && !ast_bridge_suspend(conference_bridge->bridge, first_participant->chan)) {
-		first_participant->playing_moh = 0;
-		ast_moh_stop(first_participant->chan);
-		ast_bridge_unsuspend(conference_bridge->bridge, first_participant->chan);
+	if (ast_test_flag(&first_participant->u_profile, USER_OPT_MUSICONHOLD)) {
+		conf_moh_stop(first_participant);
 	}
 	if (!ast_test_flag(&first_participant->u_profile, USER_OPT_STARTMUTED)) {
 		first_participant->features.mute = 0;
@@ -1098,6 +1176,13 @@
 	conference_bridge_user->conference_bridge = conference_bridge;
 
 	ao2_lock(conference_bridge);
+
+	/*
+	 * Suspend any MOH until the user actually joins the bridge of
+	 * the conference.  This way any pre-join file playback does not
+	 * need to worry about MOH.
+	 */
+	conference_bridge_user->suspended_moh = 1;
 
 	if (handle_conf_user_join(conference_bridge_user)) {
 		/* Invalid event, nothing was done, so we don't want to process a leave. */
@@ -1530,20 +1615,17 @@
 	/* Play the Join sound to both the conference and the user entering. */
 	if (!quiet) {
 		const char *join_sound = conf_get_sound(CONF_SOUND_JOIN, conference_bridge_user.b_profile.sounds);
-		if (conference_bridge_user.playing_moh) {
-			ast_moh_stop(chan);
-		}
+
 		ast_stream_and_wait(chan, join_sound, "");
 		ast_autoservice_start(chan);
 		play_sound_file(conference_bridge, join_sound);
 		ast_autoservice_stop(chan);
-		if (conference_bridge_user.playing_moh) {
-			ast_moh_start(chan, conference_bridge_user.u_profile.moh_class, NULL);
-		}
 	}
 
 	/* See if we need to automatically set this user as a video source or not */
 	handle_video_on_join(conference_bridge, conference_bridge_user.chan, ast_test_flag(&conference_bridge_user.u_profile, USER_OPT_MARKEDUSER));
+
+	conf_moh_unsuspend(&conference_bridge_user);
 
 	/* Join our conference bridge for real */
 	send_join_event(conference_bridge_user.chan, conference_bridge->name);
@@ -1925,25 +2007,14 @@
 	struct conf_menu_entry *menu_entry,
 	struct conf_menu *menu)
 {
-	struct conference_bridge *conference_bridge = conference_bridge_user->conference_bridge;
-
 	/* See if music on hold is playing */
-	ao2_lock(conference_bridge);
-	if (conference_bridge_user->playing_moh) {
-		/* MOH is going, let's stop it */
-		ast_moh_stop(bridge_channel->chan);
-	}
-	ao2_unlock(conference_bridge);
+	conf_moh_suspend(conference_bridge_user);
 
 	/* execute the list of actions associated with this menu entry */
-	execute_menu_entry(conference_bridge, conference_bridge_user, bridge_channel, menu_entry, menu);
+	execute_menu_entry(conference_bridge_user->conference_bridge, conference_bridge_user, bridge_channel, menu_entry, menu);
 
 	/* See if music on hold needs to be started back up again */
-	ao2_lock(conference_bridge);
-	if (conference_bridge_user->playing_moh) {
-		ast_moh_start(bridge_channel->chan, conference_bridge_user->u_profile.moh_class, NULL);
-	}
-	ao2_unlock(conference_bridge);
+	conf_moh_unsuspend(conference_bridge_user);
 
 	return 0;
 }
@@ -2835,13 +2906,7 @@
 	/* Turn on MOH/mute if the single participant is set up for it */
 	if (ast_test_flag(&only_participant->u_profile, USER_OPT_MUSICONHOLD)) {
 		only_participant->features.mute = 1;
-		if (!ast_channel_internal_bridge(only_participant->chan) || !ast_bridge_suspend(conference_bridge->bridge, only_participant->chan)) {
-			ast_moh_start(only_participant->chan, only_participant->u_profile.moh_class, NULL);
-			only_participant->playing_moh = 1;
-			if (ast_channel_internal_bridge(only_participant->chan)) {
-				ast_bridge_unsuspend(conference_bridge->bridge, only_participant->chan);
-			}
-		}
+		conf_moh_start(only_participant);
 	}
 }
 

Modified: team/may/ooh323_qsig/apps/app_queue.c
URL: http://svnview.digium.com/svn/asterisk/team/may/ooh323_qsig/apps/app_queue.c?view=diff&rev=378196&r1=378195&r2=378196
==============================================================================
--- team/may/ooh323_qsig/apps/app_queue.c (original)
+++ team/may/ooh323_qsig/apps/app_queue.c Fri Dec 21 15:44:16 2012
@@ -1630,12 +1630,12 @@
  * Lock interface list find sc, iterate through each queues queue_member list for member to
  * update state inside queues
 */
-static int update_status(struct call_queue *q, struct member *m, const int status)
+static void update_status(struct call_queue *q, struct member *m, const int status)
 {
 	m->status = status;
 
 	if (q->maskmemberstatus) {
-		return 0;
+		return;
 	}
 
 	/*** DOCUMENTATION
@@ -1707,8 +1707,6 @@
 		q->name, m->interface, m->membername, m->state_interface, m->dynamic ? "dynamic" : m->realtime ? "realtime" : "static",
 		m->penalty, m->calls, (int)m->lastcall, m->status, m->paused
 	);
-
-	return 0;
 }
 
 /*!
@@ -3650,18 +3648,8 @@
 	ast_channel_unlock(tmp->chan);
 	ast_channel_unlock(qe->chan);
 
-	ao2_lock(tmp->member);
-	update_status(qe->parent, tmp->member, get_queue_member_status(tmp->member));
-	if (!qe->parent->ringinuse && (tmp->member->status != AST_DEVICE_NOT_INUSE) && (tmp->member->status != AST_DEVICE_UNKNOWN)) {
-		ast_verb(1, "Member %s is busy, cannot dial", tmp->member->interface);
-		res = -1;
-	}
-	else {
-		/* Place the call, but don't wait on the answer */
-		res = ast_call(tmp->chan, location, 0);
-	}
-	ao2_unlock(tmp->member);
-	if (res) {
+	/* Place the call, but don't wait on the answer */
+	if ((res = ast_call(tmp->chan, location, 0))) {
 		/* Again, keep going even if there's an error */
 		ast_verb(3, "Couldn't call %s\n", tmp->interface);
 		do_hang(tmp);

Modified: team/may/ooh323_qsig/apps/confbridge/conf_state.c
URL: http://svnview.digium.com/svn/asterisk/team/may/ooh323_qsig/apps/confbridge/conf_state.c?view=diff&rev=378196&r1=378195&r2=378196
==============================================================================
--- team/may/ooh323_qsig/apps/confbridge/conf_state.c (original)
+++ team/may/ooh323_qsig/apps/confbridge/conf_state.c Fri Dec 21 15:44:16 2012
@@ -47,9 +47,28 @@
 	ast_log(LOG_ERROR, "Invalid event for confbridge user '%s'\n", cbu->u_profile.name);
 }
 
+/*!
+ * \internal
+ * \brief Mute the user and play MOH if the user requires it.
+ *
+ * \param user Conference user to mute and optionally start MOH on.
+ *
+ * \return Nothing
+ */
+static void conf_mute_moh_inactive_waitmarked(struct conference_bridge_user *user)
+{
+	/* Be sure we are muted so we can't talk to anybody else waiting */
+	user->features.mute = 1;
+	/* Start music on hold if needed */
+	if (ast_test_flag(&user->u_profile, USER_OPT_MUSICONHOLD)) {
+		conf_moh_start(user);
+	}
+}
+
 void conf_default_join_waitmarked(struct conference_bridge_user *cbu)
 {
 	conf_add_user_waiting(cbu->conference_bridge, cbu);
+	conf_mute_moh_inactive_waitmarked(cbu);
 	conf_add_post_join_action(cbu, conf_handle_inactive_waitmarked);
 }
 

Modified: team/may/ooh323_qsig/apps/confbridge/conf_state_multi_marked.c
URL: http://svnview.digium.com/svn/asterisk/team/may/ooh323_qsig/apps/confbridge/conf_state_multi_marked.c?view=diff&rev=378196&r1=378195&r2=378196
==============================================================================
--- team/may/ooh323_qsig/apps/confbridge/conf_state_multi_marked.c (original)
+++ team/may/ooh323_qsig/apps/confbridge/conf_state_multi_marked.c Fri Dec 21 15:44:16 2012
@@ -107,12 +107,8 @@
 				cbu_iter->conference_bridge->waitingusers++;
 				/* Handle muting/moh of cbu_iter if necessary */
 				if (ast_test_flag(&cbu_iter->u_profile, USER_OPT_MUSICONHOLD)) {
-				   cbu_iter->features.mute = 1;
-					if (!ast_bridge_suspend(cbu_iter->conference_bridge->bridge, cbu_iter->chan)) {
-						ast_moh_start(cbu_iter->chan, cbu_iter->u_profile.moh_class, NULL);
-						cbu_iter->playing_moh = 1;
-						ast_bridge_unsuspend(cbu_iter->conference_bridge->bridge, cbu_iter->chan);
-					}
+					cbu_iter->features.mute = 1;
+					conf_moh_start(cbu_iter);
 				}
 			}
 		}
@@ -173,10 +169,8 @@
 		cbu->conference_bridge->waitingusers--;
 		AST_LIST_INSERT_TAIL(&cbu->conference_bridge->active_list, cbu_iter, list);
 		cbu->conference_bridge->activeusers++;
-		if (cbu_iter->playing_moh && !ast_bridge_suspend(cbu->conference_bridge->bridge, cbu_iter->chan)) {
-			cbu_iter->playing_moh = 0;
-			ast_moh_stop(cbu_iter->chan);
-			ast_bridge_unsuspend(cbu->conference_bridge->bridge, cbu_iter->chan);
+		if (cbu_iter->playing_moh) {
+			conf_moh_stop(cbu_iter);
 		}
 		/* only unmute them if they are not supposed to start muted */
 		if (!ast_test_flag(&cbu_iter->u_profile, USER_OPT_STARTMUTED)) {

Modified: team/may/ooh323_qsig/apps/confbridge/include/confbridge.h
URL: http://svnview.digium.com/svn/asterisk/team/may/ooh323_qsig/apps/confbridge/include/confbridge.h?view=diff&rev=378196&r1=378195&r2=378196
==============================================================================
--- team/may/ooh323_qsig/apps/confbridge/include/confbridge.h (original)
+++ team/may/ooh323_qsig/apps/confbridge/include/confbridge.h Fri Dec 21 15:44:16 2012
@@ -236,6 +236,7 @@
 	struct ast_channel *chan;                    /*!< Asterisk channel participating */
 	struct ast_bridge_features features;         /*!< Bridge features structure */
 	struct ast_bridge_tech_optimizations tech_args; /*!< Bridge technology optimizations for talk detection */
+	unsigned int suspended_moh;                  /*!< Count of active suspended MOH actions. */
 	unsigned int kicked:1;                       /*!< User has been kicked from the conference */
 	unsigned int playing_moh:1;                  /*!< MOH is currently being played to the user */
 	AST_LIST_HEAD_NOLOCK(, post_join_action) post_join_list; /*!< List of sounds to play after joining */;
@@ -358,6 +359,24 @@
  */
 void conf_ended(struct conference_bridge *conference_bridge);
 
+/*!
+ * \brief Stop MOH for the conference user.
+ *
+ * \param user Conference user to stop MOH on.
+ *
+ * \return Nothing
+ */
+void conf_moh_stop(struct conference_bridge_user *user);
+
+/*!
+ * \brief Start MOH for the conference user.
+ *
+ * \param user Conference user to start MOH on.
+ *
+ * \return Nothing
+ */
+void conf_moh_start(struct conference_bridge_user *user);
+
 /*! \brief Attempt to mute/play MOH to the only user in the conference if they require it
  * \param conference_bridge A conference bridge containing a single user
  */

Modified: team/may/ooh323_qsig/channels/chan_agent.c
URL: http://svnview.digium.com/svn/asterisk/team/may/ooh323_qsig/channels/chan_agent.c?view=diff&rev=378196&r1=378195&r2=378196
==============================================================================
--- team/may/ooh323_qsig/channels/chan_agent.c (original)
+++ team/may/ooh323_qsig/channels/chan_agent.c Fri Dec 21 15:44:16 2012
@@ -1442,8 +1442,9 @@
 	AST_LIST_TRAVERSE(&agents, p, list) {
 		ast_mutex_lock(&p->lock);
 		if (!p->pending && ((groupmatch && (p->group & groupmatch)) || !strcmp(data, p->agent))) {
-			if (p->chan)
+			if (p->chan) {
 				hasagent++;
+			}
 			now = ast_tvnow();
 			if (!p->lastdisc.tv_sec || (now.tv_sec >= p->lastdisc.tv_sec)) {
 				p->lastdisc = ast_tv(0, 0);
@@ -1459,30 +1460,6 @@
 			}
 		}
 		ast_mutex_unlock(&p->lock);
-	}
-	if (!p) {
-		AST_LIST_TRAVERSE(&agents, p, list) {
-			ast_mutex_lock(&p->lock);
-			if (!p->pending && ((groupmatch && (p->group & groupmatch)) || !strcmp(data, p->agent))) {
-				if (p->chan) {
-					hasagent++;
-				}
-				now = ast_tvnow();
-				if (!p->lastdisc.tv_sec || (now.tv_sec >= p->lastdisc.tv_sec)) {
-					p->lastdisc = ast_tv(0, 0);
-					/* Agent must be registered, but not have any active call, and not be in a waiting state */
-					if (!p->owner && p->chan) {
-						/* Could still get a fixed agent */
-						chan = agent_new(p, AST_STATE_DOWN, requestor ? ast_channel_linkedid(requestor) : NULL, callid);
-					}
-					if (chan) {
-						ast_mutex_unlock(&p->lock);
-						break;
-					}
-				}
-			}
-			ast_mutex_unlock(&p->lock);
-		}
 	}
 
 	if (!chan && waitforagent) {

Modified: team/may/ooh323_qsig/channels/chan_local.c
URL: http://svnview.digium.com/svn/asterisk/team/may/ooh323_qsig/channels/chan_local.c?view=diff&rev=378196&r1=378195&r2=378196
==============================================================================
--- team/may/ooh323_qsig/channels/chan_local.c (original)
+++ team/may/ooh323_qsig/channels/chan_local.c Fri Dec 21 15:44:16 2012
@@ -151,8 +151,6 @@
 	struct ast_jb_conf jb_conf;     /*!< jitterbuffer configuration for this local channel */
 	struct ast_channel *owner;      /*!< Master Channel - Bridging happens here */

[... 1446 lines stripped ...]



More information about the asterisk-commits mailing list