aboutsummaryrefslogtreecommitdiffstats
path: root/include
AgeCommit message (Collapse)AuthorFilesLines
2010-12-17Merged revisions 298905 via svnmerge from tilghman3-0/+25
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r298905 | tilghman | 2010-12-17 15:40:56 -0600 (Fri, 17 Dec 2010) | 6 lines Let Asterisk find better backtrace information with libbfd. The menuselect option BETTER_BACKTRACES, if enabled, will use libbfd to search for better symbol information within both the Asterisk binary, as well as loaded modules, to assist when using inline backtraces to track down problems. ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@298957 f38db490-d61c-443f-a65b-d21fe96a405b
2010-12-10Portability issue on OpenSolaris.tilghman1-0/+3
Also detect the required structure element, because OpenSolaris defines SIOCGIFHWADDR, but without support for IP sockets. (closes issue #18442) Reported by: ranjtech Patches: 20101209__issue18442.diff.txt uploaded by tilghman (license 14) Tested by: ranjtech git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@298050 f38db490-d61c-443f-a65b-d21fe96a405b
2010-12-01Merged revisions 296990 via svnmerge from tilghman1-1/+9
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r296990 | tilghman | 2010-12-01 10:59:26 -0600 (Wed, 01 Dec 2010) | 5 lines Clarify documentation on how we store codec preference lists. (closes issue #18397) Reported by: birgita ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@296991 f38db490-d61c-443f-a65b-d21fe96a405b
2010-11-29I love standards. There are so many to choose from. Except when there ↵tilghman1-0/+6
isn't one. Linux and *BSD disagree on the elements within the ucred structure. Detect which one is in use on the system. (closes issue #18384) Reported by: bjm Patches: cred-diffs uploaded by bjm (license 473) 20101127__issue18384__1.6.2.diff.txt uploaded by tilghman (license 14) 20101127__issue18384__1.8.diff.txt uploaded by tilghman (license 14) Tested by: tilghman, bjm git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@296533 f38db490-d61c-443f-a65b-d21fe96a405b
2010-11-22Merged revisions 295790 via svnmerge from rmudgett2-2/+31
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r295790 | rmudgett | 2010-11-22 12:46:26 -0600 (Mon, 22 Nov 2010) | 46 lines The channel redirect function (CLI or AMI) hangs up the call instead of redirecting the call. To recreate the problem: 1) Party A calls Party B 2) Invoke CLI "channel redirect" command to redirect channel call leg associated with A. 3) All associated channels are hung up. Note that if the CLI command were done on the channel call leg associated with B it works. This regression was a result of the fix for issue #16946 (https://reviewboard.asterisk.org/r/740/). The regression affects all features that use an async goto to execute the dialplan because of an external event: Channel redirect, AMI redirect, SIP REFER, and FAX detection. The struct ast_channel._softhangup code is a mess. The variable is used for several purposes that do not necessarily result in the call being hung up. I have added doxygen comments to describe how the various _softhangup bits are used. I have corrected all the places where the variable was tested in a non-bit oriented manner. The primary fix is the new AST_CONTROL_END_OF_Q frame. It acts as a weak hangup request so the soft hangup requests that do not normally result in a hangup do not hangup. JIRA SWP-2470 JIRA SWP-2489 (closes issue #18171) Reported by: SantaFox (closes issue #18185) Reported by: kwemheuer (closes issue #18211) Reported by: zahir_koradia (closes issue #18230) Reported by: vmarrone (closes issue #18299) Reported by: mbrevda (closes issue #18322) Reported by: nerbos Review: https://reviewboard.asterisk.org/r/1013/ ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@295843 f38db490-d61c-443f-a65b-d21fe96a405b
2010-11-20Fix cache of device state changes for multiple servers.russell1-0/+20
This patch addresses a regression where device states across multiple servers were not being processing completely correctly. The code works to determine the overall state by looking at the last known state of a device on each server. However, there was a regression due to some invasive rewrites of how the cache works that led to the cache only storing the last device state change for a device, regardless of which server it was on. The code is set up to cache device state change events by ensuring that each event in the cache has a unique device name + entity ID (server ID). The code that was responsible for comparing raw information elements (which EID is) always returned a match due to a memcmp() with a length of 0. There isn't much code to fix the actual bug. This patch also introduces a new CLI command that was very useful for debugging this problem. The command allows you to dump the contents of the event cache. (closes issue #18284) Reported by: klaus3000 Patches: issue18284.rev1.txt uploaded by russell (license 2) Tested by: russell, klaus3000 (closes issue #18280) Reported by: klaus3000 Review: https://reviewboard.asterisk.org/r/1012/ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@295710 f38db490-d61c-443f-a65b-d21fe96a405b
2010-11-18Fix compiler warnings when using openssl-dev 1.0.0+pabelanger1-1/+1
Review: https://reviewboard.asterisk.org/r/1016/ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@295440 f38db490-d61c-443f-a65b-d21fe96a405b
2010-11-11Merged revisions 294384 via svnmerge from jpeeler1-0/+1
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r294384 | jpeeler | 2010-11-09 11:37:59 -0600 (Tue, 09 Nov 2010) | 47 lines Fix a deadlock in device state change processing. Copied from some notes from the original author (Russell): Deadlock scenario: Thread 1: device state change thread Holds - rdlock on contexts Holds - hints lock Waiting on channels container lock Thread 2: SIP monitor thread Holds the "iflock" Holds a sip_pvt lock Holds channel container lock Waiting for a channel lock Thread 3: A channel thread (chan_local in this case) Holds 2 channel locks acquired within app_dial Holds a 3rd channel lock it got inside of chan_local Holds a local_pvt lock Waiting on a rdlock of the contexts lock A bunch of other threads waiting on a wrlock of the contexts lock To address this deadlock, some locking order rules must be put in place and enforced. Existing relevant rules: 1) channel lock before a pvt lock 2) contexts lock before hints lock 3) channels container before a channel What's missing is some enforcement of the order when you involve more than any two. To fix this problem, I put in some code that ensures that (at least in the code paths involved in this bug) the locks in (3) come before the locks in (2). To change the operation of thread 1 to comply, I converted the storage of hints to an astobj2 container. This allows processing of hints without holding the hints container lock. So, in the code path that led to thread 1's state, it no longer holds either the contexts or hints lock while it attempts to lock the channels container. (closes issue #18165) Reported by: antonio ABE-2583 ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@294639 f38db490-d61c-443f-a65b-d21fe96a405b
2010-11-08Fix playback failure when using IAX with the timerfd module.jpeeler1-0/+10
To fix this issue the alert pipe will now be used when the timerfd module is in use. There appeared to be a race that was not solved by adding locking in the timerfd module, but needed to be there anyway. The race was between the timer being put in non-continuous mode in ast_read on the channel thread and the IAX frame scheduler queuing a frame which would enable continuous mode before the non-continuous mode event was read. This race for now is simply avoided. (closes issue #18110) Reported by: tpanton Tested by: tpanton I put tested by tpanton because it was tested on his hardware. Thanks for the remote access to debug this issue! git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@294277 f38db490-d61c-443f-a65b-d21fe96a405b
2010-10-07Merged revisions 290750 via svnmerge from qwell1-31/+22
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r290750 | qwell | 2010-10-07 15:56:04 -0500 (Thu, 07 Oct 2010) | 9 lines Allow PRI to build properly when using --with-pri. Use the directories found for the parent when using lib dependencies. (closes issue #17314) Reported by: tzafrir Patches: 17314-withdeps.diff uploaded by qwell (license 4) ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@290751 f38db490-d61c-443f-a65b-d21fe96a405b
2010-10-01Merged revisions 289797 via svnmerge from jpeeler1-0/+1
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r289797 | jpeeler | 2010-10-01 17:58:38 -0500 (Fri, 01 Oct 2010) | 15 lines Change RFC2833 DTMF event duration on end to report actual elapsed time. The scenario here is with a non P2P early media session. The reported time length of DTMF presses are coming up short when sending to the remote side. Currently the event duration is a running total that is incremented when sending continuation packets. These continuation packets are only triggered upon incoming media from the remote side, which means that the running total probably is not going to end up matching the actual length of time Asterisk received DTMF. This patch changes the end event duration to be lengthened if it is detected that the end event is going to come up short. Review: https://reviewboard.asterisk.org/r/957/ ABE-2476 ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@289798 f38db490-d61c-443f-a65b-d21fe96a405b
2010-09-24Merged revisions 288636 via svnmerge from tilghman3-13/+7
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r288636 | tilghman | 2010-09-23 22:20:24 -0500 (Thu, 23 Sep 2010) | 2 lines Solaris compatibility fixes ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@288637 f38db490-d61c-443f-a65b-d21fe96a405b
2010-09-10Merged revisions 286059 via svnmerge from twilson3-2/+27
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r286059 | twilson | 2010-09-10 14:25:08 -0500 (Fri, 10 Sep 2010) | 16 lines Inherit CHANNEL() writes to both sides of a Local channel Having Local (/n) channels as queue members and setting the language in the extension with Set(CHANNEL(language)=fr) sets the language on the Local/...,2 channel. Hold time report playbacks happen on the Local/...,1 channel and therefor do not play in the specified language. This patch modifies func_channel_write to call the setoption callback and pass the CHANNEL() write info to the callback. chan_local uses this information to look up the other side of the channel and apply the same changes to it. (closes issue #17673) Reported by: Guggemand Review: https://reviewboard.asterisk.org/r/903/ ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@286115 f38db490-d61c-443f-a65b-d21fe96a405b
2010-09-10Another fix for Mac OS X.tilghman1-6/+4
While trying to fix this the "right" way, I wandered into dependency hell. Two hours later, I backed out, and just removed the offending code. ast_inline_api only goes one level deep and then it breaks. Ouch. git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@285961 f38db490-d61c-443f-a65b-d21fe96a405b
2010-09-10Merged revisions 285889 via svnmerge from tilghman2-5/+18
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r285889 | tilghman | 2010-09-09 19:13:45 -0500 (Thu, 09 Sep 2010) | 7 lines Fix Mac OS X build. This also fixes a rather grievous calculation error for the offset of ast_fdset, which was masked on Linux and FreeBSD, because these platforms check the first 256 FDs regardless of the bitmask setting (due to backwards compatibility). ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@285930 f38db490-d61c-443f-a65b-d21fe96a405b
2010-09-09Fixes an issue with dialplan pattern matching where the specificity for ↵bbryant6-68/+165
pattern ranges and pattern special characters was inconsistent. (closes issue #16903) Reported by: Nick_Lewis Patches: pbx.c-specificity.patch uploaded by Nick Lewis (license 657) Tested by: Nick_Lewis git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@285710 f38db490-d61c-443f-a65b-d21fe96a405b
2010-07-27Merged revisions 279945 via svnmerge from dvossel1-0/+7
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r279945 | dvossel | 2010-07-27 15:33:40 -0500 (Tue, 27 Jul 2010) | 19 lines remove empty audiohook write list on channel If a channel has an audiohook write list created on it, that list stays on the channel until the channel is destroyed. There is no reason to keep that list on the channel if it becomes empty. If it is empty that just means we are doing needless translating for every ast_read and ast_write. This patch removes the audiohook list from the channel once it is detected to be empty on either a read or write. If a audiohook is added back to the channel after this list is destroyed, the list just gets recreated as if it never existed to begin with. (closes issue #17630) Reported by: manvirr Review: https://reviewboard.asterisk.org/r/799/ ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@279946 f38db490-d61c-443f-a65b-d21fe96a405b
2010-07-26Really fix sounds Makefile (and make it readableish).qwell1-30/+21
There was a rather large syntax error that should have caused ALL versions of GNU make to fail. I don't know how it worked. git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@279657 f38db490-d61c-443f-a65b-d21fe96a405b
2010-07-20Merged revisions 278272 via svnmerge from tilghman1-0/+12
https://origsvn.digium.com/svn/asterisk/trunk ................ r278272 | tilghman | 2010-07-20 17:26:23 -0500 (Tue, 20 Jul 2010) | 11 lines Merged revisions 278167 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r278167 | tilghman | 2010-07-20 15:59:06 -0500 (Tue, 20 Jul 2010) | 4 lines Do not queue up DTMF frames while a call is on hold. (Fixes ABE-2110) ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@278273 f38db490-d61c-443f-a65b-d21fe96a405b
2010-07-17Merged revisions 277775 via svnmerge from tilghman1-21/+30
https://origsvn.digium.com/svn/asterisk/trunk ................ r277775 | tilghman | 2010-07-17 12:42:32 -0500 (Sat, 17 Jul 2010) | 12 lines Merged revisions 277738 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r277738 | tilghman | 2010-07-17 11:59:11 -0500 (Sat, 17 Jul 2010) | 5 lines Remove uclibc cross-compile triplet, as uclibc has a working fork()... it's only uclinux that does not. (closes issue #17616) Reported by: pprindeville ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@277776 f38db490-d61c-443f-a65b-d21fe96a405b
2010-07-09Merged revisions 275022 via svnmerge from russell1-1/+6
https://origsvn.digium.com/svn/asterisk/trunk ................ r275022 | russell | 2010-07-09 10:35:53 -0500 (Fri, 09 Jul 2010) | 11 lines Merged revisions 275021 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r275021 | russell | 2010-07-09 10:33:08 -0500 (Fri, 09 Jul 2010) | 4 lines Document that a leading and trailing slash is expected for test categories. Also, emit a warning if a test is registered without one of these. ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@275023 f38db490-d61c-443f-a65b-d21fe96a405b
2010-07-03Merged revisions 273830 via svnmerge from tilghman1-12/+43
https://origsvn.digium.com/svn/asterisk/trunk ................ r273830 | tilghman | 2010-07-02 21:36:31 -0500 (Fri, 02 Jul 2010) | 16 lines Merged revisions 273793 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r273793 | tilghman | 2010-07-02 16:36:39 -0500 (Fri, 02 Jul 2010) | 9 lines Have the DEADLOCK_AVOIDANCE macro warn when an unlock fails, to help catch potentially large software bugs. (closes issue #17407) Reported by: pdf Patches: 20100527__issue17407.diff.txt uploaded by tilghman (license 14) Review: https://reviewboard.asterisk.org/r/751/ ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@273831 f38db490-d61c-443f-a65b-d21fe96a405b
2010-06-25Backport unit test API from trunk.russell2-0/+216
Also, update existing test modules that were already in this branch but had been converted to the unit test API in trunk. Review: https://reviewboard.asterisk.org/r/748/ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@272531 f38db490-d61c-443f-a65b-d21fe96a405b
2010-06-22Merged revisions 271690 via svnmerge from mnicholson1-0/+17
https://origsvn.digium.com/svn/asterisk/trunk ................ r271690 | mnicholson | 2010-06-22 07:58:28 -0500 (Tue, 22 Jun 2010) | 18 lines Merged revisions 271689 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r271689 | mnicholson | 2010-06-22 07:52:27 -0500 (Tue, 22 Jun 2010) | 8 lines Modify chan_sip's packet generation api to automatically calculate the Content-Length. This is done by storing packet content in a buffer until it is actually time to send the packet, at which time the size of the packet is calculated. This change was made to ensure that the Content-Length is always correct. (closes issue #17326) Reported by: kenner Tested by: mnicholson, kenner Review: https://reviewboard.asterisk.org/r/693/ ........ This change also adds an ast_str_copy_string() function (similar to ast_copy_string), that copies one ast_str into another, properly handling embedded nulls. ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@271691 f38db490-d61c-443f-a65b-d21fe96a405b
2010-06-18Merged revisions 271483 via svnmerge from jpeeler1-1/+1
https://origsvn.digium.com/svn/asterisk/trunk ................ r271483 | jpeeler | 2010-06-18 16:32:09 -0500 (Fri, 18 Jun 2010) | 18 lines Merged revisions 271399 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r271399 | jpeeler | 2010-06-18 14:28:24 -0500 (Fri, 18 Jun 2010) | 11 lines Fix crash when parsing some heavily nested statements in AEL on reload. Due to the recursion used when compiling AEL in gen_prios, all the stack space was being consumed when parsing some AEL that contained nesting 13 levels deep. Changing a few large buffers to be heap allocated fixed the crash, although I did not test how many more levels can now be safely used. (closes issue #16053) Reported by: diLLec Tested by: jpeeler ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@271484 f38db490-d61c-443f-a65b-d21fe96a405b
2010-06-09Merged revisions 269417 via svnmerge from russell1-2/+3
https://origsvn.digium.com/svn/asterisk/trunk ........ r269417 | russell | 2010-06-09 16:11:43 -0500 (Wed, 09 Jun 2010) | 6 lines Resolve an invalid memory read on an event. Valgrind pointed out that attempting to get an IE value from an event that has no IEs produces an invalid memory read past the end of the event. Thanks to mmichelson for pointing the problem out to me and then testing the fix. ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@269418 f38db490-d61c-443f-a65b-d21fe96a405b
2010-06-07Fix some chan_oss build system problems (these changes were already in trunk).russell1-30/+24
This is what caused a bunch of tests to fail on 1.6.2. They expected a console channel driver, but chan_oss was failing to load. git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@268815 f38db490-d61c-443f-a65b-d21fe96a405b
2010-06-04Merged revisions 267862,267877 via svnmerge from tilghman1-39/+39
https://origsvn.digium.com/svn/asterisk/trunk ........ r267862 | tilghman | 2010-06-03 21:58:55 -0500 (Thu, 03 Jun 2010) | 5 lines As signed linear audio data is accessed as 16-bit values, certain processors require the values to be aligned in memory. (closes issue #16912) Reported by: michaelevdokimov ........ r267877 | tilghman | 2010-06-03 22:20:47 -0500 (Thu, 03 Jun 2010) | 8 lines As signed linear audio data is accessed as 16-bit values, certain processors require the values to be aligned in memory. (closes issue #16912) Reported by: michaelevdokimov Patches: asterisk.patch uploaded by michaelevdokimov (license 997) Tested by: michaelevdokimov ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@267883 f38db490-d61c-443f-a65b-d21fe96a405b
2010-06-04Merged revisions 267775 via svnmerge from tilghman1-3/+0
https://origsvn.digium.com/svn/asterisk/trunk ................ r267775 | tilghman | 2010-06-03 20:20:17 -0500 (Thu, 03 Jun 2010) | 14 lines Merged revisions 267759 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r267759 | tilghman | 2010-06-03 20:16:26 -0500 (Thu, 03 Jun 2010) | 7 lines Make the default install path appear to be /usr on Linux, instead of /usr/local. Also, reorganize the options, so that they're more alphabetical. (closes issue #17013) Reported by: klaus3000 ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@267787 f38db490-d61c-443f-a65b-d21fe96a405b
2010-06-03Add fields back to ast_translator for ABI reasons.mmichelson1-0/+2
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@267527 f38db490-d61c-443f-a65b-d21fe96a405b
2010-06-03Merged revisions 267492 via svnmerge from mmichelson1-4/+2
https://origsvn.digium.com/svn/asterisk/trunk ........ r267492 | mmichelson | 2010-06-03 12:09:11 -0500 (Thu, 03 Jun 2010) | 6 lines Remove unnecessary code relating to PLC. The logic for handling generic PLC is now handled in ast_write in channel.c instead of in translation code. ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@267507 f38db490-d61c-443f-a65b-d21fe96a405b
2010-06-02Merged revisions 267065 via svnmerge from jpeeler1-60/+36
https://origsvn.digium.com/svn/asterisk/trunk ........ r267065 | jpeeler | 2010-06-02 12:29:35 -0500 (Wed, 02 Jun 2010) | 12 lines Fix infinite loop when loading codec speex This changes the sample slinear frame data to contain non-zero data so that translation calculations for speex works when preprocessing and VAD is turned on. The encoder expects samples to be returned, but when attempted with the mentioned two options and silent sample frames everything was discarded. (closes issue #17240) Reported by: seandarcy Review: https://reviewboard.asterisk.org/r/682/ ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@267073 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-26Merged revisions 265747 via svnmerge from tilghman1-3/+0
https://origsvn.digium.com/svn/asterisk/trunk ........ r265747 | tilghman | 2010-05-25 19:29:40 -0500 (Tue, 25 May 2010) | 8 lines Use configure to determine the prefixes and include directories properly. This ensures cross-platform compatibility, even among Linux distributions, which don't always put headers in the same place. (closes issue #17391) Reported by: loloski ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@265748 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-24Merged revisions 265320,265467 via svnmerge from twilson1-0/+3
https://origsvn.digium.com/svn/asterisk/trunk ........ r265320 | twilson | 2010-05-24 14:06:40 -0500 (Mon, 24 May 2010) | 14 lines Add the FullyBooted AMI event It is possible to connect to the manager interface before all Asterisk modules are loaded. To ensure that an application does not send AMI actions that might require a module that has not yet loaded, the application can listen for the FullyBooted manager event. It will be sent upon connection if all modules have been loaded, or as soon as loading is complete. The event: Event: FullyBooted Privilege: system,all Status: Fully Booted Review: https://reviewboard.asterisk.org/r/639/ ........ r265467 | twilson | 2010-05-24 17:21:58 -0500 (Mon, 24 May 2010) | 1 line Merge the rest of the FullyBooted patch ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@265521 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-21Merged revisions 265090 via svnmerge from mmichelson1-1/+1
https://origsvn.digium.com/svn/asterisk/trunk ................ r265090 | mmichelson | 2010-05-21 16:08:51 -0500 (Fri, 21 May 2010) | 15 lines Merged revisions 265089 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r265089 | mmichelson | 2010-05-21 15:59:14 -0500 (Fri, 21 May 2010) | 8 lines Don't hang up on a queue caller if the file we attempt to play does not exist. This also fixes a documentation mistake in file.h that made my original attempt to correct this problem not work correctly. (closes issue #17061) Reported by: RoadKill ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@265091 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-21Merged revisions 265000 via svnmerge from mmichelson1-1/+1
https://origsvn.digium.com/svn/asterisk/trunk ................ r265000 | mmichelson | 2010-05-21 11:54:21 -0500 (Fri, 21 May 2010) | 9 lines Merged revisions 264999 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r264999 | mmichelson | 2010-05-21 11:53:53 -0500 (Fri, 21 May 2010) | 3 lines Fix grammatical error in comment. ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@265001 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-21Merged revisions 264997 via svnmerge from mmichelson1-1/+18
https://origsvn.digium.com/svn/asterisk/trunk ................ r264997 | mmichelson | 2010-05-21 11:44:27 -0500 (Fri, 21 May 2010) | 38 lines Merged revisions 264996 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r264996 | mmichelson | 2010-05-21 11:28:34 -0500 (Fri, 21 May 2010) | 32 lines Allow ast_safe_sleep to defer specific frames until after the sleep has concluded. From reviewboard Background: A Digium customer discovered a somewhat odd bug. The setup is that parties A and B are bridged, and party A places party B on hold. While party B is listening to hold music, he mashes a bunch of DTMF. Party A takes party B off hold while this is happening, but party B continues to hear hold music. I could reproduce this about 1 in 5 times. The issue: When DTMF features are enabled and a user presses keys, the channel that the DTMF is streamed to is placed in an ast_safe_sleep for 100 ms, the duration of the emulated tone. If an AST_CONTROL_UNHOLD frame is read from the channel during the sleep, the frame is dropped. Thus the unhold indication is never made to the channel that was originally placed on hold. The fix: Originally, I discussed with Kevin possible ways of fixing the specific problem reported. However, we determined that the same type of problem could happen in other situations where ast_safe_sleep() is used. Using autoservice as a model, I modified ast_safe_sleep_conditional() to defer specific frame types so they can be re-queued once the sleep has finished. I made a common function for determining if a frame should be deferred so that there are not two identical switch blocks to maintain. Review: https://reviewboard.asterisk.org/r/674/ ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@264998 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-19Merged revisions 264452 via svnmerge from mmichelson2-0/+10
https://origsvn.digium.com/svn/asterisk/trunk ........ r264452 | mmichelson | 2010-05-19 16:29:08 -0500 (Wed, 19 May 2010) | 86 lines Fix transcode_via_sln option with SIP calls and improve PLC usage. From reviewboard: The problem here is a bit complex, so try to bear with me... It was noticed by a Digium customer that generic PLC (as configured in codecs.conf) did not appear to actually be having any sort of benefit when packet loss was introduced on an RTP stream. I reproduced this issue myself by streaming a file across an RTP stream and dropping approx. 5% of the RTP packets. I saw no real difference between when PLC was enabled or disabled when using wireshark to analyze the RTP streams. After analyzing what was going on, it became clear that one of the problems faced was that when running my tests, the translation paths were being set up in such a way that PLC could not possibly work as expected. To illustrate, if packets are lost on channel A's read stream, then we expect that PLC will be applied to channel B's write stream. The problem is that generic PLC can only be done when there is a translation path that moves from some codec to SLINEAR. When I would run my tests, I found that every single time, read and write translation paths would be set up on channel A instead of channel B. There appeared to be no real way to predict which channel the translation paths would be set up on. This is where Kevin swooped in to let me know about the transcode_via_sln option in asterisk.conf. It is supposed to work by placing a read translation path on both channels from the channel's rawreadformat to SLINEAR. It also will place a write translation path on both channels from SLINEAR to the channel's rawwriteformat. Using this option allows one to predictably set up translation paths on all channels. There are two problems with this, though. First and foremost, the transcode_via_sln option did not appear to be working properly when I was placing a SIP call between two endpoints which did not share any common formats. Second, even if this option were to work, for PLC to be applied, there had to be a write translation path that would go from some format to SLINEAR. It would not work properly if the starting format of translation was SLINEAR. The one-line change presented in this review request in chan_sip.c fixed the first issue for me. The problem was that in sip_request_call, the jointcapability of the outbound channel was being set to the format passed to sip_request_call. This is nativeformats of the inbound channel. Because of this, when ast_channel_make_compatible was called by app_dial, both channels already had compatibly read and write formats. Thus, no translation path was set up at the time. My change is to set the jointcapability of the sip_pvt created during sip_request_call to the intersection of the inbound channel's nativeformats and the configured peer capability that we determined during the earlier call to create_addr. Doing this got the translation paths set up as expected when using transcode_via_sln. The changes presented in channel.c fixed the second issue for me. First and foremost, when Asterisk is started, we'll read codecs.conf to see the value of the genericplc option. If this option is set, and ast_write is called for a frame with no data, then we will attempt to fill in the missing samples for the frame. The implementation uses a channel datastore for maintaining the PLC state and for creating a buffer to store PLC samples in. Even when we receive a frame with data, we'll call plc_rx so that the PLC state will have knowledge of the previous voice frame, which it can use as a basis for when it comes time to actually do a PLC fill-in. So, reviewers, now I ask for your help. First off, there's the one line change in chan_sip that I have put in. Is it right? By my logic it seems correct, but I'm sure someone can tell me why it is not going to work. This is probably the change I'm least concerned about, though. What concerns me much more is the set of changes in channel.c. First off, am I even doing it right? When I run tests, I can clearly see that when PLC is activated, I see a significant increase in RTP traffic where I would expect it to be. However, in my humble opinion, the audio sounds kind of crappy whenever the PLC fill-in is done. It sounds worse to me than when no PLC is used at all. I need someone to review the logic I have used to be sure that I'm not misusing anything. As far as I can see my pointer arithmetic is correct, and my use of AST_FRIENDLY_OFFSET should be correct as well, but I'm sure someone can point out somewhere where I've done something incorrectly. As I was writing this review request up, I decided to give the code a test run under valgrind, and I find that for some reason, calls to plc_rx are causing some invalid reads. Apparently I'm reading past the end of a buffer somehow. I'll have to dig around a bit to see why that is the case. If it's obvious to someone reviewing, speak up! Finally, I have one other proposal that is not reflected in my code review. Since without transcode_via_sln set, one cannot predict or control where a translation path will be up, it seems to me that the current practice of using PLC only when transcoding to SLINEAR is not useful. I recommend that once it has been determined that the method used in this code review is correct and works as expected, then the code in translate.c that invokes PLC should be removed. Review: https://reviewboard.asterisk.org/r/622/ ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@264453 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-19Merged revisions 264249 via svnmerge from tilghman2-0/+9
https://origsvn.digium.com/svn/asterisk/trunk ................ r264249 | tilghman | 2010-05-19 12:48:31 -0500 (Wed, 19 May 2010) | 24 lines Merged revisions 264248 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r264248 | tilghman | 2010-05-19 12:41:29 -0500 (Wed, 19 May 2010) | 17 lines Internal timing is now on by default, if you're using DAHDI 2.3 or above. The reason for ensuring DAHDI 2.3 or above is that this version ensures that a timer is always available, whereas in previous versions, it was possible for DAHDI to be loaded, but have no drivers to actually generate timing. If internal_timing was turned on in this circumstance, a complete lack of audio would result. This is the reason why internal_timing was not on by default. However, now that DAHDI ensures the availability of a timer, there is no reason for this setting to be off (and in fact, it solves a great many initial user problems). (closes issue #15932) Reported by: dimas Patches: 20100519__issue15932.diff.txt uploaded by tilghman (license 14) Tested by: tilghman ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@264250 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-11Merged revisions 262513 via svnmerge from tilghman1-106/+107
https://origsvn.digium.com/svn/asterisk/trunk ........ r262513 | tilghman | 2010-05-11 16:25:05 -0500 (Tue, 11 May 2010) | 7 lines Move cause 200 to cause 26, as specified in Q.850. Also cleanup the formatting and add a few more that seem like good candidates. (closes issue #16157) Reported by: wimpy ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@262516 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-09Merged revisions 262102 via svnmerge from tilghman1-213/+0
https://origsvn.digium.com/svn/asterisk/trunk ........ r262102 | tilghman | 2010-05-08 21:14:04 -0500 (Sat, 08 May 2010) | 5 lines Cleanup a bit more by getting rid of useless version defines. Also make library detection use passed CFLAGS. (closes issue #17309) Reported by: stuarth ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@262105 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-07Merged revisions 261913 via svnmerge from tilghman1-30/+28
https://origsvn.digium.com/svn/asterisk/trunk ........ r261913 | tilghman | 2010-05-07 15:35:17 -0500 (Fri, 07 May 2010) | 14 lines Use the detected pthread building flags in every place, instead of hardcoding -lpthread. We nicely detect the right flags on each system for building Asterisk with pthreads, then ignore it for every other build option that requires us to build with pthreads. This caused some items to return a false negative. Also cleanup some minor naming issues that caused "library library" redundancy in the output. (closes issue #17303) Reported by: stuarth Patches: 20100507__issue17303.diff.txt uploaded by tilghman (license 14) Tested by: stuarth ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@261916 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-04Merged revisions 254450 via svnmerge from mnicholson1-1/+2
https://origsvn.digium.com/svn/asterisk/trunk ........ r254450 | kpfleming | 2010-03-25 10:27:31 -0500 (Thu, 25 Mar 2010) | 49 lines Improve handling of T.38 re-INVITEs that arrive before a T.38-capable application is executing on a channel. This patch addresses an issue found during working with end-users using res_fax. If an incoming call is answered in the dialplan, or jumps to the 'fax' extension due to reception of a CNG tone (with faxdetect enabled), and then the remote endpoint sends a T.38 re-INVITE, it is possible for the channel's T.38 state to be 'T38_STATE_NEGOTIATING' when the application starts up. Unfortunately, even if the application wants to use T.38, it can't respond to the peer's negotiation request, because the AST_CONTROL_T38_PARAMETERS control frame that chan_sip sent originally has been lost, and the application needs the content of that frame to be able to formulate a reply. This patch adds a new 'request' type to AST_CONTROL_T38_PARAMETERS, AST_T38_REQUEST_PARMS. If the application sends this request, chan_sip will re-send the original control frame (with AST_T38_REQUEST_NEGOTIATE as the request type), and the application can respond as normal. If this occurs within the five second timeout in chan_sip, the automatic cancellation of the peer reinvite will be stopped, and the application will 'own' the negotiation process from that point onwards. This also improves the code path in chan_sip to allow sip_indicate(), when called for AST_CONTROL_T38_PARAMETERS, to be able to return a non-zero response, which should have been in place before since the control frame *can* fail to be processed properly. It also modifies ast_indicate() to return whatever result the channel driver returned for this control frame, rather than converting all non-zero results into '-1'. Finally, the new request type intentionally returns a positive value, so that an application that sends AST_T38_REQUEST_PARMS can know for certain whether the channel driver accepted it and will be replying with a control frame of its own, or whether it was ignored (if the sip_indicate()/ast_indicate() path had properly supported failure responses before, this would not be necessary). This patch also modifies res_fax to take advantage of the new request. In addition, this patch makes sip_t38_abort() actually lock the private structure before doing its work... bad programmer, no donut. This patch also enhances chan_sip's 'faxdetect' support to allow triggering on T.38 re-INVITEs received as well as CNG tone detection. Review: https://reviewboard.asterisk.org/r/556/ ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@260884 f38db490-d61c-443f-a65b-d21fe96a405b
2010-04-29Merged revisions 260050 via svnmerge from dvossel1-3/+10
https://origsvn.digium.com/svn/asterisk/trunk ................ r260050 | dvossel | 2010-04-29 10:33:27 -0500 (Thu, 29 Apr 2010) | 21 lines Merged revisions 260049 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r260049 | dvossel | 2010-04-29 10:31:02 -0500 (Thu, 29 Apr 2010) | 14 lines Fixes crash in audiohook_write_list The middle_frame in the audiohook_write_list function was being freed if a audiohook manipulator returned a failure. This is incorrect logic. This patch resolves this and adds detailed descriptions of how this function should work and why manipulator failures must be ignored. (closes issue #17052) Reported by: dvossel Tested by: dvossel (closes issue #16196) Reported by: atis Review: https://reviewboard.asterisk.org/r/623/ ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@260051 f38db490-d61c-443f-a65b-d21fe96a405b
2010-04-15Merged revisions 257560 via svnmerge from tilghman1-2/+1
https://origsvn.digium.com/svn/asterisk/trunk ................ r257560 | tilghman | 2010-04-15 16:26:19 -0500 (Thu, 15 Apr 2010) | 13 lines Merged revisions 257544 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r257544 | tilghman | 2010-04-15 16:23:24 -0500 (Thu, 15 Apr 2010) | 6 lines Allow application options with arguments to contain parentheses, through a variety of escaping techniques. Fixes SWP-1194 (ABE-2143). Review: https://reviewboard.asterisk.org/r/604/ ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@257597 f38db490-d61c-443f-a65b-d21fe96a405b
2010-04-06Merged revisions 256370 via svnmerge from tilghman2-18/+22
https://origsvn.digium.com/svn/asterisk/trunk ........ r256370 | tilghman | 2010-04-06 14:28:42 -0500 (Tue, 06 Apr 2010) | 2 lines Mac OS X does not support comparing a mutex to its initializer. Create a test for this. ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@256373 f38db490-d61c-443f-a65b-d21fe96a405b
2010-04-01Merged revisions 255796 via svnmerge from tilghman1-5/+1
https://origsvn.digium.com/svn/asterisk/trunk ........ r255796 | tilghman | 2010-04-01 13:16:37 -0500 (Thu, 01 Apr 2010) | 7 lines Fix DEBUG_THREADS build on Darwin. (closes issue #16828) Reported by: oej Patches: 20100331__issue16828.diff.txt uploaded by tilghman (license 14) ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@255816 f38db490-d61c-443f-a65b-d21fe96a405b
2010-03-25Fix DEBUG_THREADS issue with out-of-tree modules.qwell1-9/+6
Take 2, without ABI breakage this time. Review: https://reviewboard.asterisk.org/r/588/ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@254770 f38db490-d61c-443f-a65b-d21fe96a405b
2010-03-25Merged revisions 254553 via svnmerge from mmichelson1-7/+176
https://origsvn.digium.com/svn/asterisk/trunk ................ r254553 | mmichelson | 2010-03-25 12:42:36 -0500 (Thu, 25 Mar 2010) | 11 lines Merged revisions 254552 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r254552 | mmichelson | 2010-03-25 12:33:35 -0500 (Thu, 25 Mar 2010) | 5 lines Add doxygen for acl.h Review: https://reviewboard.asterisk.org/r/528 ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@254556 f38db490-d61c-443f-a65b-d21fe96a405b
2010-03-17Revert API change in release branchestwilson1-1/+1
This re-renames ast_rtp_update_source to ast_rtp_new_source git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@253158 f38db490-d61c-443f-a65b-d21fe96a405b