summaryrefslogtreecommitdiff
path: root/channels/chan_misdn.c
AgeCommit message (Collapse)Author
2013-06-17chan_misdn: Fix compile error after CDR merge.Richard Mudgett
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@392053 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-06-07Refactor chan_dahdi/sig_analog/sig_pri and chan_misdn to use the common ↵Richard Mudgett
transfer functions. (closes issue ASTERISK-21523) Reported by: Matt Jordan (closes issue ASTERISK-21524) Reported by: Matt Jordan Review: https://reviewboard.asterisk.org/r/2600/ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@390804 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-06-06Refactor the features configuration scheme.Mark Michelson
Features configuration is handled in its own API in features_config.h and features_config.c. This way, features configuration is accessible to anything that needs it. In addition, features configuration has been altered to be more channel-oriented. Most callers of features API code will be supplying a channel so that the individual channel's settings will be acquired rather than the global setting. Missing from this commit is XML documentation for the features configuration. That will be handled in a separate commit. Review: https://reviewboard.asterisk.org/r/2578/ (issue ASTERISK-21542) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@390751 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-24Split Hold event into Hold/Unhold, and move it into core.Jason Parker
(closes issue ASTERISK-21487) Review: https://reviewboard.asterisk.org/r/2565/ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@389746 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-21Merge in the bridge_construction branch to make the system use the Bridging API.Richard Mudgett
Breaks many things until they can be reworked. A partial list: chan_agent chan_dahdi, chan_misdn, chan_iax2 native bridging app_queue COLP updates DTMF attended transfers Protocol attended transfers git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@389378 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-01-16chan_misdn: Fix compile error.Richard Mudgett
(issue ASTERISK-15456) ........ Merged revisions 379226 from http://svn.asterisk.org/svn/asterisk/branches/1.8 ........ Merged revisions 379230 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@379231 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-01-16Set the INVALID_EXTEN channel variable when chan_misdn forces the 'i' extensionMatthew Jordan
The chan_misdn channel driver will send a channel with an invalid destination to the 'i' extension itself if said extension can be reached. It forgot, however, to set the INVALID_EXTEN channel variable when it bounces the channel to this extension. Dialplan writers everywhere moaned at yet another inconsistency. This is yet another example of why duplicating logic in multiple places results in bugs that stick around in Jira for just under three years. Yes: ASTERISK-15456 was created on January 18th, 2010. Patch committed on January 15th, 2013. Ouch. (closes issue ASTERISK-15456) Reported by: Thomas Omerzu patches: chan_misdn_invalid.patch2 uploaded by Thomas Omerzu (license 5927) ........ Merged revisions 379145 from http://svn.asterisk.org/svn/asterisk/branches/1.8 ........ Merged revisions 379146 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@379147 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-11-02Things don't need to be that const.Richard Mudgett
........ Merged revisions 375658 from http://svn.asterisk.org/svn/asterisk/branches/1.8 ........ Merged revisions 375659 from http://svn.asterisk.org/svn/asterisk/branches/10 ........ Merged revisions 375661 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@375662 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-14Doxygen Updates - Title updateAndrew Latham
Update and extend the configuration_file group and enable linking. Update title that was left behind many years ago. (issue ASTERISK-20259) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@375006 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-05Merged revisions 374515-374535 fromRichard Mudgett
https://origsvn.digium.com/svn/asterisk/be/branches/C.3-bier ................ r374515 | rmudgett | 2012-10-04 17:52:36 -0500 (Thu, 04 Oct 2012) | 10 lines chan_misdn: Remove some deadcode * Made setup_bc() static. Patches: patch1_unused-code.diff (license #6372) patch uploaded by Guenther Kelleter Modified JIRA ABE-2882 ................ r374516 | rmudgett | 2012-10-04 18:01:01 -0500 (Thu, 04 Oct 2012) | 7 lines chan_misdn: Remove unused bchan states Patches: patch2_unused-states.diff (license #6372) patch uploaded by Guenther Kelleter JIRA ABE-2882 ................ r374517 | rmudgett | 2012-10-04 18:17:51 -0500 (Thu, 04 Oct 2012) | 16 lines chan_misdn: Remove unnecessary null pointer checks and checks for stack->nt * cleanup_bc() is always called with valid bc (or it would've crashed before). * Value of stack->nt is known in advance at some places. * Rename handle_event() to handle_event_te(), handle_frm() to handle_frm_te(). Patches: patch3_checks.diff (license #6372) patch uploaded by Guenther Kelleter Modified JIRA ABE-2882 ................ r374518 | rmudgett | 2012-10-04 18:21:59 -0500 (Thu, 04 Oct 2012) | 7 lines chan_misdn: Fix spelling in log messages Patches: patch4_spelling.diff (license #6372) patch uploaded by Guenther Kelleter JIRA ABE-2882 ................ r374519 | rmudgett | 2012-10-04 18:31:59 -0500 (Thu, 04 Oct 2012) | 15 lines chan_misdn: Don't cleanup a bc twice. In handle_frm_te() after calling misdn_lib_send_event(bc, EVENT_RELEASE_COMPLETE) bc is emptied, cleaned and set not in use, although misdn_lib_send_event() already did the same. This is bad. When it's not in use we are not allowed to touch it. * Moved log message in front of the resulting actions and fixed it to match the case. Patches: patch5_bccleanup.diff (license #6372) patch uploaded by Guenther Kelleter JIRA ABE-2882 ................ r374520 | rmudgett | 2012-10-04 18:43:56 -0500 (Thu, 04 Oct 2012) | 12 lines chan_misdn: Fix memory leaks, bc, chan not cleaned up etc., really bad stuff. * Fix return codes of cb_events() for EVENT_SETUP to use caller's cleanup mechanisms. * Move cl_queue_chan() call after bearer check. Patches: patch6_leaks.diff (license #6372) patch uploaded by Guenther Kelleter JIRA ABE-2882 ................ r374521 | rmudgett | 2012-10-04 18:48:38 -0500 (Thu, 04 Oct 2012) | 11 lines chan_misdn: We must initialize cause on sending a DISCONNECT. We must initialize cause on sending a DISCONNECT, so it is later correctly indicated to ast_channel in case the answer (RELEASE/RELEASE_COMPLETE) does not include one. Patches: patch7_hangupcause.diff (license #6372) patch uploaded by Guenther Kelleter JIRA ABE-2882 ................ r374522 | rmudgett | 2012-10-04 19:03:56 -0500 (Thu, 04 Oct 2012) | 7 lines chan_misdn: Remove unused code for upqueue Patches: patch8_unused-upqueue.diff (license #6372) patch uploaded by Guenther Kelleter JIRA ABE-2882 ................ r374523 | rmudgett | 2012-10-04 19:11:50 -0500 (Thu, 04 Oct 2012) | 7 lines chan_misdn: Improve debugging (port number, messages fixed, dups removed) Patches: patch9_debug.diff (license #6372) patch uploaded by Guenther Kelleter JIRA ABE-2882 ................ r374533 | rmudgett | 2012-10-05 12:17:18 -0500 (Fri, 05 Oct 2012) | 8 lines chan_misdn: Better debug: we can print_bc_info even if there's no ast leg. Patches: patch10_debug-bc-2.diff (license #6372) patch uploaded by Guenther Kelleter Modified. JIRA ABE-2882 ................ r374534 | rmudgett | 2012-10-05 12:34:10 -0500 (Fri, 05 Oct 2012) | 16 lines chan_misdn: setup_bc() is called too early for an incoming SETUP on TE. This prevents the B channel from being setup for HDLC mode when requested by the bearer capability and config option hdlc=yes. It violates ETS300102 Ch.5.2.3.2: "The user, in any case, must not connect to the channel until a CONNECT ACKNOWLEDGE message has been received." * Call setup_bc() on receipt of CONNECT_ACKNOWLEGDE for PTMP, and on first response to SETUP for PTP. Patches: abe-2881-2.diff (license #6372) patch uploaded by Guenther Kelleter Modified. JIRA ABE-2881 ................ r374535 | rmudgett | 2012-10-05 12:41:05 -0500 (Fri, 05 Oct 2012) | 2 lines chan_misdn: Remove some more deadcode. ................ ........ Merged revisions 374536 from http://svn.asterisk.org/svn/asterisk/branches/1.8 ........ Merged revisions 374537 from http://svn.asterisk.org/svn/asterisk/branches/10 ........ Merged revisions 374538 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@374539 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-01Doxygen CleanupAndrew Latham
Start adding configuration file linking and pages. Add module loading doxygen block. Breaking up commits to keep it easy to track (issue ASTERISK-20259) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@374166 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-25Allow for redirecting reasons to be set to arbitrary strings.Mark Michelson
This allows for the REDIRECTING dialplan function to be used to set the reason to any string. The SIP channel driver has been modified to set the redirecting reason string to the value received in a Diversion header. In addition, SIP 480 response reason text will set the redirecting reason as well. (closes issue AST-942) reported by Malcolm Davenport (closes issue AST-943) reported by Malcolm Davenport Review: https://reviewboard.asterisk.org/r/2101 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@373701 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-21Doxygen Updates - janitor workAndrew Latham
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
2012-08-10Add private representation of caller, connected and redirecting party ids.Richard Mudgett
This patch adds the feature "Private representation of caller, connected and redirecting party ids", as previously discussed with us (DATUS) and Digium. 1. Feature motivation Until now it is quite difficult to modify a party number or name which can only be seen by exactly one particular instantiated technology channel subscriber. One example where a modified party number or name on one channel is spread over several channels are supplementary services like call transfer or pickup. To implement these features Asterisk internally copies caller and connected ids from one channel to another. Another example are extension subscriptions. The monitoring entities (watchers) are notified of state changes and - if desired - of party numbers or names which represent the involving call parties. One major feature where a private representation of party names is essentially needed, i.e. where a party name shall be exclusively signaled to only one particular user, is a private user-specific name resolution for party numbers. A lookup in a private destination-dependent telephone book shall provide party names which cannot be seen by any other user at any time. 2. Feature Description This feature comes along with the implementation of additional private party id elements for caller id, connected id and redirecting ids inside Asterisk channels. The private party id elements can be read or set by the user using Asterisk dialplan functions. When a technology channel is initiating a call, receives an internal connected-line update event, or receives an internal redirecting update event, it merges the corresponding public id with the private id to create an effective party id. The effective party id is then used for protocol signaling. The channel technologies which initially support the private id representation with this patch are SIP (chan_sip), mISDN (chan_misdn) and PRI (chan_dahdi). Once a private name or number on a channel is set and (implicitly) made valid, it is generally used for any further protocol signaling until it is rewritten or invalidated. To simplify the invalidation of private ids all internally generated connected/redirecting update events and also all connected/redirecting update events which are generated by technology channels -- receiving regarding protocol information - automatically trigger the invalidation of private ids. If not using the private party id representation feature at all, i.e. if using only the 'regular' caller-id, connected and redirecting related functions, the current characteristic of Asterisk is not affected by the new extended functionality. 3. User interface Description To grant access to the private name and number representation from the Asterisk dialplan, the CALLERID, CONNECTEDLINE and REDIRECTING dialplan functions are extended by the following data types. The formats of these data types are equal to the corresponding regular 'non-private' already existing data types: CALLERID: priv-all priv-name priv-name-valid priv-name-charset priv-name-pres priv-num priv-num-valid priv-num-plan priv-num-pres priv-subaddr priv-subaddr-valid priv-subaddr-type priv-subaddr-odd priv-tag CONNECTEDLINE: priv-name priv-name-valid priv-name-pres priv-name-charset priv-num priv-num-valid priv-num-pres priv-num-plan priv-subaddr priv-subaddr-valid priv-subaddr-type priv-subaddr-odd priv-tag REDIRECTING: priv-orig-name priv-orig-name-valid priv-orig-name-pres priv-orig-name-charset priv-orig-num priv-orig-num-valid priv-orig-num-pres priv-orig-num-plan priv-orig-subaddr priv-orig-subaddr-valid priv-orig-subaddr-type priv-orig-subaddr-odd priv-orig-tag priv-from-name priv-from-name-valid priv-from-name-pres priv-from-name-charset priv-from-num priv-from-num-valid priv-from-num-pres priv-from-num-plan priv-from-subaddr priv-from-subaddr-valid priv-from-subaddr-type priv-from-subaddr-odd priv-from-tag priv-to-name priv-to-name-valid priv-to-name-pres priv-to-name-charset priv-to-num priv-to-num-valid priv-to-num-pres priv-to-num-plan priv-to-subaddr priv-to-subaddr-valid priv-to-subaddr-type priv-to-subaddr-odd priv-to-tag Reported by: Thomas Arimont Review: https://reviewboard.asterisk.org/r/2030/ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@371120 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-08-07Add named callgroups/pickupgroupsMatthew Jordan
This patch adds named calledgroups/pickupgroups to Asterisk. Named groups are implemented in parallel to the existing numbered callgroup/pickupgroup implementation. However, unlike the existing implementation, which is limited to a maximum of 64 defined groups, the number of defined groups allowed for named callgroups/pickupgroups is effectively unlimited. Named groups are configured with the keywords "namedcallgroup" and "namedpickupgroup". This corresponds to the numbered group definitions of "callgroup" and "pickupgroup". Note that as the implementation of named groups coexists with the existing numbered implementation, a defined named group of "4" does not equate to numbered group 4. Support for the named groups has been added to the SIP, DAHDI, and mISDN channel drivers. Review: https://reviewboard.asterisk.org/r/2043 Uploaded by: Guenther Kelleter(license #6372) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@370831 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-07-30Release B channel allocation on error path in chan_misdn.Richard Mudgett
........ Merged revisions 370563 from http://svn.asterisk.org/svn/asterisk/branches/1.8 ........ Merged revisions 370564 from http://svn.asterisk.org/svn/asterisk/branches/10 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@370565 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-07-20Fix build error in chan_misdn from commit 370316Kinsey Moore
chan_misdn was not updated properly to account for a change in parameters for HANGUPCAUSE functionality. It now builds properly. git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@370328 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-06-20Fix chan_misdn compile error.Richard Mudgett
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@369166 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-06-19Ensure that pvt cause information does not break native bridgingKinsey Moore
Channel drivers that allow native bridging need to handle AST_CONTROL_PVT_CAUSE_CODE frames and previously did not handle them properly, usually breaking out of the native bridge. This change corrects that behavior and exposes the available cause code information to the dialplan while native bridges are in place. This required exposing the HANGUPCAUSE hash setter outside of channel.c, so additional documentation has been added. git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@369086 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-06-15Multiple revisions 369001-369002Kevin P. Fleming
........ 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
2012-05-14Commit framework for HANGUPCAUSE (replacement for SIP_CAUSE)Kinsey Moore
This is the starting point for the Asterisk 11: Who Hung Up work and provides a framework which will allow channel drivers to report the types of hangup cause information available in SIP_CAUSE without incurring the overhead of the MASTER_CHANNEL dialplan function. The initial implementation only includes cause generation for chan_sip and does not include cause code translation utilities. This change deprecates SIP_CAUSE and replaces its method of reporting cause codes with the new framework. This change also deprecates the 'storesipcause' option in sip.conf. Review: https://reviewboard.asterisk.org/r/1822/ (Closes issue SWP-4221) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@366408 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-04-20Use ast_channel_lock_both() where it was inlined before.Richard Mudgett
The CHANNEL_DEADLOCK_AVOIDANCE() feature of preserving where the channel lock was originally obtained is overkill where ast_channel_lock_both() was inlined. git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@362888 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-03-01Opaquify ast_channel typedefs, fd arrays, and softhangup flagTerry Wilson
Review: https://reviewboard.asterisk.org/r/1784/ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@357721 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-02-29Opaquify ast_channel structs and listsTerry Wilson
Review: https://reviewboard.asterisk.org/r/1773/ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@357542 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-02-24Opaquification for ast_format structs in struct ast_channelTerry Wilson
Review: https://reviewboard.asterisk.org/r/1770/ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@356573 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-02-22Fix chan_misdn after the lastest opaquification changesTerry Wilson
It now compiles, but there are some unrelated warnings for set but unused variables. git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@356259 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-02-20ast_channel opaquification of pointers and integral typesTerry Wilson
Review: https://reviewboard.asterisk.org/r/1753/ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@356042 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-02-13Fix compile error from most recent ast_channel opaquification installment.Richard Mudgett
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@355055 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-02-13Opaquify char * and char[] in ast_channelTerry Wilson
Review: https://reviewboard.asterisk.org/r/1733/ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@354968 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-02-09Fix some compile problems from the 'cppcheck' patch.Richard Mudgett
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@354498 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-02-08Avoid cppcheck warnings; removing unused vars and a bit of cleanup.Walter Doekes
Patch by: Clod Patry Review: https://reviewboard.asterisk.org/r/1651 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@354429 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-02-01Constify some more channel driver technology callback parameters.Richard Mudgett
Review: https://reviewboard.asterisk.org/r/1707/ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@353685 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-24Opaquify channel stringfieldsTerry Wilson
Continue channel opaque-ification by wrapping all of the stringfields. Eventually, we will restrict what can actually set these variables, but the purpose for now is to hide the implementation and keep people from adding code that directly accesses the channel structure. Semantic changes will follow afterward. Review: https://reviewboard.asterisk.org/r/1661/ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@352348 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-09Replace direct access to channel name with accessor functionsTerry Wilson
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
2011-11-12mISDN Round Robin break when no channel is availableGregory Nietsky
Prevent channels been parsed repetitively. ........ Merged revisions 344965 from http://svn.asterisk.org/svn/asterisk/branches/1.8 ........ Merged revisions 344966 from http://svn.asterisk.org/svn/asterisk/branches/10 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@344979 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-09-16Merged revisions 336167 via svnmerge from Gregory Nietsky
https://origsvn.digium.com/svn/asterisk/branches/10 ................ r336167 | irroot | 2011-09-16 12:12:03 +0200 (Fri, 16 Sep 2011) | 22 lines Merged revisions 336166 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.8 ........ r336166 | irroot | 2011-09-16 12:09:17 +0200 (Fri, 16 Sep 2011) | 16 lines The round robin routing routine in chan_misdn.c is broken. it rotates between ports but never checks the channels in the ports. i have extensivly tested it and verified it works on 1 upto 4 ports. before the patch only 1 out of each port was used now all are used as expected. (closes issue ASTERISK-18413) Reported by: irroot Tested by: irroot Reviewed by: irroot Review: https://reviewboard.asterisk.org/r/1410/ ........ ................ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@336168 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-09-09Merged revisions 335078 via svnmerge from Matthew Jordan
https://origsvn.digium.com/svn/asterisk/branches/10 ................ r335078 | mjordan | 2011-09-09 11:27:01 -0500 (Fri, 09 Sep 2011) | 29 lines Merged revisions 335064 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.8 ........ r335064 | mjordan | 2011-09-09 11:09:09 -0500 (Fri, 09 Sep 2011) | 23 lines Updated SIP 484 handling; added Incomplete control frame When a SIP phone uses the dial application and receives a 484 Address Incomplete response, if overlapped dialing is enabled for SIP, then the 484 Address Incomplete is forwarded back to the SIP phone and the HANGUPCAUSE channel variable is set to 28. Previously, the Incomplete application dialplan logic was automatically triggered; now, explicit dialplan usage of the application is required. Additionally, this patch adds a new AST_CONTOL_FRAME type called AST_CONTROL_INCOMPLETE. If a channel driver receives this control frame, it is an indication that the dialplan expects more digits back from the device. If the device supports overlap dialing it should attempt to notify the device that the dialplan is waiting for more digits; otherwise, it can handle the frame in a manner appropriate to the channel driver. (closes issue ASTERISK-17288) Reported by: Mikael Carlsson Tested by: Matthew Jordan Review: https://reviewboard.asterisk.org/r/1416/ ........ ................ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@335079 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-07-14Merged revisions 328247 via svnmerge from Leif Madsen
https://origsvn.digium.com/svn/asterisk/branches/1.10 ................ r328247 | lmadsen | 2011-07-14 16:25:31 -0400 (Thu, 14 Jul 2011) | 14 lines Merged revisions 328209 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.8 ........ r328209 | lmadsen | 2011-07-14 16:13:06 -0400 (Thu, 14 Jul 2011) | 6 lines Introduce <support_level> tags in MODULEINFO. This change introduces MODULEINFO into many modules in Asterisk in order to show the community support level for those modules. This is used by changes committed to menuselect by Russell Bryant recently (r917 in menuselect). More information about the support level types and what they mean is available on the wiki at https://wiki.asterisk.org/wiki/display/AST/Asterisk+Module+Support+States ........ ................ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@328259 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-04-01Merged revisions 312509 via svnmerge from Richard Mudgett
https://origsvn.digium.com/svn/asterisk/branches/1.8 ........ r312509 | rmudgett | 2011-04-01 18:15:42 -0500 (Fri, 01 Apr 2011) | 22 lines When a call going out an NT-PTMP port gets rejected, Asterisk crashes. If a call is sent to an ISDN phone that rejects the call with RELEASE_COMPLETE(cause: call reject(21), or busy(17)) Asterisk crashes. I could not get my setup to crash. However, I could see the possibility from a race condition between queuing an AST_CONTROL_BUSY to the core and then queueing an AST_CONTROL_HANGUP. If the AST_CONTROL_BUSY is processed before the AST_CONTROL_HANGUP is queued, the ast_channel could be destroyed out from under chan_misdn. Avoid this particular crash scenario by not queueing the AST_CONTROL_HANGUP if the AST_CONTROL_BUSY was queued. (closes issue #18408) Reported by: wimpy Patches: issue18408_v1.8.patch uploaded by rmudgett (license 664) Tested by: rmudgett, wimpy JIRA SWP-2679 ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@312510 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-03-31Merged revisions 312022 via svnmerge from Richard Mudgett
https://origsvn.digium.com/svn/asterisk/branches/1.8 ........ r312022 | rmudgett | 2011-03-31 15:11:40 -0500 (Thu, 31 Mar 2011) | 14 lines chan_misdn segfaults when DEBUG_THREADS is enabled. The segfault happens because jb->mutexjb is uninitialized from the ast_malloc(). The internals of ast_mutex_init() were assuming a nonzero value meant mutex tracking initialization had already happened. Recent changes to mutex tracking code to reduce excessive memory consumption exposed this uninitialized value. Converted misdn_jb_init() to use ast_calloc() instead of ast_malloc(). Also eliminated redundant zero initialization code in the routine. (closes issue #18975) Reported by: irroot ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@312023 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-02-04Replace ast_log(LOG_DEBUG, ...) with ast_debug()Paul Belanger
(closes issue #18556) Reported by: kkm Review: https://reviewboard.asterisk.org/r/1071/ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@306258 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-02-03Asterisk media architecture conversion - no more format bitfieldsDavid Vossel
This patch is the foundation of an entire new way of looking at media in Asterisk. The code present in this patch is everything required to complete phase1 of my Media Architecture proposal. For more information about this project visit the link below. https://wiki.asterisk.org/wiki/display/AST/Media+Architecture+Proposal The primary function of this patch is to convert all the usages of format bitfields in Asterisk to use the new format and format_cap APIs. Functionally no change in behavior should be present in this patch. Thanks to twilson and russell for all the time they spent reviewing these changes. Review: https://reviewboard.asterisk.org/r/1083/ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@306010 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-12-20Fix chan_misdn build after sched API changes.Russell Bryant
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@299134 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-11-29Merged revisions 296582 via svnmerge from Richard Mudgett
https://origsvn.digium.com/svn/asterisk/branches/1.8 ................ r296582 | rmudgett | 2010-11-29 14:46:03 -0600 (Mon, 29 Nov 2010) | 24 lines Merged revision 296575 from https://origsvn.digium.com/svn/asterisk/be/branches/C.3-bier .......... r296575 | rmudgett | 2010-11-29 14:27:37 -0600 (Mon, 29 Nov 2010) | 13 lines Invalid mISDN PTMP redirecting signaling as TE towards NT. The mISDN PTMP redirection signaling (NOTIFY redirecting number and notification code, SETUP redirecting number) is also sent in PTMP/TE mode. It should only apply in PTMP/NT mode. The call setup proceeds but the network (Deutsche Telekom) reacts with ugly ISDN STATUS messages. Also don't send the redirecting number ie when PTP is also sending the DivertingLegInformation2 facility. The redirecting number ie is redundant and the network (Deutsche Telekom) complains about it. Patches: abe_2651_v4.patch uploaded by rmudgett (license 664) JIRA ABE-2651 JIRA SWP-2537 .......... ................ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@296585 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-11-09Merged revisions 294349 via svnmerge from Richard Mudgett
https://origsvn.digium.com/svn/asterisk/branches/1.8 ........ r294349 | rmudgett | 2010-11-09 10:55:32 -0600 (Tue, 09 Nov 2010) | 17 lines Analog lines do not transfer CONNECTED LINE or execute the interception macros. Add connected line update for sig_analog transfers and simplify the corresponding sig_pri and chan_misdn transfer code. Note that if you create a three-way call in sig_analog before transferring the call, the distinction of the caller/callee interception macros make little sense. The interception macro writer needs to be prepared for either caller/callee macro to be executed. The current implementation swaps which caller/callee interception macro is executed after a three-way call is created. Review: https://reviewboard.asterisk.org/r/996/ JIRA ABE-2589 JIRA SWP-2372 ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@294351 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-11-08Merged revisions 294125 via svnmerge from Richard Mudgett
https://origsvn.digium.com/svn/asterisk/branches/1.8 ........ r294125 | rmudgett | 2010-11-08 11:16:01 -0600 (Mon, 08 Nov 2010) | 33 lines valgrind reported references to freed memory during a mISDN hangup collision. Bad things have been happening in chan_misdn because the chan_misdn channel private struct chan_list is not protected from reentrancy. Hangup collisions have be causing read and write accesses to freed memory. Converted chan_misdn struct chan_list to an ao2 object for its reference counting feature. ********** Removed an impediment to converting chan_list to an ao2 object. The use of the other_ch member in chan_list is shaky at best. It is set if the incoming and outgoing call legs are mISDN. The use of the other_ch member goes against the Asterisk architecture and can even cause problems. 1) It is used to disable echo cancellation. This could be bad if the call is forked and the winning call leg is not mISDN or the winning call leg is not the last mISDN channel called by the fork. The other_ch would become a dangling pointer. 2) It is used when the far end is alerting to hear the far end's inband audio instead of Asterisk's generated ringback tone. This is bad if the call is forked. You would only hear the last forked mISDN channel and it may not be ringing yet. The other_ch would become a dangling pointer if the call is later transferred. ********** JIRA SWP-2423 JIRA ABE-2614 ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@294127 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-10-22Merged revisions 292704 via svnmerge from Richard Mudgett
https://origsvn.digium.com/svn/asterisk/branches/1.8 ........ r292704 | rmudgett | 2010-10-22 10:47:08 -0500 (Fri, 22 Oct 2010) | 19 lines Connected line is not updated when chan_dahdi/sig_pri or chan_misdn transfers a call. When a call is transfered by ECT or implicitly by disconnect in sig_pri or implicitly by disconnect in chan_misdn, the connected line information is not exchanged. The connected line interception macros also need to be executed if defined. The CALLER interception macro is executed for the held call. The CALLEE interception macro is executed for the active/ringing call. JIRA ABE-2589 JIRA SWP-2296 Patches: abe_2589_c3bier.patch uploaded by rmudgett (license 664) abe_2589_v1.8_v2.patch uploaded by rmudgett (license 664) Review: https://reviewboard.asterisk.org/r/958/ ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@292705 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-10-13Merged revisions 291507 via svnmerge from Richard Mudgett
https://origsvn.digium.com/svn/asterisk/branches/1.8 ................ r291507 | rmudgett | 2010-10-13 14:01:48 -0500 (Wed, 13 Oct 2010) | 18 lines Merged revision 291504 from https://origsvn.digium.com/svn/asterisk/be/branches/C.3-bier .......... r291504 | rmudgett | 2010-10-13 13:30:21 -0500 (Wed, 13 Oct 2010) | 11 lines Hold off ast_hangup() from destroying the ast_channel. Must get the ast_channel lock before proceeding with release_chan() and release_chan_early() to hold off ast_hangup() from destroying the ast_channel. Missed this change for -r291468. JIRA ABE-2598 JIRA SWP-2317 .......... ................ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@291508 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-10-13Merged revisions 291469 via svnmerge from Richard Mudgett
https://origsvn.digium.com/svn/asterisk/branches/1.8 ................ r291469 | rmudgett | 2010-10-13 13:10:21 -0500 (Wed, 13 Oct 2010) | 23 lines Merge revision 291468 from https://origsvn.digium.com/svn/asterisk/be/branches/C.3-bier .......... r291468 | rmudgett | 2010-10-13 12:39:02 -0500 (Wed, 13 Oct 2010) | 16 lines Memory overwrites when releasing mISDN call. Phone <--> Asterisk <-- ALERTING --> DISCONNECT <-- RELEASE --> RELEASE_COMPLETE * Add lock protection around channel list for find/add/delete operations. * Protect misdn_hangup() from release_chan() and vise versa using the release_lock. JIRA ABE-2598 JIRA SWP-2317 .......... ................ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@291470 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-09-30Merged revisions 289549 via svnmerge from Richard Mudgett
https://origsvn.digium.com/svn/asterisk/branches/1.8 ................ r289549 | rmudgett | 2010-09-30 14:28:36 -0500 (Thu, 30 Sep 2010) | 17 lines Merged revision 289547 from https://origsvn.digium.com/svn/asterisk/be/branches/C.3-bier .......... r289547 | rmudgett | 2010-09-30 14:16:36 -0500 (Thu, 30 Sep 2010) | 10 lines In chan_misdn, the DivertingLegInformation2 DivertingNr is garbage when the number is restricted. The same thing happens with DivertingLegInformation1 DivertedTo number. The misdn_PresentedNumberUnscreened_extract() extracted the Unscreened PartyNumber field unconditionally. It now checks the presented number unscreened type to see if the PartyNumber was even present. JIRA ABE-2595 .......... ................ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@289552 65c4cc65-6c06-0410-ace0-fbb531ad65f3