aboutsummaryrefslogtreecommitdiffstats
path: root/include
AgeCommit message (Collapse)AuthorFilesLines
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
2010-03-13Merged revisions 252089 via svnmerge from twilson2-4/+7
https://origsvn.digium.com/svn/asterisk/trunk ........ r252089 | twilson | 2010-03-12 16:04:51 -0600 (Fri, 12 Mar 2010) | 20 lines Only change the RTP ssrc when we see that it has changed This change basically reverts the change reviewed in https://reviewboard.asterisk.org/r/374/ and instead limits the updating of the RTP synchronization source to only those times when we detect that the other side of the conversation has changed the ssrc. The problem is that SRCUPDATE control frames are sent many times where we don't want a new ssrc, including whenever Asterisk has to send DTMF in a normal bridge. This is also not the first time that this mistake has been made. The initial implementation of the ast_rtp_new_source function also changed the ssrc--and then it was removed because of this same issue. Then, we put it back in again to fix a different issue. This patch attempts to only change the ssrc when we see that the other side of the conversation has changed the ssrc. It also renames some functions to make their purpose more clear. Review: https://reviewboard.asterisk.org/r/540/ ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@252137 f38db490-d61c-443f-a65b-d21fe96a405b
2010-03-02Merged revisions 249893 via svnmerge from dvossel1-2/+5
https://origsvn.digium.com/svn/asterisk/trunk ........ r249893 | dvossel | 2010-03-02 13:08:38 -0600 (Tue, 02 Mar 2010) | 11 lines fixes adaptive jitterbuffer configuration When configuring the adaptive jitterbuffer, the target_extra value not only could not be set from the configuration, but was not even being set to its proper default. This value is required in order for the adaptive jitterbuffer to work correctly. To resolve this a config option has been added to expose this value to the conf files, and a default value is provided when no config specific value is present. ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@249895 f38db490-d61c-443f-a65b-d21fe96a405b
2010-02-28Merged revisions 249405 via svnmerge from tilghman1-7/+32
https://origsvn.digium.com/svn/asterisk/trunk ........ r249405 | tilghman | 2010-02-28 01:10:22 -0600 (Sun, 28 Feb 2010) | 2 lines Properly document voicemail API documents. Also fix a crash reported via the -dev list. ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@249407 f38db490-d61c-443f-a65b-d21fe96a405b
2010-02-17Merged revisions 247335 via svnmerge from mmichelson1-11/+11
https://origsvn.digium.com/svn/asterisk/trunk ........ r247335 | mmichelson | 2010-02-17 15:22:40 -0600 (Wed, 17 Feb 2010) | 20 lines Fix two problems in ast_str functions found while writing a unit test. 1. The documentation for ast_str_set and ast_str_append state that the max_len parameter may be -1 in order to limit the size of the ast_str to its current allocated size. The problem was that the max_len parameter in all cases was a size_t, which is unsigned. Thus a -1 was interpreted as UINT_MAX instead of -1. Changing the max_len parameter to be ssize_t fixed this issue. 2. Once issue 1 was fixed, there was an off-by-one error in the case where we attempted to write a string larger than the current allotted size to a string when -1 was passed as the max_len parameter. When trying to write more than the allotted size, the ast_str's __AST_STR_USED was set to 1 higher than it should have been. Thanks to Tilghman for quickly spotting the offending line of code. Oh, and the unit test that I referenced in the top line of this commit will be added to reviewboard shortly. Sit tight... ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@247337 f38db490-d61c-443f-a65b-d21fe96a405b
2010-02-16Merged revisions 246985 via svnmerge from mmichelson1-2/+7
https://origsvn.digium.com/svn/asterisk/trunk ........ r246985 | mmichelson | 2010-02-16 15:15:38 -0600 (Tue, 16 Feb 2010) | 3 lines Add some clarifying documentation to the ast_str_set and ast_str_append functions. ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@246989 f38db490-d61c-443f-a65b-d21fe96a405b
2010-02-10Merged revisions 246030 via svnmerge from tilghman1-0/+3
https://origsvn.digium.com/svn/asterisk/trunk ........ r246030 | tilghman | 2010-02-10 10:01:28 -0600 (Wed, 10 Feb 2010) | 12 lines Solaris doesn't like outputting a NULL to a %s in format strings. Detect all platforms that don't like that, either, and ensure that when documentation is missing, we pass a non-NULL pointer when outputting the corresponding documentation. (closes issue #16689) Reported by: bklang Patches: 20100209__issue16689__with_tests.diff.txt uploaded by tilghman (license 14) Review: https://reviewboard.asterisk.org/r/497/ ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@246199 f38db490-d61c-443f-a65b-d21fe96a405b
2010-02-02Merged revisions 244443 via svnmerge from dvossel1-0/+16
https://origsvn.digium.com/svn/asterisk/trunk ........ r244443 | dvossel | 2010-02-02 16:27:23 -0600 (Tue, 02 Feb 2010) | 18 lines fixes crash during T.38 negotiation caused by invalid or missing FaxMaxDatagram field AST-2010-001 (closes issue #16634) Reported by: krn (closes issue #16724) Reported by: barthpbx (closes issue #16517) Reported by: bklang (closes issue #16485) Reported by: elsto ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@244445 f38db490-d61c-443f-a65b-d21fe96a405b
2010-01-24Merged revisions 242521 via svnmerge from tilghman1-21/+30
https://origsvn.digium.com/svn/asterisk/trunk ................ r242521 | tilghman | 2010-01-24 00:40:31 -0600 (Sun, 24 Jan 2010) | 15 lines Merged revisions 242520 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r242520 | tilghman | 2010-01-24 00:33:01 -0600 (Sun, 24 Jan 2010) | 8 lines Only rebuild bison and flex source files on demand, if bison and flex are detected by the configure script. Changed after discussion on the -dev list about possible unnecessary build failures, due to checkouts/untars causing these special source files to possibly be newer than their resulting C files. This should additionally ensure that nobody need learn about extra Makefile arguments to ensure the proper files get rebuilt when changes are made to these special source files. ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@242522 f38db490-d61c-443f-a65b-d21fe96a405b
2010-01-08Merged revisions 238635 via svnmerge from dvossel1-0/+3
https://origsvn.digium.com/svn/asterisk/trunk ........ r238635 | dvossel | 2010-01-08 13:39:30 -0600 (Fri, 08 Jan 2010) | 22 lines fixes AUDIOHOOK_INHERIT regression During the process of removing an audiohook from one channel and attaching it to another the audiohook's status is updated to DONE and then back to whatever it was previously. Typically updating the status after setting it to DONE is not a good idea because DONE can trigger unrecoverable audiohook destruction events... because of this a conditional check was added to audiohook_update_status to explicitly prevent the audiohook from ever changing after being set to DONE. It was this check that prevented audiohook inherit from work properly though. Now ast_audiohook_move_by_source is treated as a special exception, as the audiohook must be returned to its previous status after attaching it to the new channel. This is only a safe operation because the audiohook's lock is held the entire time, otherwise this could cause trouble. (closes issue #16522) Reported by: corruptor ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@238637 f38db490-d61c-443f-a65b-d21fe96a405b
2010-01-07Merged revisions 209400 via svnmerge from tilghman1-0/+5
https://origsvn.digium.com/svn/asterisk/trunk ........ r209400 | kpfleming | 2009-07-28 08:49:46 -0500 (Tue, 28 Jul 2009) | 3 lines Define side-effect-safe MIN and MAX macros and remove duplicate definitions from various files. (closes issue #16251) Reported by: asgaroth ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@238499 f38db490-d61c-443f-a65b-d21fe96a405b
2010-01-04Merged revisions 237406 via svnmerge from tilghman1-0/+4
https://origsvn.digium.com/svn/asterisk/trunk ................ r237406 | tilghman | 2010-01-04 12:28:28 -0600 (Mon, 04 Jan 2010) | 23 lines Merged revisions 237405 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r237405 | tilghman | 2010-01-04 12:19:00 -0600 (Mon, 04 Jan 2010) | 16 lines Add a flag to disable the Background behavior, for AGI users. This is in a section of code that relates to two other issues, namely issue #14011 and issue #14940), one of which was the behavior of Background when called with a context argument that matched the current context. This fix broke FreePBX, however, in a post-Dial situation. Needless to say, this is an extremely difficult collision of several different issues. While the use of an exception flag is ugly, fixing all of the issues linked is rather difficult (although if someone would like to propose a better solution, we're happy to entertain that suggestion). (closes issue #16434) Reported by: rickead2000 Patches: 20091217__issue16434.diff.txt uploaded by tilghman (license 14) 20091222__issue16434__1.6.1.diff.txt uploaded by tilghman (license 14) Tested by: rickead2000 ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@237409 f38db490-d61c-443f-a65b-d21fe96a405b
2009-12-28Merged revisions 236613 via svnmerge from seanbright2-32/+32
https://origsvn.digium.com/svn/asterisk/trunk ................ r236613 | seanbright | 2009-12-28 10:22:54 -0500 (Mon, 28 Dec 2009) | 14 lines Merged revisions 236585 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r236585 | seanbright | 2009-12-28 10:12:08 -0500 (Mon, 28 Dec 2009) | 7 lines Try a test compile to see if PTHREAD_ONCE_INIT requires extra braces. There was conditional code (based on build platform) to optioinally wrap PTHREAD_ONCE_INIT in braces that was removed since it is fixed in newer versions of Solaris/OpenSolaris, but I am still running into it on Solaris 10 x86 so add a configure-time check for it. ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@236635 f38db490-d61c-443f-a65b-d21fe96a405b
2009-12-18Merged revisions 235660 via svnmerge from jpeeler1-5/+5
https://origsvn.digium.com/svn/asterisk/trunk ................ r235660 | jpeeler | 2009-12-18 16:51:37 -0600 (Fri, 18 Dec 2009) | 55 lines Merged revisions 235635 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r235635 | jpeeler | 2009-12-18 16:29:51 -0600 (Fri, 18 Dec 2009) | 48 lines Correct CDR dispositions for BUSY/FAILED This patch is simple in that it reorders the disposition defines so that the fix for issue 12946 works properly (the default CDR disposition was changed to AST_CDR_NOANSWER). Also, the AST_CDR_FLAG_ORIGINATED flag was set in ast_call to ensure all CDR records are written. The side effects of CDR changes are scary, so I'm documenting the test cases performed to attempt to catch any regressions. The following tests were all performed using 1.4 rev 195881 vs head (235571) + patch: A calls B C calls B (busy) Hangup C Hangup A (Both SIP and features) A calls B A blind transfers to C Hangup C (Both SIP and features) A calls B A attended transfers to C Hangup C A calls B A attended transfers to C (SIP) C blind transfers to A (features) Hangup A All of the test scenario CDRs matched. The following tests were performed just with the patch to ensure proper operation (with unanswered=yes): exten =>s,1,Answer exten =>s,n,ResetCDR(w) exten =>s,n,ResetCDR(w) exten =>s,1,ResetCDR(w) exten =>s,n,ResetCDR(w) (closes issue #16180) Reported by: aatef Patches: bug16180.patch uploaded by jpeeler (license 325) ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@235665 f38db490-d61c-443f-a65b-d21fe96a405b
2009-11-30Merged revisions 231692 via svnmerge from kpfleming1-2/+17
https://origsvn.digium.com/svn/asterisk/trunk ........ r231692 | kpfleming | 2009-11-30 15:47:42 -0600 (Mon, 30 Nov 2009) | 22 lines Another round of UDPTL stack fixes/improvements: 1) Allow users of UDPTL stack to associate a character-string tag with a UDPTL session, so that log/error/debug messages generated by the UDPTL stack can be 'connected' to the endpoint that caused them to be generated. 2) Improve comments (and process) of calculating the far end's maximum IFP size when redundancy mode is in use for error correction. 3) When an IFP larger than the calculated 'far max IFP' size is presented for writing, truncate it rather than putting in the buffer and allowing the buffer to overflow; this will cause the ends to retrain to a lower bit rate that produces IFPs of an appropriate size if possible, and if not possible, the FAX transfer will fail completely. In these cases, it is due to the one endpoint supplying a T38FaxMaxDatagram value that is improperly calculated and is too low to be of use; we have configuration options available to override this behavior. 4) Eliminate use of T38FaxMaxDatagram value in udptl.conf; it is no longer needed. ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@231696 f38db490-d61c-443f-a65b-d21fe96a405b
2009-11-30Merged revisions 231688 via svnmerge from mnicholson1-0/+11
https://origsvn.digium.com/svn/asterisk/trunk ................ r231688 | mnicholson | 2009-11-30 15:31:55 -0600 (Mon, 30 Nov 2009) | 15 lines Merged revisions 231614 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r231614 | mnicholson | 2009-11-30 15:11:44 -0600 (Mon, 30 Nov 2009) | 8 lines Remove duplicate entries from voicemail format lists. This prevents app_voicemail from entering an infinite loop when the same format is specified twice in the format list. (closes issue #15625) Reported by: Shagg63 Tested by: mnicholson Review: https://reviewboard.asterisk.org/r/429/ ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@231689 f38db490-d61c-443f-a65b-d21fe96a405b
2009-11-20Merged revisions 230583 via svnmerge from dvossel1-0/+6
https://origsvn.digium.com/svn/asterisk/trunk ........ r230583 | dvossel | 2009-11-20 11:26:20 -0600 (Fri, 20 Nov 2009) | 6 lines audiohook signal trigger on every status change (issue #14618) Review: https://reviewboard.asterisk.org/r/434/ ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@230585 f38db490-d61c-443f-a65b-d21fe96a405b
2009-11-09Merged revisions 228858 via svnmerge from mnicholson1-14/+15
https://origsvn.digium.com/svn/asterisk/trunk ................ r228858 | mnicholson | 2009-11-09 08:37:07 -0600 (Mon, 09 Nov 2009) | 15 lines Merged revisions 228827 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r228827 | mnicholson | 2009-11-09 08:16:03 -0600 (Mon, 09 Nov 2009) | 8 lines Perform limited bounds checking when destroying ast_mutex_t structures to make sure we don't try to use negative indices. (closes issue #15588) Reported by: zerohalo Patches: 20090820__issue15588.diff.txt uploaded by tilghman (license 14) Tested by: zerohalo ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@228859 f38db490-d61c-443f-a65b-d21fe96a405b
2009-10-28Merged revisions 226305 via svnmerge from tilghman1-2/+2
https://origsvn.digium.com/svn/asterisk/trunk ................ r226305 | tilghman | 2009-10-28 13:04:05 -0500 (Wed, 28 Oct 2009) | 9 lines Merged revisions 226304 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r226304 | tilghman | 2009-10-28 13:02:25 -0500 (Wed, 28 Oct 2009) | 2 lines Fix documentation (pointed out by TheDavidFactor on #-dev) ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@226308 f38db490-d61c-443f-a65b-d21fe96a405b
2009-10-22Merged revisions 225445 via svnmerge from dvossel1-6/+8
https://origsvn.digium.com/svn/asterisk/trunk ........ r225445 | dvossel | 2009-10-22 14:55:51 -0500 (Thu, 22 Oct 2009) | 50 lines SIP TCP/TLS: move client connection setup/write into tcp helper thread, various related locking/memory fixes. What this patch fixes 1.Moves sip TCP/TLS connection setup into the TCP helper thread: Connection setup takes awhile and before this it was being done while holding the monitor lock. 2.Moves TCP/TLS writing to the TCP helper thread: Through the use of a packet queue and an alert pipe, the TCP helper thread can now be woken up to write data as well as read data. 3.Locking error: sip_xmit returned an XMIT_ERROR without giving up the tcptls_session lock. This lock has been completely removed from sip_xmit and placed in the new sip_tcptls_write() function. 4.Memory leak: When creating a tcptls_client the tls_cfg was alloced but never freed unless the tcptls_session failed to start. Now the session_args for a sip client are an ao2 object which frees the tls_cfg on destruction. 5.Pointer to stack variable: During sip_prepare_socket the creation of a client's ast_tcptls_session_args was done on the stack and stored as a pointer in the newly created tcptls_session. Depending on the events that followed, there was a slight possibility that pointer could have been accessed after the stack returned. Given the new changes, it is always accessed after the stack returns which is why I found it. Notable code changes 1.I broke tcptls.c's ast_tcptls_client_start() function into two functions. One for creating and allocating the new tcptls_session, and a separate one for starting and handling the new connection. This allowed me to create the tcptls_session, launch the helper thread, and then establish the connection within the helper thread. 2.Writes to a tcptls_session are now done within the helper thread. This is done by using an alert pipe to wake up the thread if new data needs to be sent. The thread's sip_threadinfo object contains the alert pipe as well as the packet queue. 3.Since the threadinfo object contains the alert pipe, it must now be accessed outside of the helper thread for every write (queuing of a packet). For easy lookup, I moved the threadinfo objects from a linked list to an ao2_container. (closes issue #13136) Reported by: pabelanger Tested by: dvossel, whys (closes issue #15894) Reported by: dvossel Tested by: dvossel Review: https://reviewboard.asterisk.org/r/380/ ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@225489 f38db490-d61c-443f-a65b-d21fe96a405b
2009-10-22Merged revisions 225360 via svnmerge from tilghman1-4/+5
https://origsvn.digium.com/svn/asterisk/trunk ................ r225360 | tilghman | 2009-10-22 12:11:23 -0500 (Thu, 22 Oct 2009) | 11 lines Merged revisions 225105 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r225105 | tilghman | 2009-10-21 11:02:12 -0500 (Wed, 21 Oct 2009) | 4 lines Fix documentation for ast_softhangup() and correct the misuse thereof. (closes issue #16103) Reported by: majorbloodnok ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@225363 f38db490-d61c-443f-a65b-d21fe96a405b