Skip to content
Snippets Groups Projects
  1. Apr 17, 2015
    • Mark Michelson's avatar
      Detect potential forwarding loops based on count. · aae45acb
      Mark Michelson authored
      A potential problem that can arise is the following:
      
      * Bob's phone is programmed to automatically forward to Carol.
      * Carol's phone is programmed to automatically forward to Bob.
      * Alice calls Bob.
      
      If left unchecked, this results in an endless loops of call forwards
      that would eventually result in some sort of fiery crash.
      
      Asterisk's method of solving this issue was to track which interfaces
      had been dialed. If a destination were dialed a second time, then
      the attempt to call that destination would fail since a loop was
      detected.
      
      The problem with this method is that call forwarding has evolved. Some
      SIP phones allow for a user to manually forward an incoming call to an
      ad-hoc destination. This can mean that:
      
      * There are legitimate use cases where a device may be dialed multiple
      times, or
      * There can be human error when forwarding calls.
      
      This change removes the old method of detecting forwarding loops in
      favor of keeping a count of the number of destinations a channel has
      dialed on a particular branch of a call. If the number exceeds the
      set number of max forwards, then the call fails. This approach has
      the following advantages over the old:
      
      * It is much simpler.
      * It can detect loops involving local channels.
      * It is user configurable.
      
      The only disadvantage it has is that in the case where there is a
      legitimate forwarding loop present, it takes longer to detect it.
      However, the forwarding loop is still properly detected and the
      call is cleaned up as it should be.
      
      Address review feedback on gerrit.
      
      * Correct "mfgium" to "Digium"
      * Decrement max forwards by one in the case where allocation of the
        max forwards datastore is required.
      * Remove irrelevant code change from pjsip_global_headers.c
      
      ASTERISK-24958 #close
      
      Change-Id: Ia7e4b7cd3bccfbd34d9a859838356931bba56c23
      aae45acb
  2. Apr 13, 2015
    • Matt Jordan's avatar
      git migration: Refactor the ASTERISK_FILE_VERSION macro · 4a582616
      Matt Jordan authored
      Git does not support the ability to replace a token with a version
      string during check-in. While it does have support for replacing a
      token on clone, this is somewhat sub-optimal: the token is replaced
      with the object hash, which is not particularly easy for human
      consumption. What's more, in practice, the source file version was often
      not terribly useful. Generally, when triaging bugs, the overall version
      of Asterisk is far more useful than an individual SVN version of a file. As a
      result, this patch removes Asterisk's support for showing source file
      versions.
      
      Specifically, it does the following:
      
      * Rename ASTERISK_FILE_VERSION macro to ASTERISK_REGISTER_FILE, and
        remove passing the version in with the macro. Other facilities
        than 'core show file version' make use of the file names, such as
        setting a debug level only on a specific file. As such, the act of
        registering source files with the Asterisk core still has use. The
        macro rename now reflects the new macro purpose.
      
      * main/asterisk:
        - Refactor the file_version structure to reflect that it no longer
          tracks a version field.
        - Remove the "core show file version" CLI command. Without the file
          version, it is no longer useful.
        - Remove the ast_file_version_find function. The file version is no
          longer tracked.
        - Rename ast_register_file_version/ast_unregister_file_version to
          ast_register_file/ast_unregister_file, respectively.
      
      * main/manager: Remove value from the Version key of the ModuleCheck
        Action. The actual key itself has not been removed, as doing so would
        absolutely constitute a backwards incompatible change. However, since
        the file version is no longer tracked, there is no need to attempt to
        include it in the Version key.
      
      * UPGRADE: Add notes for:
        - Modification to the ModuleCheck AMI Action
        - Removal of the "core show file version" CLI command
      
      Change-Id: I6cf0ff280e1668bf4957dc21f32a5ff43444a40e
      4a582616
  3. Apr 06, 2015
  4. Mar 26, 2015
  5. Aug 06, 2014
  6. Jul 20, 2014
  7. May 09, 2014
  8. Mar 07, 2014
    • Scott Griepentrog's avatar
      uniqueid: channel linkedid, ami, ari object creation with id's · 80ef9a21
      Scott Griepentrog authored
      Much needed was a way to assign id to objects on creation, and
      much change was necessary to accomplish it.  Channel uniqueids
      and linkedids are split into separate string and creation time
      components without breaking linkedid propgation.  This allowed
      the uniqueid to be specified by the user interface - and those
      values are now carried through to channel creation, adding the
      assignedids value to every function in the chain including the
      channel drivers. For local channels, the second channel can be
      specified or left to default to a ;2 suffix of first.  In ARI,
      bridge, playback, and snoop objects can also be created with a
      specified uniqueid.
      
      Along the way, the args order to allocating channels was fixed
      in chan_mgcp and chan_gtalk, and linkedid is no longer lost as
      masquerade occurs.
      
      (closes issue ASTERISK-23120)
      Review: https://reviewboard.asterisk.org/r/3191/
      ........
      
      Merged revisions 410157 from http://svn.asterisk.org/svn/asterisk/branches/12
      
      
      git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@410158 65c4cc65-6c06-0410-ace0-fbb531ad65f3
      80ef9a21
  9. Oct 03, 2013
  10. Sep 30, 2013
    • David M. Lee's avatar
      Multiple revisions 399887,400138,400178,400180-400181 · 2de42c2a
      David M. Lee authored
      ........
        r399887 | dlee | 2013-09-26 10:41:47 -0500 (Thu, 26 Sep 2013) | 1 line
        
        Minor performance bump by not allocate manager variable struct if we don't need it
      ........
        r400138 | dlee | 2013-09-30 10:24:00 -0500 (Mon, 30 Sep 2013) | 23 lines
        
        Stasis performance improvements
        
        This patch addresses several performance problems that were found in
        the initial performance testing of Asterisk 12.
        
        The Stasis dispatch object was allocated as an AO2 object, even though
        it has a very confined lifecycle. This was replaced with a straight
        ast_malloc().
        
        The Stasis message router was spending an inordinate amount of time
        searching hash tables. In this case, most of our routers had 6 or
        fewer routes in them to begin with. This was replaced with an array
        that's searched linearly for the route.
        
        We more heavily rely on AO2 objects in Asterisk 12, and the memset()
        in ao2_ref() actually became noticeable on the profile. This was
        #ifdef'ed to only run when AO2_DEBUG was enabled.
        
        After being misled by an erroneous comment in taskprocessor.c during
        profiling, the wrong comment was removed.
        
        Review: https://reviewboard.asterisk.org/r/2873/
      ........
        r400178 | dlee | 2013-09-30 13:26:27 -0500 (Mon, 30 Sep 2013) | 24 lines
        
        Taskprocessor optimization; switch Stasis to use taskprocessors
        
        This patch optimizes taskprocessor to use a semaphore for signaling,
        which the OS can do a better job at managing contention and waiting
        that we can with a mutex and condition.
        
        The taskprocessor execution was also slightly optimized to reduce the
        number of locks taken.
        
        The only observable difference in the taskprocessor implementation is
        that when the final reference to the taskprocessor goes away, it will
        execute all tasks to completion instead of discarding the unexecuted
        tasks.
        
        For systems where unnamed semaphores are not supported, a really
        simple semaphore implementation is provided. (Which gives identical
        performance as the original taskprocessor implementation).
        
        The way we ended up implementing Stasis caused the threadpool to be a
        burden instead of a boost to performance. This was switched to just
        use taskprocessors directly for subscriptions.
        
        Review: https://reviewboard.asterisk.org/r/2881/
      ........
        r400180 | dlee | 2013-09-30 13:39:34 -0500 (Mon, 30 Sep 2013) | 28 lines
        
        Optimize how Stasis forwards are dispatched
        
        This patch optimizes how forwards are dispatched in Stasis.
        
        Originally, forwards were dispatched as subscriptions that are invoked
        on the publishing thread. This did not account for the vast number of
        forwards we would end up having in the system, and the amount of work it
        would take to walk though the forward subscriptions.
        
        This patch modifies Stasis so that rather than walking the tree of
        forwards on every dispatch, when forwards and subscriptions are changed,
        the subscriber list for every topic in the tree is changed.
        
        This has a couple of benefits. First, this reduces the workload of
        dispatching messages. It also reduces contention when dispatching to
        different topics that happen to forward to the same aggregation topic
        (as happens with all of the channel, bridge and endpoint topics).
        
        Since forwards are no longer subscriptions, the bulk of this patch is
        simply changing stasis_subscription objects to stasis_forward objects
        (which, admittedly, I should have done in the first place.)
        
        Since this required me to yet again put in a growing array, I finally
        abstracted that out into a set of ast_vector macros in
        asterisk/vector.h.
        
        Review: https://reviewboard.asterisk.org/r/2883/
      ........
        r400181 | dlee | 2013-09-30 13:48:57 -0500 (Mon, 30 Sep 2013) | 28 lines
        
        Remove dispatch object allocation from Stasis publishing
        
        While looking for areas for performance improvement, I realized that an
        unused feature in Stasis was negatively impacting performance.
        
        When a message is sent to a subscriber, a dispatch object is allocated
        for the dispatch, containing the topic the message was published to, the
        subscriber the message is being sent to, and the message itself.
        
        The topic is actually unused by any subscriber in Asterisk today. And
        the subscriber is associated with the taskprocessor the message is being
        dispatched to.
        
        First, this patch removes the unused topic parameter from Stasis
        subscription callbacks.
        
        Second, this patch introduces the concept of taskprocessor local data,
        data that may be set on a taskprocessor and provided along with the data
        pointer when a task is pushed using the ast_taskprocessor_push_local()
        call. This allows the task to have both data specific to that
        taskprocessor, in addition to data specific to that invocation.
        
        With those two changes, the dispatch object can be removed completely,
        and the message is simply refcounted and sent directly to the
        taskprocessor.
        
        Review: https://reviewboard.asterisk.org/r/2884/
      ........
      
      Merged revisions 399887,400138,400178,400180-400181 from http://svn.asterisk.org/svn/asterisk/branches/12
      
      
      git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400186 65c4cc65-6c06-0410-ace0-fbb531ad65f3
      2de42c2a
  11. Aug 17, 2013
    • Kinsey Moore's avatar
      Strip down the old event system · 59753b1e
      Kinsey Moore authored
      This removes unused code, event types, IE pltypes, and event IE types
      where possible and makes several functions private that were once
      public. This includes a renumbering of the remaining event and IE types
      which breaks binary compatibility with previous versions. The last
      remaining consumers of the old event system (or parts thereof) are
      main/security_events.c, res/res_security_log.c, tests/test_cel.c,
      tests/test_event.c, main/cel.c, and the CEL backends.
      
      Review: https://reviewboard.asterisk.org/r/2703/
      (closes issue ASTERISK-22139)
      
      
      git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@396887 65c4cc65-6c06-0410-ace0-fbb531ad65f3
      59753b1e
  12. Jul 19, 2013
  13. Apr 16, 2013
  14. Jan 02, 2013
    • Automerge script's avatar
      Merged revisions 378322 via svnmerge from · 675914bb
      Automerge script authored
      file:///srv/subversion/repos/asterisk/trunk
      
      ................
        r378322 | mjordan | 2013-01-02 12:11:59 -0600 (Wed, 02 Jan 2013) | 33 lines
        
        Prevent exhaustion of system resources through exploitation of event cache
        
        Asterisk maintains an internal cache for devices in the event subsystem. The
        device state cache holds the state of each device known to Asterisk, such that
        consumers of device state information can query for the last known state for
        a particular device, even if it is not part of an active call. The concept of
        a device in Asterisk can include entities that do not have a physical
        representation. One way that this occurred was when anonymous calls are allowed
        in Asterisk. A device was automatically created and stored in the cache for
        each anonymous call that occurred; this was possible in the SIP and IAX2
        channel drivers and through channel drivers that utilized the
        res_jabber/res_xmpp resource modules (Gtalk, Jingle, and Motif). These devices
        are never removed from the system, allowing anonymous calls to potentially
        exhaust a system's resources.
        
        This patch changes the event cache subsystem and device state management to
        no longer cache devices that are not associated with a physical entity.
        
        (issue ASTERISK-20175)
        Reported by: Russell Bryant, Leif Madsen, Joshua Colp
        Tested by: kmoore
        patches:
          event-cachability-3.diff uploaded by jcolp (license 5000)
        ........
        
        Merged revisions 378303 from http://svn.asterisk.org/svn/asterisk/branches/1.8
        ........
        
        Merged revisions 378320 from http://svn.asterisk.org/svn/asterisk/branches/10
        ........
        
        Merged revisions 378321 from http://svn.asterisk.org/svn/asterisk/branches/11
      ................
      
      
      git-svn-id: https://origsvn.digium.com/svn/asterisk/team/mmichelson/threadpool@378329 65c4cc65-6c06-0410-ace0-fbb531ad65f3
      675914bb
    • Matthew Jordan's avatar
      Prevent exhaustion of system resources through exploitation of event cache · 8fb5bdce
      Matthew Jordan authored
      Asterisk maintains an internal cache for devices in the event subsystem. The
      device state cache holds the state of each device known to Asterisk, such that
      consumers of device state information can query for the last known state for
      a particular device, even if it is not part of an active call. The concept of
      a device in Asterisk can include entities that do not have a physical
      representation. One way that this occurred was when anonymous calls are allowed
      in Asterisk. A device was automatically created and stored in the cache for
      each anonymous call that occurred; this was possible in the SIP and IAX2
      channel drivers and through channel drivers that utilized the
      res_jabber/res_xmpp resource modules (Gtalk, Jingle, and Motif). These devices
      are never removed from the system, allowing anonymous calls to potentially
      exhaust a system's resources.
      
      This patch changes the event cache subsystem and device state management to
      no longer cache devices that are not associated with a physical entity.
      
      (issue ASTERISK-20175)
      Reported by: Russell Bryant, Leif Madsen, Joshua Colp
      Tested by: kmoore
      patches:
        event-cachability-3.diff uploaded by jcolp (license 5000)
      ........
      
      Merged revisions 378303 from http://svn.asterisk.org/svn/asterisk/branches/1.8
      ........
      
      Merged revisions 378320 from http://svn.asterisk.org/svn/asterisk/branches/10
      ........
      
      Merged revisions 378321 from http://svn.asterisk.org/svn/asterisk/branches/11
      
      
      git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@378322 65c4cc65-6c06-0410-ace0-fbb531ad65f3
      8fb5bdce
  15. Dec 03, 2012
  16. Nov 02, 2012
  17. Oct 18, 2012
  18. Oct 15, 2012
  19. Oct 03, 2012
  20. Oct 02, 2012
  21. Sep 22, 2012
    • Andrew Latham's avatar
      Doxygen Updates Janitor Work · fd98835f
      Andrew Latham authored
      * Whitespace, doc-blocks, spelling, case, missing and incorrect tags.
      * Add cleanup to Makefile for the Doxygen configuration update
      * Start updating Doxygen configuration for cleaner output
      * Enable inclusion of configuration files into documentation
      * remove mantisworkflow...
      * update documentation README
      * Add markup to Tilghman's email and talk with him about updating his email, he knows...
      * no code changes on this commit other than the mentioned Makefile change
      
      (issue ASTERISK-20259)
      
      
      git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@373384 65c4cc65-6c06-0410-ace0-fbb531ad65f3
      fd98835f
  22. Sep 21, 2012
    • Andrew Latham's avatar
      Doxygen Updates - janitor work · 6f61cb50
      Andrew Latham authored
      Doxygen updates including mistakes, misspellings, missing parameters, updates for Doxygen style.  Some missing txt file links are removed but their content or essense will be included in some later updates.  A majority of the txt files were removed in the 1.6 era but never noted. The HR and EXTREF are simple changes that make the documentation more compatable with more versions of Doxygen.
      
      Further updates coming.
      
      (issue ASTERISK-20259)
      
      
      git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@373330 65c4cc65-6c06-0410-ace0-fbb531ad65f3
      6f61cb50
  23. Jul 18, 2012
  24. Jun 22, 2012
  25. Jun 15, 2012
    • Kevin P. Fleming's avatar
      Multiple revisions 369001-369002 · 166b4e2b
      Kevin P. Fleming authored
      ........
        r369001 | kpfleming | 2012-06-15 10:56:08 -0500 (Fri, 15 Jun 2012) | 11 lines
        
        Add support-level indications to many more source files.
        
        Since we now have tools that scan through the source tree looking for files
        with specific support levels, we need to ensure that every file that is
        a component of a 'core' or 'extended' module (or the main Asterisk binary)
        is explicitly marked with its support level. This patch adds support-level
        indications to many more source files in tree, but avoids adding them to
        third-party libraries that are included in the tree and to source files
        that don't end up involved in Asterisk itself.
      ........
        r369002 | kpfleming | 2012-06-15 10:57:14 -0500 (Fri, 15 Jun 2012) | 3 lines
        
        Add a script to enable finding source files without support-levels defined.
      ........
      
      Merged revisions 369001-369002 from http://svn.asterisk.org/svn/asterisk/branches/1.8
      ........
      
      Merged revisions 369005 from http://svn.asterisk.org/svn/asterisk/branches/10
      
      
      git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@369013 65c4cc65-6c06-0410-ace0-fbb531ad65f3
      166b4e2b
  26. Jun 14, 2012
    • Richard Mudgett's avatar
      Allow non-normal execution routines to be able to run on hungup channels. · f8746d00
      Richard Mudgett authored
      * Make non-normal dialplan execution routines be able to run on a hung up
      channel.  This is preparation work for hangup handler routines.
      
      * Fixed ability to support relative non-normal dialplan execution
      routines.  (i.e., The context and exten are optional for the specified
      dialplan location.) Predial routines are the only non-normal routines that
      it makes sense to optionally omit the context and exten.  Setting a hangup
      handler also needs this ability.
      
      * Fix Return application being able to restore a dialplan location
      exactly.  Channels without a PBX may not have context or exten set.
      
      * Fixes non-normal execution routines like connected line interception and
      predial leaving the dialplan execution stack unbalanced.  Errors like
      missing Return statements, popping too many stack frames using StackPop,
      or an application returning non-zero could leave the dialplan stack
      unbalanced.
      
      * Fixed the AGI gosub application so it cleans up the dialplan execution
      stack and handles the autoloop priority increments correctly.
      
      * Eliminated the need for the gosub_virtual_context return location.
      
      Review: https://reviewboard.asterisk.org/r/1984/
      
      
      git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@368985 65c4cc65-6c06-0410-ace0-fbb531ad65f3
      f8746d00
  27. Mar 02, 2012
  28. Feb 29, 2012
  29. Feb 27, 2012
  30. Feb 21, 2012
  31. Feb 20, 2012
  32. Feb 13, 2012
  33. Jan 09, 2012
    • Terry Wilson's avatar
      Replace direct access to channel name with accessor functions · 04da92c3
      Terry Wilson authored
      There are many benefits to making the ast_channel an opaque handle, from
      increasing maintainability to presenting ways to kill masquerades. This patch
      kicks things off by taking things a field at a time, renaming the field to
      '__do_not_use_${fieldname}' and then writing setters/getters and converting the
      existing code to using them. When all fields are done, we can move ast_channel
      to a C file from channel.h and lop off the '__do_not_use_'.
      
      This patch sets up main/channel_interal_api.c to be the only file that actually
      accesses the ast_channel's fields directly. The intent would be for any API
      functions in channel.c to use the accessor functions. No more monkeying around
      with channel internals. We should use our own APIs.
      
      The interesting changes in this patch are the addition of
      channel_internal_api.c, the moving of the AST_DATA stuff from channel.c to
      channel_internal_api.c (note: the AST_DATA stuff will have to be reworked to
      use accessor functions when ast_channel is really opaque), and some re-working
      of the way channel iterators/callbacks are handled so as to avoid creating fake
      ast_channels on the stack to pass in matching data by directly accessing fields
      (since "name" is a stringfield and the fake channel doesn't init the
      stringfields, you can't use the ast_channel_name_set() function). I went with
      ast_channel_name(chan) for a getter, and ast_channel_name_set(chan, name) for a
      setter.
      
      The majority of the grunt-work for this change was done by writing a semantic
      patch using Coccinelle ( http://coccinelle.lip6.fr/ ).
      
      Review: https://reviewboard.asterisk.org/r/1655/
      
      
      git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@350223 65c4cc65-6c06-0410-ace0-fbb531ad65f3
      04da92c3
  34. Jun 03, 2011
  35. May 19, 2011
    • Richard Mudgett's avatar
      Merged revisions 319758 via svnmerge from · b33fc4db
      Richard Mudgett authored
      https://origsvn.digium.com/svn/asterisk/branches/1.8
      
      ........
        r319758 | rmudgett | 2011-05-19 11:50:48 -0500 (Thu, 19 May 2011) | 21 lines
        
        CCSS generic agent with POTS and ISDN phones fail caller busy call-back test.
        
        If the following is true after a CCSS activation:
        * The generic agent is for an analog phone or ISDN phone.  (Caller party)
        * The called party becomes available.
        * The caller party is not available.
        
        When the caller party becomes available, the caller is not alerted to the
        called party being available.  The generic agent still thinks the caller
        is busy.
        
        * Fixed the generic agent device state event subscription to look for all
        device states that are considered available.
        
        * Encapsulated the device state test for CCSS generic device available in
        cc_generic_is_device_available().  Made the generic agent and monitor use
        the new function instead of the manually coded inline equivalent.
        
        JIRA AST-559
        JIRA SWP-3462
      ........
      
      
      git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@319759 65c4cc65-6c06-0410-ace0-fbb531ad65f3
      b33fc4db
  36. May 16, 2011
    • Richard Mudgett's avatar
      Merged revisions 319259 via svnmerge from · eddc32a3
      Richard Mudgett authored
      https://origsvn.digium.com/svn/asterisk/branches/1.8
      
      ........
        r319259 | rmudgett | 2011-05-16 15:33:37 -0500 (Mon, 16 May 2011) | 13 lines
        
        Deadlock between generic CCSS agent and native ISDN CCSS.
        
        Deadlock can occur when the generic CCSS agent is deleting duplicate CC
        offers and the native ISDN CC driver is processing an incoming CC message.
        The cc_core_instances container lock cannot be held when an agent or
        monitor callback is invoked without the possibility of a deadlock.
        
        * Make kill_duplicate_offers() remove the reference in cc_core_instances
        outside of the container lock.
        
        JIRA AST-566
        JIRA SWP-3469
      ........
      
      
      git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@319260 65c4cc65-6c06-0410-ace0-fbb531ad65f3
      eddc32a3
  37. Apr 14, 2011
    • Richard Mudgett's avatar
      Add Device State Information CCSS for Generic Devices. · ae2926b5
      Richard Mudgett authored
      Add Asterisk Device State information and callbacks to the Call Completion
      Supplemental Services for generic agents.
      
      There are currently not many devices that have native support for CCSS.
      Even as the devices become available there may be other reasons why one
      may choose to not take advantage of the native abilities and stick with
      the generic implementation.  The generic implementation is quite capable
      and could be greatly enhanced by adding device state capabilities.  A
      phone could then subscribe to the device state with a BLF key in
      conjunction with Asterisk hints.
      
      The advantages of the device state information would allow a single button
      to: request CCSS, cancel a CCSS request, and display the current state of
      a CCSS request.
      
      For example, you may have a single button that when not lit, there is no
      active CCSS request.  When you press that button, the dialplan can query
      the DEVICE_STATE() associated with that caller to determine whether they
      should be calling CallCompletionRequest() or CallCompletionCancel().  If
      there is currently a pending request, then the dialplan would cancel it.
      This also has the advantage of showing the true state of a request, which
      is an asynchronous call, even when CallCompletionRequest() thinks it was
      successful.  The actual request could ultimately fail.  Once lit, further
      feedback can be provided to the caller about the current state of their
      request since it will be updated by the CCSS State Machine as appropriate.
      
      The DEVICE_STATE mapping is configurable since the BLF being used on a
      given phone type may vary.  The idea is to allow some level of
      customization as to the phone's behavior.
      
      As an example, you may want the BLF key to go solid once you have
      requested a callback.  You may then want the LED to blink (typically
      ringing) when either the callback is in process, which is a visual
      indication that the incoming call is the desired callback.  You may want
      it to blink when the callee is ready but you are busy, giving you a visual
      indication that the target is available as you may want to get off the
      line so that the callback can be successful.
      
      Device state information is sent back via the ast_devstate_prov_add()
      callback for any generic CCSS device as it traverses through the state
      machine.  You simply provide a map between CC_STATE values and the
      corresponding AST_DEVICE state values.
      
      You could then generate hints against these states similar to what is
      possible today with Custom Devstates or MeetMe states.  For example, you
      may have an extension 3000 that is currently associated with device
      SIP/3000.  You could then create a feature code for that extension that
      may look something like:
      
      exten => *823000,hint,ccss:sip/3000
      
      You would then subscribe a BLF button to *823000 which would point to the
      dialplan that handled CCSS requests/cancels using the available
      DEVICE_STATE() information about ccss:sip/3000 to make the decision about
      what to do.
      
      (closes issue #18788)
      Reported by: p_lindheimer
      Patches:
            ccss.trunk.18788.patch uploaded by p lindheimer (license 558)
            Modified with final reviewboard comments.
      Tested by: p_lindheimer, loloski
      
      Review: https://reviewboard.asterisk.org/r/1105/
      
      
      git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@313744 65c4cc65-6c06-0410-ace0-fbb531ad65f3
      ae2926b5
  38. Apr 01, 2011
    • Richard Mudgett's avatar
      Merged revisions 312461 via svnmerge from · 75594e6e
      Richard Mudgett authored
      https://origsvn.digium.com/svn/asterisk/branches/1.8
      
      ........
        r312461 | rmudgett | 2011-04-01 16:31:39 -0500 (Fri, 01 Apr 2011) | 25 lines
        
        CallCompletionRequest()/CallCompletionCancel() exit non-zero if fail.
        
        The CallCompletionRequest()/CallCompletionCancel() dialplan applications
        exit nonzero on normal failure conditions.  The nonzero exit causes the
        dialplan to hangup immediately.  The dialplan author has no opportunity to
        report success/failure to the user.
        
        * Made always return zero so the dialplan can continue.
        
        * Made set CC_REQUEST_RESULT/CC_REQUEST_REASON and
        CC_CANCEL_RESULT/CC_CANCEL_REASON channel variables respectively.  Also
        documented the values set.
        
        * Reduced the warning about no core instance in CallCompletionCancel() to
        a debug message.  It is a normal event and should not be output at the
        WARNING level.
        
        (closes issue #18763)
        Reported by: p_lindheimer
        Patches:
              ccss.patch uploaded by p lindheimer (license 558) Modified
        Tested by: p_lindheimer, rmudgett
        
        JIRA SWP-3042
      ........
      
      
      git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@312462 65c4cc65-6c06-0410-ace0-fbb531ad65f3
      75594e6e
Loading