[asterisk-commits] rmudgett: branch rmudgett/misdn_facility r155799 - in /team/rmudgett/misdn_fa...

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Mon Nov 10 14:35:05 CST 2008


Author: rmudgett
Date: Mon Nov 10 14:35:05 2008
New Revision: 155799

URL: http://svn.digium.com/view/asterisk?view=rev&rev=155799
Log:
Manually merged from issue8824 branch.

Merged revisions 154702,154768,154812,154850,154888,154936,154961,154981,155029,155089,155136,155178,155216,155255,155294,155336,155371,155418,155478,155526,155567,155624,155647,155681,155724,155774 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/team/group/issue8824

................
  r154702 | root | 2008-11-05 10:39:26 -0600 (Wed, 05 Nov 2008) | 17 lines
  
  Merged revisions 154687 via svnmerge from 
  file:///srv/subversion/repos/asterisk/trunk
  
  ................
  r154687 | murf | 2008-11-05 10:11:11 -0600 (Wed, 05 Nov 2008) | 9 lines
  
  Merged revisions 154685 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
  r154685 | murf | 2008-11-05 09:06:53 -0700 (Wed, 05 Nov 2008) | 1 line
  
  This fix was prompted by communication from user, who was seeing thousands of error logs... looks like EAGAIN. Made such uninteresting.
  ........
  
  ................
................
  r154768 | root | 2008-11-05 11:39:41 -0600 (Wed, 05 Nov 2008) | 21 lines
  
  Merged revisions 154732 via svnmerge from 
  file:///srv/subversion/repos/asterisk/trunk
  
  ................
  r154732 | mmichelson | 2008-11-05 10:46:54 -0600 (Wed, 05 Nov 2008) | 13 lines
  
  Blocked revisions 154724 via svnmerge
  
  ........
  r154724 | mmichelson | 2008-11-05 10:44:34 -0600 (Wed, 05 Nov 2008) | 6 lines
  
  The logic of a strcasecmp call was reversed
  
  (closes issue #13841)
  Reported by: clegall_proformatique
  
  
  ........
  
  ................
................
  r154812 | root | 2008-11-05 13:38:45 -0600 (Wed, 05 Nov 2008) | 27 lines
  
  Merged revisions 154796,154798,154801 via svnmerge from 
  file:///srv/subversion/repos/asterisk/trunk
  
  ........
  r154796 | eliel | 2008-11-05 12:46:29 -0600 (Wed, 05 Nov 2008) | 8 lines
  
  Add Macro(), MacroExit(), MacroExclusive() and
  MacroIf() applications XML documentation.
  
  (closes issue #13699)
  Reported by: snuffy
  Patches:
        bug13699_20081016.diff uploaded by snuffy (license 35)
  
  ........
  r154798 | eliel | 2008-11-05 12:50:02 -0600 (Wed, 05 Nov 2008) | 2 lines
  
  Add more [see also] references based on TFOT.
  
  ........
  r154801 | eliel | 2008-11-05 13:17:32 -0600 (Wed, 05 Nov 2008) | 3 lines
  
  Add TestClient() and TestServer() applications XML
  documentation.
  
  ........
................
  r154850 | root | 2008-11-05 14:38:45 -0600 (Wed, 05 Nov 2008) | 16 lines
  
  Merged revisions 154837,154839 via svnmerge from 
  file:///srv/subversion/repos/asterisk/trunk
  
  ........
  r154837 | eliel | 2008-11-05 14:17:06 -0600 (Wed, 05 Nov 2008) | 3 lines
  
  Add AgentLogin(), AgentMonitorOutgoing() applications and
  AGENT() function XML documentation.
  
  ........
  r154839 | mvanbaak | 2008-11-05 14:33:11 -0600 (Wed, 05 Nov 2008) | 2 lines
  
  make this compile on OpenBSD again.
  
  ........
................
  r154888 | root | 2008-11-05 15:39:34 -0600 (Wed, 05 Nov 2008) | 9 lines
  
  Merged revisions 154875 via svnmerge from 
  file:///srv/subversion/repos/asterisk/trunk
  
  ........
  r154875 | mattf | 2008-11-05 14:45:03 -0600 (Wed, 05 Nov 2008) | 1 line
  
  Make compilation of chan_dahdi so that it does not require the new pri_progress_with_cause function to have libpri support work.
  ........
................
  r154936 | root | 2008-11-05 16:38:39 -0600 (Wed, 05 Nov 2008) | 1 line
  
  automerge cancel
................
  r154961 | mmichelson | 2008-11-05 17:06:04 -0600 (Wed, 05 Nov 2008) | 3 lines
  
  Resolve conflicts and reset automerge
................
  r154981 | root | 2008-11-06 12:40:22 -0600 (Thu, 06 Nov 2008) | 14 lines
  
  Merged revisions 154967 via svnmerge from 
  file:///srv/subversion/repos/asterisk/trunk
  
  ........
  r154967 | eliel | 2008-11-06 12:19:00 -0600 (Thu, 06 Nov 2008) | 6 lines
  
  Simplify the output of [See Also].
  Functions are printed without parenthesis like: FUNTION
  Applications are printed with parenthesis like: AppName()
  Cli commands are printed like: 'core show application'
  The other type of references are printed as they are inside the <ref> tag.
  
  ........
................
  r155029 | root | 2008-11-06 14:40:13 -0600 (Thu, 06 Nov 2008) | 24 lines
  
  Merged revisions 155012 via svnmerge from 
  file:///srv/subversion/repos/asterisk/trunk
  
  ................
  r155012 | mmichelson | 2008-11-06 13:46:53 -0600 (Thu, 06 Nov 2008) | 16 lines
  
  Merged revisions 155011 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
  r155011 | mmichelson | 2008-11-06 13:45:52 -0600 (Thu, 06 Nov 2008) | 8 lines
  
  The documentation listed the ability to set 'maxmsg' per
  context. The truth is that you can only set this in the general section
  or per mailbox. Thus I am updating the sample config file to be more
  accurate.
  
  Thanks to sasargen on IRC for bringing up this issue.
  
  
  ........
  
  ................
................
  r155089 | root | 2008-11-06 15:39:39 -0600 (Thu, 06 Nov 2008) | 25 lines
  
  Merged revisions 155066,155079-155080 via svnmerge from 
  file:///srv/subversion/repos/asterisk/trunk
  
  ........
  r155066 | kpfleming | 2008-11-06 14:51:26 -0600 (Thu, 06 Nov 2008) | 5 lines
  
  put ifdef protection around the rest of the libpri function calls that were added at the same time as progress_with_cause
  
  move parsing of the qsig channel mapping configuration option outside ifdef HAVE_PRI_INBANDDISCONNECT and into a properly ifdef'd block
  
  
  ........
  r155079 | kpfleming | 2008-11-06 15:09:24 -0600 (Thu, 06 Nov 2008) | 3 lines
  
  make S_OR and S_COR safe to use even if the parameters are function calls or have side effects. it still bothers me that these are called S_OR and not something like ast_string_or, but that's water over the bridge
  
  
  ........
  r155080 | kpfleming | 2008-11-06 15:12:03 -0600 (Thu, 06 Nov 2008) | 3 lines
  
  coding style/guidelines cleanup, plus use new side-effect safe S_OR
  
  
  ........
................
  r155136 | root | 2008-11-06 17:39:40 -0600 (Thu, 06 Nov 2008) | 11 lines
  
  Merged revisions 155121 via svnmerge from 
  file:///srv/subversion/repos/asterisk/trunk
  
  ........
  r155121 | kpfleming | 2008-11-06 16:49:19 -0600 (Thu, 06 Nov 2008) | 3 lines
  
  don't blindly assume that Darwin and Cygwin need GLOB_ABORTED defined; only define it if it is not already defined
  
  
  ........
................
  r155178 | root | 2008-11-06 20:38:27 -0600 (Thu, 06 Nov 2008) | 10 lines
  
  Merged revisions 155175 via svnmerge from 
  file:///srv/subversion/repos/asterisk/trunk
  
  ........
  r155175 | eliel | 2008-11-06 20:37:47 -0600 (Thu, 06 Nov 2008) | 2 lines
  
  Fix an asterisk crash if no asterisk.conf configuration file is present.
  
  ........
................
  r155216 | root | 2008-11-06 21:39:41 -0600 (Thu, 06 Nov 2008) | 16 lines
  
  Merged revisions 155204,155206 via svnmerge from 
  file:///srv/subversion/repos/asterisk/trunk
  
  ........
  r155204 | eliel | 2008-11-06 21:02:01 -0600 (Thu, 06 Nov 2008) | 4 lines
  
  If 'asterisk.conf' is not found, instead of giving up,
  load documentation for the 'en_US' language (fix my last
  commit).
  
  ........
  r155206 | kpfleming | 2008-11-06 21:09:16 -0600 (Thu, 06 Nov 2008) | 1 line
  
  correct logic error noticed by rmudgett (thanks!)
  ........
................
  r155255 | root | 2008-11-07 09:39:52 -0600 (Fri, 07 Nov 2008) | 19 lines
  
  Merged revisions 155241,155244 via svnmerge from 
  file:///srv/subversion/repos/asterisk/trunk
  
  ........
  r155241 | russell | 2008-11-07 08:50:30 -0600 (Fri, 07 Nov 2008) | 4 lines
  
  Fix some code in chan_sip that was intended to unlink multiple objects from a
  container.  The OBJ_MULTIPLE flag must be provided here.  Otherwise, this would
  only remove a single object.
  
  ........
  r155244 | russell | 2008-11-07 09:01:02 -0600 (Fri, 07 Nov 2008) | 4 lines
  
  Clarify which part of OBJ_MULTIPLE is not implemented, and under what case it
  is perfectly fine to use.  (Inspired by a question I received about my last
  commit.)
  
  ........
................
  r155294 | root | 2008-11-07 10:48:50 -0600 (Fri, 07 Nov 2008) | 24 lines
  
  Merged revisions 155264,155282,155284 via svnmerge from 
  file:///srv/subversion/repos/asterisk/trunk
  
  ........
  r155264 | russell | 2008-11-07 09:42:04 -0600 (Fri, 07 Nov 2008) | 3 lines
  
  Remove a bogus ast_free() that Kevin noticed.  This was probably just left over 
  from pre-astobj2ified chan_sip.
  
  ........
  r155282 | kpfleming | 2008-11-07 09:52:05 -0600 (Fri, 07 Nov 2008) | 1 line
  
  stringfields conversion for struct sip_peer, as requested :-)
  ........
  r155284 | seanbright | 2008-11-07 10:18:52 -0600 (Fri, 07 Nov 2008) | 6 lines
  
  Convert open-coded linked list in indications to the AST_LIST_* macros.  This
  cleans the code up some and should make it more maintainable as time goes on.
  
  Reviewed by Russell, Kevin, Mark M., and Tilghman via ReviewBoard:
  	http://reviewboard.digium.com/r/34/
  
  ........
................
  r155336 | root | 2008-11-07 14:48:41 -0600 (Fri, 07 Nov 2008) | 15 lines
  
  Merged revisions 155324 via svnmerge from 
  file:///srv/subversion/repos/asterisk/trunk
  
  ........
  r155324 | tilghman | 2008-11-07 14:13:32 -0600 (Fri, 07 Nov 2008) | 7 lines
  
  Send call release with unallocated cause instead of normal call clearing, when
  invalid extension is called.
  (closes issue #13408)
   Reported by: adomjan
   Patches: 
         chan_dahdi.c-ss7-unallocated-2 uploaded by adomjan (license 487)
  
  ........
................
  r155371 | root | 2008-11-07 15:48:40 -0600 (Fri, 07 Nov 2008) | 16 lines
  
  Merged revisions 155360 via svnmerge from 
  file:///srv/subversion/repos/asterisk/trunk
  
  ........
  r155360 | mmichelson | 2008-11-07 15:14:49 -0600 (Fri, 07 Nov 2008) | 8 lines
  
  Remove one more instance of the sample configuration
  lying about what's possible. The tz cannot be set in a
  context like this. It can only be set in the general
  section or per-mailbox.
  
  Thanks to sasargen on #asterisk-dev for pointing this out
  
  
  ........
................
  r155418 | root | 2008-11-07 16:50:43 -0600 (Fri, 07 Nov 2008) | 38 lines
  
  Merged revisions 155395,155399,155401 via svnmerge from 
  file:///srv/subversion/repos/asterisk/trunk
  
  ................
  r155395 | tilghman | 2008-11-07 16:03:50 -0600 (Fri, 07 Nov 2008) | 2 lines
  
  Two bugs relating to colnames found by Marquis42 on #asterisk-dev
  
  ................
  r155399 | tilghman | 2008-11-07 16:28:58 -0600 (Fri, 07 Nov 2008) | 14 lines
  
  Merged revisions 155398 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
    r155398 | tilghman | 2008-11-07 16:27:32 -0600 (Fri, 07 Nov 2008) | 7 lines
    
    Clarify error message.
    (closes issue #13809)
     Reported by: denke
     Patches: 
           20081104__bug13809.diff.txt uploaded by Corydon76 (license 14)
     Tested by: denke
  ........
  
  ................
  r155401 | seanbright | 2008-11-07 16:39:30 -0600 (Fri, 07 Nov 2008) | 8 lines
  
  Add ability to pass arbitrary data to the ao2_callback_fn (called from
  ao2_callback and ao2_find).  Currently, passing OBJ_POINTER to either
  of these mandates that the passed 'arg' is a hashable object, making
  searching for an ao2 object based on outside criteria difficult.
  
  Reviewed by Russell and Mark M. via ReviewBoard:
      http://reviewboard.digium.com/r/36/
  
  ................
................
  r155478 | root | 2008-11-07 17:48:54 -0600 (Fri, 07 Nov 2008) | 20 lines
  
  Merged revisions 155467 via svnmerge from 
  file:///srv/subversion/repos/asterisk/trunk
  
  ........
  r155467 | mmichelson | 2008-11-07 17:41:44 -0600 (Fri, 07 Nov 2008) | 12 lines
  
  Set the invite state to INV_CANCELLED in a place that
  makes more sense. Where it was set before, it was impossible
  to actually delay sending a CANCEL if we had not yet received
  a provisional response to an INVITE.
  
  (closes issue #13626)
  Reported by: atis
  Patches:
        13626.patch uploaded by putnopvut (license 60)
  Tested by: atis
  
  
  ........
................
  r155526 | root | 2008-11-08 15:52:35 -0600 (Sat, 08 Nov 2008) | 17 lines
  
  Merged revisions 155513,155516 via svnmerge from 
  file:///srv/subversion/repos/asterisk/trunk
  
  ........
  r155513 | russell | 2008-11-08 15:34:36 -0600 (Sat, 08 Nov 2008) | 3 lines
  
  Remove some code that is basically a no-op.  Code above this already ensures that
  the buffer is terminated.
  
  ........
  r155516 | russell | 2008-11-08 15:46:43 -0600 (Sat, 08 Nov 2008) | 3 lines
  
   - Check for failure when putting the packet in the ast_str
   - fix a spelling error in a header file
  
  ........
................
  r155567 | root | 2008-11-08 19:53:51 -0600 (Sat, 08 Nov 2008) | 22 lines
  
  Merged revisions 155554 via svnmerge from 
  file:///srv/subversion/repos/asterisk/trunk
  
  ................
  r155554 | seanbright | 2008-11-08 19:27:00 -0600 (Sat, 08 Nov 2008) | 14 lines
  
  Merged revisions 155553 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
  r155553 | seanbright | 2008-11-08 20:08:07 -0500 (Sat, 08 Nov 2008) | 6 lines
  
  Use static functions here instead of nested ones.  This requires a small
  change to the ast_bridge_config struct as well.  To understand the reason
  for this change, see the following post:
  
      http://gcc.gnu.org/ml/gcc-help/2008-11/msg00049.html
  
  ........
  
  ................
................
  r155624 | root | 2008-11-08 20:52:20 -0600 (Sat, 08 Nov 2008) | 13 lines
  
  Merged revisions 155590 via svnmerge from 
  file:///srv/subversion/repos/asterisk/trunk
  
  ........
  r155590 | seanbright | 2008-11-08 19:59:59 -0600 (Sat, 08 Nov 2008) | 5 lines
  
  In order to move away from nested function use, some changes to the recently introduced
  ast_channel_search_locked need to be made.  Specifically, the caller needs to be able to
  pass arbitrary data which in turn is passed to the callback.  This patch addresses all
  of the nested functions currently in asterisk trunk.
  
  ........
................
  r155647 | root | 2008-11-08 21:53:02 -0600 (Sat, 08 Nov 2008) | 9 lines
  
  Merged revisions 155637 via svnmerge from 
  file:///srv/subversion/repos/asterisk/trunk
  
  ........
  r155637 | seanbright | 2008-11-08 21:34:28 -0600 (Sat, 08 Nov 2008) | 1 line
  
  Fix some spelling errors, and convert tabs to spaces.
  ........
................
  r155681 | root | 2008-11-09 10:53:26 -0600 (Sun, 09 Nov 2008) | 9 lines
  
  Merged revisions 155671 via svnmerge from 
  file:///srv/subversion/repos/asterisk/trunk
  
  ........
  r155671 | seanbright | 2008-11-09 10:30:29 -0600 (Sun, 09 Nov 2008) | 1 line
  
  Fix this as well.  Pointed out by tzafrir.
  ........
................
  r155724 | root | 2008-11-10 08:54:05 -0600 (Mon, 10 Nov 2008) | 19 lines
  
  Merged revisions 155711 via svnmerge from 
  file:///srv/subversion/repos/asterisk/trunk
  
  ........
  r155711 | eliel | 2008-11-10 07:53:23 -0600 (Mon, 10 Nov 2008) | 11 lines
  
  Move all the XML documentation API from pbx.c to xmldoc.c.
  Export the XML documentation API:
     ast_xmldoc_build_synopsis()
     ast_xmldoc_build_syntax()
     ast_xmldoc_build_description()
     ast_xmldoc_build_seealso()
     ast_xmldoc_build_arguments()
     ast_xmldoc_printable()
     ast_xmldoc_load_documentation()
  
  
  ........
................
  r155774 | root | 2008-11-10 12:53:13 -0600 (Mon, 10 Nov 2008) | 14 lines
  
  Merged revisions 155763 via svnmerge from 
  file:///srv/subversion/repos/asterisk/trunk
  
  ........
  r155763 | tilghman | 2008-11-10 12:04:30 -0600 (Mon, 10 Nov 2008) | 6 lines
  
  Fix memory leak when MALLOC_DEBUG is enabled.
  (closes issue #13864)
   Reported by: eliel
   Patches: 
         readline.c.patch uploaded by eliel (license 64)
  
  ........
................

Added:
    team/rmudgett/misdn_facility/include/asterisk/xmldoc.h
      - copied unchanged from r155774, team/group/issue8824/include/asterisk/xmldoc.h
    team/rmudgett/misdn_facility/main/xmldoc.c
      - copied unchanged from r155774, team/group/issue8824/main/xmldoc.c
Modified:
    team/rmudgett/misdn_facility/   (props changed)
    team/rmudgett/misdn_facility/CHANGES
    team/rmudgett/misdn_facility/apps/app_dial.c
    team/rmudgett/misdn_facility/apps/app_directed_pickup.c
    team/rmudgett/misdn_facility/apps/app_followme.c
    team/rmudgett/misdn_facility/apps/app_macro.c
    team/rmudgett/misdn_facility/apps/app_mixmonitor.c
    team/rmudgett/misdn_facility/apps/app_queue.c
    team/rmudgett/misdn_facility/apps/app_test.c
    team/rmudgett/misdn_facility/channels/chan_agent.c
    team/rmudgett/misdn_facility/channels/chan_console.c
    team/rmudgett/misdn_facility/channels/chan_dahdi.c
    team/rmudgett/misdn_facility/channels/chan_iax2.c
    team/rmudgett/misdn_facility/channels/chan_sip.c
    team/rmudgett/misdn_facility/configs/chan_dahdi.conf.sample
    team/rmudgett/misdn_facility/configs/voicemail.conf.sample
    team/rmudgett/misdn_facility/configure
    team/rmudgett/misdn_facility/configure.ac
    team/rmudgett/misdn_facility/funcs/func_dialgroup.c
    team/rmudgett/misdn_facility/funcs/func_odbc.c
    team/rmudgett/misdn_facility/funcs/func_strings.c
    team/rmudgett/misdn_facility/include/asterisk.h
    team/rmudgett/misdn_facility/include/asterisk/_private.h
    team/rmudgett/misdn_facility/include/asterisk/app.h
    team/rmudgett/misdn_facility/include/asterisk/astobj2.h
    team/rmudgett/misdn_facility/include/asterisk/autoconfig.h.in
    team/rmudgett/misdn_facility/include/asterisk/channel.h
    team/rmudgett/misdn_facility/include/asterisk/indications.h
    team/rmudgett/misdn_facility/include/asterisk/strings.h
    team/rmudgett/misdn_facility/include/asterisk/term.h
    team/rmudgett/misdn_facility/main/Makefile
    team/rmudgett/misdn_facility/main/app.c
    team/rmudgett/misdn_facility/main/asterisk.c
    team/rmudgett/misdn_facility/main/astobj2.c
    team/rmudgett/misdn_facility/main/channel.c
    team/rmudgett/misdn_facility/main/config.c
    team/rmudgett/misdn_facility/main/editline/readline.c
    team/rmudgett/misdn_facility/main/features.c
    team/rmudgett/misdn_facility/main/indications.c
    team/rmudgett/misdn_facility/main/manager.c
    team/rmudgett/misdn_facility/main/pbx.c
    team/rmudgett/misdn_facility/main/taskprocessor.c
    team/rmudgett/misdn_facility/pbx/pbx_config.c
    team/rmudgett/misdn_facility/res/ael/ael.flex
    team/rmudgett/misdn_facility/res/ael/ael_lex.c
    team/rmudgett/misdn_facility/res/res_http_post.c
    team/rmudgett/misdn_facility/res/res_indications.c
    team/rmudgett/misdn_facility/res/res_phoneprov.c
    team/rmudgett/misdn_facility/res/res_timing_pthread.c
    team/rmudgett/misdn_facility/utils/extconf.c
    team/rmudgett/misdn_facility/utils/hashtest2.c

Propchange: team/rmudgett/misdn_facility/
------------------------------------------------------------------------------
Binary property 'branch-1.4-blocked' - no diff available.

Propchange: team/rmudgett/misdn_facility/
------------------------------------------------------------------------------
Binary property 'branch-1.4-merged' - no diff available.

Propchange: team/rmudgett/misdn_facility/
------------------------------------------------------------------------------
--- misdn-facility (original)
+++ misdn-facility Mon Nov 10 14:35:05 2008
@@ -1,1 +1,1 @@
-/team/group/issue8824:1-154683
+/team/group/issue8824:1-155796

Propchange: team/rmudgett/misdn_facility/
------------------------------------------------------------------------------
    svnmerge-integrated = /trunk:1-155773

Modified: team/rmudgett/misdn_facility/CHANGES
URL: http://svn.digium.com/view/asterisk/team/rmudgett/misdn_facility/CHANGES?view=diff&rev=155799&r1=155798&r2=155799
==============================================================================
--- team/rmudgett/misdn_facility/CHANGES (original)
+++ team/rmudgett/misdn_facility/CHANGES Mon Nov 10 14:35:05 2008
@@ -68,6 +68,9 @@
  * Added debugging CLI functions to func_odbc, 'odbc read' and 'odbc write'.
  * func_odbc now may specify an insert query to execute, when the write query
    affects 0 rows (usually indicating that no such row exists).
+ * Added a new dialplan function, LISTFILTER, which permits removing elements
+   from a set list, by name.  Uses the same general syntax as the existing CUT
+   and FIELDQTY dialplan functions, which also manage lists.
 
 Applications
 ------------

Modified: team/rmudgett/misdn_facility/apps/app_dial.c
URL: http://svn.digium.com/view/asterisk/team/rmudgett/misdn_facility/apps/app_dial.c?view=diff&rev=155799&r1=155798&r2=155799
==============================================================================
--- team/rmudgett/misdn_facility/apps/app_dial.c (original)
+++ team/rmudgett/misdn_facility/apps/app_dial.c Mon Nov 10 14:35:05 2008
@@ -1500,6 +1500,27 @@
 	ast_app_options2str64(dial_exec_options, &perm_opts, features->options, sizeof(features->options));
 }
 
+static void end_bridge_callback(void *data)
+{
+	char buf[80];
+	time_t end;
+	struct ast_channel *chan = data;
+
+	time(&end);
+
+	ast_channel_lock(chan);
+	if (chan->cdr->answer.tv_sec) {
+		snprintf(buf, sizeof(buf), "%ld", end - chan->cdr->answer.tv_sec);
+		pbx_builtin_setvar_helper(chan, "ANSWEREDTIME", buf);
+	}
+
+	if (chan->cdr->start.tv_sec) {
+		snprintf(buf, sizeof(buf), "%ld", end - chan->cdr->start.tv_sec);
+		pbx_builtin_setvar_helper(chan, "DIALEDTIME", buf);
+	}
+	ast_channel_unlock(chan);
+}
+
 static int dial_exec_full(struct ast_channel *chan, void *data, struct ast_flags64 *peerflags, int *continue_exec)
 {
 	int res = -1; /* default: error */
@@ -2184,27 +2205,6 @@
 		if (res) { /* some error */
 			res = -1;
 		} else {
-			auto void end_bridge_callback(void);
-			void end_bridge_callback (void)
-			{
-				char buf[80];
-				time_t end;
-
-				time(&end);
-
-				ast_channel_lock(chan);
-				if (chan->cdr->answer.tv_sec) {
-					snprintf(buf, sizeof(buf), "%ld", end - chan->cdr->answer.tv_sec);
-					pbx_builtin_setvar_helper(chan, "ANSWEREDTIME", buf);
-				}
-
-				if (chan->cdr->start.tv_sec) {
-					snprintf(buf, sizeof(buf), "%ld", end - chan->cdr->start.tv_sec);
-					pbx_builtin_setvar_helper(chan, "DIALEDTIME", buf);
-				}
-				ast_channel_unlock(chan);
-			}
-
 			if (ast_test_flag64(peerflags, OPT_CALLEE_TRANSFER))
 				ast_set_flag(&(config.features_callee), AST_FEATURE_REDIRECT);
 			if (ast_test_flag64(peerflags, OPT_CALLER_TRANSFER))
@@ -2229,6 +2229,7 @@
 				ast_set_flag(&(config.features_caller), AST_FEATURE_NO_H_EXTEN);
 
 			config.end_bridge_callback = end_bridge_callback;
+			config.end_bridge_callback_data = chan;
 
 			if (moh) {
 				moh = 0;

Modified: team/rmudgett/misdn_facility/apps/app_directed_pickup.c
URL: http://svn.digium.com/view/asterisk/team/rmudgett/misdn_facility/apps/app_directed_pickup.c?view=diff&rev=155799&r1=155798&r2=155799
==============================================================================
--- team/rmudgett/misdn_facility/apps/app_directed_pickup.c (original)
+++ team/rmudgett/misdn_facility/apps/app_directed_pickup.c Mon Nov 10 14:35:05 2008
@@ -179,45 +179,64 @@
 	return res;
 }
 
+struct pickup_criteria {
+	const char *exten;
+	const char *context;
+};
+
+static int find_by_exten(struct ast_channel *c, void *data)
+{
+	struct pickup_criteria *info = data;
+
+	return (!strcasecmp(c->macroexten, info->exten) || !strcasecmp(c->exten, info->exten)) &&
+		!strcasecmp(c->dialcontext, info->context) &&
+		can_pickup(c);
+}
+
 /* Attempt to pick up specified extension with context */
 static int pickup_by_exten(struct ast_channel *chan, const char *exten, const char *context)
 {
-	int res = -1;
 	struct ast_channel *target = NULL;
-
-	while ((target = ast_channel_walk_locked(target))) {
-		if ((!strcasecmp(target->macroexten, exten) || !strcasecmp(target->exten, exten)) &&
-			!strcasecmp(target->dialcontext, context) &&
-			can_pickup(target)) {
-			res = pickup_do(chan, target);
-			ast_channel_unlock(target);
-			break;
-		}
+	struct pickup_criteria search = {
+		.exten = exten,
+		.context = context,
+	};
+
+	target = ast_channel_search_locked(find_by_exten, &search);
+
+	if (target) {
+		int res = pickup_do(chan, target);
 		ast_channel_unlock(target);
-	}
-
-	return res;
+		target = NULL;
+		return res;
+	}
+
+	return -1;
+}
+
+static int find_by_mark(struct ast_channel *c, void *data)
+{
+	const char *mark = data;
+	const char *tmp;
+
+	return (tmp = pbx_builtin_getvar_helper(c, PICKUPMARK)) &&
+		!strcasecmp(tmp, mark) &&
+		can_pickup(c);
 }
 
 /* Attempt to pick up specified mark */
 static int pickup_by_mark(struct ast_channel *chan, const char *mark)
 {
-	int res = -1;
-	const char *tmp = NULL;
-	struct ast_channel *target = NULL;
-
-	while ((target = ast_channel_walk_locked(target))) {
-		if ((tmp = pbx_builtin_getvar_helper(target, PICKUPMARK)) &&
-			!strcasecmp(tmp, mark) &&
-			can_pickup(target)) {
-			res = pickup_do(chan, target);
-			ast_channel_unlock(target);
-			break;
-		}
+	struct ast_channel *target = ast_channel_search_locked(find_by_mark, (char *) mark);
+
+	if (target) {
+		int res = pickup_do(chan, target);
 		ast_channel_unlock(target);
-	}
-
-	return res;
+		target = NULL;
+		return res;
+	}
+
+	return -1;
 }
 
 /* application entry point for Pickup() */

Modified: team/rmudgett/misdn_facility/apps/app_followme.c
URL: http://svn.digium.com/view/asterisk/team/rmudgett/misdn_facility/apps/app_followme.c?view=diff&rev=155799&r1=155798&r2=155799
==============================================================================
--- team/rmudgett/misdn_facility/apps/app_followme.c (original)
+++ team/rmudgett/misdn_facility/apps/app_followme.c Mon Nov 10 14:35:05 2008
@@ -971,6 +971,27 @@
 	return new;
 }
 
+static void end_bridge_callback(void *data)
+{
+	char buf[80];
+	time_t end;
+	struct ast_channel *chan = data;
+
+	time(&end);
+
+	ast_channel_lock(chan);
+	if (chan->cdr->answer.tv_sec) {
+		snprintf(buf, sizeof(buf), "%ld", end - chan->cdr->answer.tv_sec);
+		pbx_builtin_setvar_helper(chan, "ANSWEREDTIME", buf);
+	}
+
+	if (chan->cdr->start.tv_sec) {
+		snprintf(buf, sizeof(buf), "%ld", end - chan->cdr->start.tv_sec);
+		pbx_builtin_setvar_helper(chan, "DIALEDTIME", buf);
+	}
+	ast_channel_unlock(chan);
+}
+
 static int app_exec(struct ast_channel *chan, void *data)
 {
 	struct fm_args targs;
@@ -1085,27 +1106,6 @@
 			ast_stream_and_wait(chan, targs.sorryprompt, "");
 		res = 0;
 	} else {
-		auto void end_bridge_callback(void);
-		void end_bridge_callback (void)
-		{
-			char buf[80];
-			time_t end;
-
-			time(&end);
-
-			ast_channel_lock(chan);
-			if (chan->cdr->answer.tv_sec) {
-				snprintf(buf, sizeof(buf), "%ld", end - chan->cdr->answer.tv_sec);
-				pbx_builtin_setvar_helper(chan, "ANSWEREDTIME", buf);
-			}
-
-			if (chan->cdr->start.tv_sec) {
-				snprintf(buf, sizeof(buf), "%ld", end - chan->cdr->start.tv_sec);
-				pbx_builtin_setvar_helper(chan, "DIALEDTIME", buf);
-			}
-			ast_channel_unlock(chan);
-		}
-
 		caller = chan;
 		outbound = targs.outbound;
 		/* Bridge the two channels. */
@@ -1115,6 +1115,7 @@
 		ast_set_flag(&(config.features_callee), AST_FEATURE_AUTOMON);
 		ast_set_flag(&(config.features_caller), AST_FEATURE_AUTOMON);
 		config.end_bridge_callback = end_bridge_callback;
+		config.end_bridge_callback_data = chan;
 
 		ast_moh_stop(caller);
 		/* Be sure no generators are left on it */

Modified: team/rmudgett/misdn_facility/apps/app_macro.c
URL: http://svn.digium.com/view/asterisk/team/rmudgett/misdn_facility/apps/app_macro.c?view=diff&rev=155799&r1=155798&r2=155799
==============================================================================
--- team/rmudgett/misdn_facility/apps/app_macro.c (original)
+++ team/rmudgett/misdn_facility/apps/app_macro.c Mon Nov 10 14:35:05 2008
@@ -37,66 +37,123 @@
 #include "asterisk/utils.h"
 #include "asterisk/lock.h"
 
+/*** DOCUMENTATION
+	<application name="Macro" language="en_US">
+		<synopsis>
+			Macro Implementation.
+		</synopsis>
+		<syntax>
+			<parameter name="name" required="true">
+				<para>The name of the macro</para>
+			</parameter>
+			<parameter name="args">
+				<argument name="arg1" required="true" />
+				<argument name="arg2" multiple="true" />
+			</parameter>
+		</syntax>
+		<description>
+			<para>Executes a macro using the context macro-<replaceable>name</replaceable>,
+			jumping to the <literal>s</literal> extension of that context and executing each step,
+			then returning when the steps end.</para>
+			<para>The calling extension, context, and priority are stored in <variable>MACRO_EXTEN</variable>,
+			<variable>MACRO_CONTEXT</variable> and <variable>MACRO_PRIORITY</variable> respectively. Arguments
+			become <variable>ARG1</variable>, <variable>ARG2</variable>, etc in the macro context.</para>
+			<para>If you Goto out of the Macro context, the Macro will terminate and control will be returned
+			at the location of the Goto.</para>
+			<para>If <variable>MACRO_OFFSET</variable> is set at termination, Macro will attempt to continue
+			at priority MACRO_OFFSET + N + 1 if such a step exists, and N + 1 otherwise.</para>
+			<para>Extensions: While a macro is being executed, it becomes the current context. This means that if
+			a hangup occurs, for instance, that the macro will be searched for an <literal>h</literal> extension,
+			NOT the context from which the macro was called. So, make sure to define all appropriate extensions
+			in your macro! (Note: AEL does not use macros)</para>
+			<warning><para>Because of the way Macro is implemented (it executes the priorities contained within
+			it via sub-engine), and a fixed per-thread memory stack allowance, macros are limited to 7 levels
+			of nesting (macro calling macro calling macro, etc.); It may be possible that stack-intensive
+			applications in deeply nested macros could cause asterisk to crash earlier than this limit.
+			It is advised that if you need to deeply nest macro calls, that you use the Gosub application
+			(now allows arguments like a Macro) with explict Return() calls instead.</para></warning>
+		</description>
+		<see-also>
+			<ref type="application">MacroExit</ref>
+			<ref type="application">Goto</ref>
+			<ref type="application">Gosub</ref>
+		</see-also>
+	</application>
+	<application name="MacroIf" language="en_US">
+		<synopsis>
+			Conditional Macro implementation.
+		</synopsis>
+		<syntax argsep="?">
+			<parameter name="expr" required="true" />
+			<parameter name="destination" required="true" argsep=":">
+				<argument name="macroiftrue" required="true">
+					<argument name="macroiftrue" required="true" />
+					<argument name="arg1" multiple="true" />
+				</argument>
+				<argument name="macroiffalse">
+					<argument name="macroiffalse" required="true" />
+					<argument name="arg1" multiple="true" />
+				</argument>
+			</parameter>
+		</syntax>
+		<description>
+			<para>Executes macro defined in <replaceable>macroiftrue</replaceable> if
+			<replaceable>expr</replaceable> is true (otherwise <replaceable>macroiffalse</replaceable>
+			if provided)</para>
+			<para>Arguments and return values as in application Macro()</para>
+		</description>
+		<see-also>
+			<ref type="application">GotoIf</ref>
+			<ref type="application">GosubIf</ref>
+			<ref type="function">IF</ref>
+		</see-also>
+	</application>
+	<application name="MacroExclusive" language="en_US">
+		<synopsis>
+			Exclusive Macro Implementation.
+		</synopsis>
+		<syntax>
+			<parameter name="name" required="true">
+				<para>The name of the macro</para>
+			</parameter>
+			<parameter name="arg1" />
+			<parameter name="arg2" multiple="true" />
+		</syntax>
+		<description>
+			<para>Executes macro defined in the context macro-<replaceable>name</replaceable>.
+			Only one call at a time may run the macro. (we'll wait if another call is busy
+			executing in the Macro)</para>
+			<para>Arguments and return values as in application Macro()</para>
+		</description>
+		<see-also>
+			<ref type="application">Macro</ref>
+		</see-also>
+	</application>
+	<application name="MacroExit" language="en_US">
+		<synopsis>
+			Exit from Macro.
+		</synopsis>
+		<syntax />
+		<description>
+			<para>Causes the currently running macro to exit as if it had
+			ended normally by running out of priorities to execute.
+			If used outside a macro, will likely cause unexpected behavior.</para>
+		</description>
+		<see-also>
+			<ref type="application">Macro</ref>
+		</see-also>
+	</application>
+ ***/
+
 #define MAX_ARGS 80
 
 /* special result value used to force macro exit */
 #define MACRO_EXIT_RESULT 1024
-
-static char *descrip =
-"  Macro(macroname,arg1,arg2...): Executes a macro using the context\n"
-"'macro-<macroname>', jumping to the 's' extension of that context and\n"
-"executing each step, then returning when the steps end. \n"
-"The calling extension, context, and priority are stored in ${MACRO_EXTEN}, \n"
-"${MACRO_CONTEXT} and ${MACRO_PRIORITY} respectively.  Arguments become\n"
-"${ARG1}, ${ARG2}, etc in the macro context.\n"
-"If you Goto out of the Macro context, the Macro will terminate and control\n"
-"will be returned at the location of the Goto.\n"
-"If ${MACRO_OFFSET} is set at termination, Macro will attempt to continue\n"
-"at priority MACRO_OFFSET + N + 1 if such a step exists, and N + 1 otherwise.\n"
-"Extensions: While a macro is being executed, it becomes the current context.\n"
-"            This means that if a hangup occurs, for instance, that the macro\n"
-"            will be searched for an 'h' extension, NOT the context from which\n"
-"            the macro was called. So, make sure to define all appropriate\n"
-"            extensions in your macro! (Note: AEL does not use macros)\n"
-"WARNING: Because of the way Macro is implemented (it executes the priorities\n"
-"         contained within it via sub-engine), and a fixed per-thread\n"
-"         memory stack allowance, macros are limited to 7 levels\n"
-"         of nesting (macro calling macro calling macro, etc.); It\n"
-"         may be possible that stack-intensive applications in deeply nested macros\n"
-"         could cause asterisk to crash earlier than this limit. It is advised that\n"
-"         if you need to deeply nest macro calls, that you use the Gosub application\n"
-"         (now allows arguments like a Macro) with explict Return() calls instead.\n";
-
-static char *if_descrip =
-"  MacroIf(<expr>?macroname_a[,arg1][:macroname_b[,arg1]])\n"
-"Executes macro defined in <macroname_a> if <expr> is true\n"
-"(otherwise <macroname_b> if provided)\n"
-"Arguments and return values as in application Macro()\n";
-
-static char *exclusive_descrip =
-"  MacroExclusive(macroname,arg1,arg2...):\n"
-"Executes macro defined in the context 'macro-macroname'\n"
-"Only one call at a time may run the macro.\n"
-"(we'll wait if another call is busy executing in the Macro)\n"
-"Arguments and return values as in application Macro()\n";
-
-static char *exit_descrip =
-"  MacroExit():\n"
-"Causes the currently running macro to exit as if it had\n"
-"ended normally by running out of priorities to execute.\n"
-"If used outside a macro, will likely cause unexpected\n"
-"behavior.\n";
 
 static char *app = "Macro";
 static char *if_app = "MacroIf";
 static char *exclusive_app = "MacroExclusive";
 static char *exit_app = "MacroExit";
-
-static char *synopsis = "Macro Implementation";
-static char *if_synopsis = "Conditional Macro Implementation";
-static char *exclusive_synopsis = "Exclusive Macro Implementation";
-static char *exit_synopsis = "Exit From Macro";
-
 
 static struct ast_exten *find_matching_priority(struct ast_context *c, const char *exten, int priority, const char *callerid)
 {
@@ -524,10 +581,10 @@
 {
 	int res;
 
-	res = ast_register_application(exit_app, macro_exit_exec, exit_synopsis, exit_descrip);
-	res |= ast_register_application(if_app, macroif_exec, if_synopsis, if_descrip);
-	res |= ast_register_application(exclusive_app, macroexclusive_exec, exclusive_synopsis, exclusive_descrip);
-	res |= ast_register_application(app, macro_exec, synopsis, descrip);
+	res = ast_register_application_xml(exit_app, macro_exit_exec);
+	res |= ast_register_application_xml(if_app, macroif_exec);
+	res |= ast_register_application_xml(exclusive_app, macroexclusive_exec);
+	res |= ast_register_application_xml(app, macro_exec);
 
 	return res;
 }

Modified: team/rmudgett/misdn_facility/apps/app_mixmonitor.c
URL: http://svn.digium.com/view/asterisk/team/rmudgett/misdn_facility/apps/app_mixmonitor.c?view=diff&rev=155799&r1=155798&r2=155799
==============================================================================
--- team/rmudgett/misdn_facility/apps/app_mixmonitor.c (original)
+++ team/rmudgett/misdn_facility/apps/app_mixmonitor.c Mon Nov 10 14:35:05 2008
@@ -99,6 +99,12 @@
 				</variable>
 			</variablelist>	
 		</description>
+		<see-also>
+			<ref type="application">Monitor</ref>
+			<ref type="application">StopMixMonitor</ref>
+			<ref type="application">PauseMonitor</ref>
+			<ref type="application">UnpauseMonitor</ref>
+		</see-also>
 	</application>
 	<application name="StopMixMonitor" language="en_US">
 		<synopsis>
@@ -109,6 +115,9 @@
 			<para>Stops the audio recording that was started with a call to <literal>MixMonitor()</literal>
 			on the current channel.</para>
 		</description>
+		<see-also>
+			<ref type="application">MixMonitor</ref>
+		</see-also>
 	</application>
 		
  ***/

Modified: team/rmudgett/misdn_facility/apps/app_queue.c
URL: http://svn.digium.com/view/asterisk/team/rmudgett/misdn_facility/apps/app_queue.c?view=diff&rev=155799&r1=155798&r2=155799
==============================================================================
--- team/rmudgett/misdn_facility/apps/app_queue.c (original)
+++ team/rmudgett/misdn_facility/apps/app_queue.c Mon Nov 10 14:35:05 2008
@@ -860,7 +860,7 @@
 	return ast_str_hash(q->name);
 }
 
-static int queue_cmp_cb(void *obj, void *arg, int flags)
+static int queue_cmp_cb(void *obj, void *arg, void *data, int flags)
 {
 	struct call_queue *q = obj, *q2 = arg;
 	return !strcasecmp(q->name, q2->name) ? CMP_MATCH | CMP_STOP : 0;
@@ -1133,7 +1133,7 @@
 	return ret;
 }
 
-static int member_cmp_fn(void *obj1, void *obj2, int flags)
+static int member_cmp_fn(void *obj1, void *obj2, void *data, int flags)
 {
 	struct member *mem1 = obj1, *mem2 = obj2;
 	return strcasecmp(mem1->interface, mem2->interface) ? 0 : CMP_MATCH | CMP_STOP;
@@ -1647,7 +1647,7 @@
 	char tmpbuf[64];	/* Must be longer than the longest queue param name. */
 
 	/* Static queues override realtime. */
-	if ((q = ao2_find(queues, &tmpq, OBJ_POINTER))) {
+	if ((q = ao2_find(queues, &tmpq, NULL, OBJ_POINTER))) {
 		ao2_lock(q);
 		if (!q->realtime) {
 			if (q->dead) {
@@ -1774,7 +1774,7 @@
 	};
 
 	/* Find the queue in the in-core list first. */
-	q = ao2_find(queues, &tmpq, OBJ_POINTER);
+	q = ao2_find(queues, &tmpq, NULL, OBJ_POINTER);
 
 	if (!q || q->realtime) {
 		/*! \note Load from realtime before taking the "queues" container lock, to avoid blocking all
@@ -2245,7 +2245,7 @@
 		}
 		ao2_lock(q);
 		if (q->count && q->members) {
-			if ((mem = ao2_find(q->members, member, OBJ_POINTER))) {
+			if ((mem = ao2_find(q->members, member, NULL, OBJ_POINTER))) {
 				ast_debug(1, "Found matching member %s in queue '%s'\n", mem->interface, q->name);
 				if (q->weight > rq->weight) {
 					ast_debug(1, "Queue '%s' (weight %d, calls %d) is preferred over '%s' (weight %d, calls %d)\n", q->name, q->weight, q->count, rq->name, rq->weight, rq->count);
@@ -3187,7 +3187,7 @@

[... 5769 lines stripped ...]



More information about the asterisk-commits mailing list