aboutsummaryrefslogtreecommitdiffstats
path: root/main
AgeCommit message (Collapse)AuthorFilesLines
2010-06-10Merge changes in 269637 and update ChangeLog.v1.6.2.9-rc3lmadsen2-0/+5
git-svn-id: http://svn.digium.com/svn/asterisk/tags/1.6.2.9-rc3@269747 f38db490-d61c-443f-a65b-d21fe96a405b
2010-06-09Merge revision 269347. Update ChangeLog and .version files.lmadsen1-6/+16
git-svn-id: http://svn.digium.com/svn/asterisk/tags/1.6.2.9-rc3@269351 f38db490-d61c-443f-a65b-d21fe96a405b
2010-06-07Update ChangeLog and merge revision 268457 from the 1.6.2 branch.v1.6.2.9-rc2lmadsen1-9/+4
git-svn-id: http://svn.digium.com/svn/asterisk/tags/1.6.2.9-rc2@268577 f38db490-d61c-443f-a65b-d21fe96a405b
2010-06-01Merged revisions 266592 via svnmerge from tilghman1-1/+1
https://origsvn.digium.com/svn/asterisk/trunk ................ r266592 | tilghman | 2010-06-01 10:18:59 -0500 (Tue, 01 Jun 2010) | 18 lines Merged revisions 266585 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r266585 | tilghman | 2010-06-01 10:17:46 -0500 (Tue, 01 Jun 2010) | 11 lines Prevent CLI prompt from distorting output of lines shorter than the prompt. Uses the VT100 method of clearing the line from the cursor position to the end of the line: Esc-0K (closes issue #17160) Reported by: coolmig Patches: 20100531__issue17160.diff.txt uploaded by tilghman (license 14) Tested by: coolmig ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@266598 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-28Merged revisions 266337 via svnmerge from tilghman1-2/+5
https://origsvn.digium.com/svn/asterisk/trunk ........ r266337 | tilghman | 2010-05-28 15:53:04 -0500 (Fri, 28 May 2010) | 1 line Only report swap on platforms which can examine those statistics ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@266338 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-26Merged revisions 266146 via svnmerge from tilghman2-21/+43
https://origsvn.digium.com/svn/asterisk/trunk ................ r266146 | tilghman | 2010-05-26 16:17:46 -0500 (Wed, 26 May 2010) | 21 lines Merged revisions 266142 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r266142 | tilghman | 2010-05-26 16:11:44 -0500 (Wed, 26 May 2010) | 14 lines Use sigaction for signals which should persist past the initial trigger, not signal. If you call signal() in a Solaris signal handler, instead of just resetting the signal handler, it causes the signal to refire, because the signal is not marked as handled prior to the signal handler being called. This effectively causes Solaris to immediately exceed the threadstack in recursive signal handlers and crash. (closes issue #17000) Reported by: rmcgilvr Patches: 20100526__issue17000.diff.txt uploaded by tilghman (license 14) Tested by: rmcgilvr ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@266154 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-24Merged revisions 265320,265467 via svnmerge from twilson2-0/+9
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-24Merged revisions 265273 via svnmerge from dvossel1-0/+6
https://origsvn.digium.com/svn/asterisk/trunk ........ r265273 | dvossel | 2010-05-24 11:10:09 -0500 (Mon, 24 May 2010) | 2 lines fixes segfault when using generic plc ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@265364 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-24Merged revisions 265316 via svnmerge from tilghman1-10/+11
https://origsvn.digium.com/svn/asterisk/trunk ........ r265316 | tilghman | 2010-05-24 13:19:08 -0500 (Mon, 24 May 2010) | 7 lines On systems with a LOT of RAM, a signed integer sometimes printed negative. (closes issue #16837) Reported by: jlpedrosa Patches: 20100504__issue16837.diff.txt uploaded by tilghman (license 14) ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@265318 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-21Merged revisions 264997 via svnmerge from mmichelson2-27/+57
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-20Merged revisions 264828 via svnmerge from rmudgett1-0/+2
https://origsvn.digium.com/svn/asterisk/trunk ................ r264828 | rmudgett | 2010-05-20 18:29:43 -0500 (Thu, 20 May 2010) | 13 lines Merged revisions 264820 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r264820 | rmudgett | 2010-05-20 18:23:21 -0500 (Thu, 20 May 2010) | 6 lines ast_callerid_parse() had a path that left name uninitialized. Several callers of ast_callerid_parse() do not initialize the name parameter before calling thus there is the potential to use an uninitialized pointer. ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@264829 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-20Merged revisions 264779 via svnmerge from tilghman1-0/+11
https://origsvn.digium.com/svn/asterisk/trunk ........ r264779 | tilghman | 2010-05-20 17:23:32 -0500 (Thu, 20 May 2010) | 8 lines Let ExtensionState resolve dynamic hints. (closes issue #16623) Reported by: tilghman Patches: 20100116__issue16623.diff.txt uploaded by tilghman (license 14) Tested by: lmadsen ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@264783 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-19Merged revisions 264452 via svnmerge from mmichelson3-4/+110
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 264400 via svnmerge from dvossel1-1/+1
https://origsvn.digium.com/svn/asterisk/trunk ........ r264400 | dvossel | 2010-05-19 15:30:33 -0500 (Wed, 19 May 2010) | 11 lines fixes infinite loop during udptl.c's decode_open_type When decode_length returns the length there is a check to see if that length is negative, if so the decode loop breaks as this means the limit has been reached. The problem here is that length is an unsigned int, so length can never be negative. This resulted in an infinite loop. (issue #17352) ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@264405 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-19Merged revisions 264379 via svnmerge from mnicholson1-1/+1
https://origsvn.digium.com/svn/asterisk/trunk ........ r264379 | mnicholson | 2010-05-19 15:26:27 -0500 (Wed, 19 May 2010) | 4 lines Cast an unsigned int to a signed int when comparing it with 0. (AST-377) ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@264388 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-19Merged revisions 264204 via svnmerge from tilghman1-2/+14
https://origsvn.digium.com/svn/asterisk/trunk ........ r264204 | tilghman | 2010-05-19 11:42:20 -0500 (Wed, 19 May 2010) | 9 lines Keep track of digit duration, when we're decoding inband to pass DTMF frames. (closes issue #17235) Reported by: frawd Patches: new_dtmf_dsp_len.patch uploaded by frawd (license 610) 20100518__issue17235.diff.txt uploaded by tilghman (license 14) Tested by: frawd ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@264205 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-19Merged revisions 264114 via svnmerge from dvossel1-2/+2
https://origsvn.digium.com/svn/asterisk/trunk ........ r264114 | dvossel | 2010-05-19 09:38:02 -0500 (Wed, 19 May 2010) | 13 lines fixes crash during dtmf During the processing of Cisco dtmf the dtmf samples were not being calculated correctly. In an attempt to determine what sample rate was being used, a NULL frame was processed which caused a crash. This patch resolves this. (closes issue #17248) Reported by: falves11 Patches: issue_17248.diff uploaded by dvossel (license 671) ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@264115 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-19Merged revisions 263950 via svnmerge from tilghman1-40/+43
https://origsvn.digium.com/svn/asterisk/trunk ................ r263950 | tilghman | 2010-05-19 01:41:04 -0500 (Wed, 19 May 2010) | 15 lines Merged revisions 263949 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r263949 | tilghman | 2010-05-19 01:32:27 -0500 (Wed, 19 May 2010) | 8 lines Because progress is called multiple times, across several frames, we must persist states when detecting multitone sequences. (closes issue #16749) Reported by: dant Patches: dsp.c-bug16749-1.patch uploaded by dant (license 670) Tested by: dant ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@263951 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-18Merged revisions 263904 via svnmerge from dvossel1-2/+3
https://origsvn.digium.com/svn/asterisk/trunk ........ r263904 | dvossel | 2010-05-18 17:48:51 -0500 (Tue, 18 May 2010) | 9 lines fixes segfault on logging (closes issue #17331) Reported by: under Patches: utils.diff uploaded by under (license 914) segfault_on_logging.diff uploaded by dvossel (license 671) Tested by: under, dvossel ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@263906 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-17Merged revisions 263640 via svnmerge from mmichelson1-1/+3
https://origsvn.digium.com/svn/asterisk/trunk ................ r263640 | mmichelson | 2010-05-17 17:08:01 -0500 (Mon, 17 May 2010) | 16 lines Merged revisions 263639 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r263639 | mmichelson | 2010-05-17 17:00:28 -0500 (Mon, 17 May 2010) | 10 lines Fix logic error when checking for a devstate provider. When using strsep, if one of the list of specified separators is not found, it is the first parameter to strsep which is now NULL, not the pointer returned by strsep. This issue isn't especially severe in that the worst it is likely to do is waste some cycles when a device with no '/' and no ':' is passed to ast_device_state. ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@263642 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-17Don't close 'n', just close 'above_n'.tilghman1-1/+1
(closes issue #17345) Reported by: wdoekes git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@263587 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-17Merged revisions 263457 via svnmerge from lmadsen1-1/+1
https://origsvn.digium.com/svn/asterisk/trunk ................ r263457 | lmadsen | 2010-05-17 09:37:35 -0500 (Mon, 17 May 2010) | 19 lines Recorded merge of revisions 263456 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r263456 | lmadsen | 2010-05-17 09:35:18 -0500 (Mon, 17 May 2010) | 11 lines Manager cookies are not compatible with RFC2109. The Version field in the cookies we're setting contain quotes around the version number which is not compatible with RFC2109 and breaks some implementations. (closes issue #17231) Reported by: ecarruda Patches: manager_rfc2109-trunk-v1.patch uploaded by ecarruda (license 559) manager_rfc2109-1.6.2-v1.patch uploaded by ecarruda (license 559) Tested by: ecarruda, russell ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@263458 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-12Merged revisions 262800 via svnmerge from pabelanger2-1/+4
https://origsvn.digium.com/svn/asterisk/trunk ........ r262800 | pabelanger | 2010-05-12 15:59:16 -0400 (Wed, 12 May 2010) | 8 lines Notify CLI when modules is loaded / unloaded (closes issue #17308) Reported by: pabelanger Patches: cli.modules.patch uploaded by pabelanger (license 224) Tested by: pabelanger, russell ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@262801 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-06Merged revisions 261496 via svnmerge from russell1-10/+14
https://origsvn.digium.com/svn/asterisk/trunk ........ r261496 | russell | 2010-05-06 08:58:07 -0500 (Thu, 06 May 2010) | 40 lines Fix handling of removing nodes from the middle of a heap. This bug surfaced in 1.6.2 and does not affect code in any other released version of Asterisk. It manifested itself as SIP qualify not happening when it should, causing peers to go unreachable. This was debugged down to scheduler entries sometimes not getting executed when they were supposed to, which was in turn caused by an error in the heap code. The problem only sometimes occurs, and it is due to the logic for removing an entry in the heap from an arbitrary location (not just popping off the top). The scheduler performs this operation frequently when entries are removed before they run (when ast_sched_del() is used). In a normal pop off of the top of the heap, a node is taken off the bottom, placed at the top, and then bubbled down until the max heap property is restored (see max_heapify()). This same logic was used for removing an arbitrary node from the middle of the heap. Unfortunately, that logic is full of fail. This patch fixes that by fully restoring the max heap property when a node is thrown into the middle of the heap. Instead of just pushing it down as appropriate, it first pushes it up as high as it will go, and _then_ pushes it down. Lastly, fix a minor problem in ast_heap_verify(), which is only used for debugging. If a parent and child node have the same value, that is not an error. The only error is if a parent's value is less than its children. A huge thanks goes out to cappucinoking for debugging this down to the scheduler, and then producing an ast_heap test case that demonstrated the breakage. That made it very easy for me to focus on the heap logic and produce a fix. Open source projects are awesome. (closes issue #16936) Reported by: ib2 Tested by: cappucinoking, crjw (closes issue #17277) Reported by: cappucinoking Patches: heap-fix.rev2.diff uploaded by russell (license 2) Tested by: cappucinoking, russell ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@261498 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-04Merged revisions 261095 via svnmerge from tilghman1-2/+7
https://origsvn.digium.com/svn/asterisk/trunk ................ r261095 | tilghman | 2010-05-04 18:51:52 -0500 (Tue, 04 May 2010) | 18 lines Merged revisions 261093-261094 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r261093 | tilghman | 2010-05-04 18:36:53 -0500 (Tue, 04 May 2010) | 7 lines Protect against overflow, when calculating how long to wait for a frame. (closes issue #17128) Reported by: under Patches: d.diff uploaded by under (license 914) ........ r261094 | tilghman | 2010-05-04 18:47:08 -0500 (Tue, 04 May 2010) | 2 lines Add a tiny corner case to the previous commit ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@261098 f38db490-d61c-443f-a65b-d21fe96a405b
2010-05-04Merged revisions 254450 via svnmerge from mnicholson1-3/+4
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-30Merged revisions 260292 via svnmerge from tilghman1-0/+4
https://origsvn.digium.com/svn/asterisk/trunk ........ r260292 | tilghman | 2010-04-30 01:19:35 -0500 (Fri, 30 Apr 2010) | 13 lines Don't allow file descriptors to go above 64k, when we're closing them in a fork(2). This saves time, when, even though the system allows the process limit to be that high, the practical limit is much lower. (closes issue #17223) Reported by: dbackeberg Patches: 20100423__issue17223.diff.txt uploaded by tilghman (license 14) Tested by: dbackeberg ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@260303 f38db490-d61c-443f-a65b-d21fe96a405b
2010-04-29Merged revisions 260050 via svnmerge from dvossel1-11/+34
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-28Merged revisions 259870 via svnmerge from dvossel1-5/+2
https://origsvn.digium.com/svn/asterisk/trunk ................ r259870 | dvossel | 2010-04-28 16:20:03 -0500 (Wed, 28 Apr 2010) | 39 lines Merged revisions 259858 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r259858 | dvossel | 2010-04-28 16:16:03 -0500 (Wed, 28 Apr 2010) | 33 lines resolves deadlocks in chan_local Issue_1. In the local_hangup() 3 locks must be held at the same time... pvt, pvt->chan, and pvt->owner. Proper deadlock avoidance is done when the channel to hangup is the outbound chan_local channel, but when it is not the outbound channel we have an issue... We attempt to do deadlock avoidance only on the tech pvt, when both the tech pvt and the pvt->owner are locked coming into that loop. By never giving up the pvt->owner channel deadlock avoidance is not entirely possible. This patch resolves that by doing deadlock avoidance on both the pvt->owner and the pvt when trying to get the pvt->chan lock. Issue_2. ast_prod() is used in ast_activate_generator() to queue a frame on the channel and make the channel's read function get called. This function is used in ast_activate_generator() while the channel is locked, which mean's the channel will have a lock both from the generator code and the frame_queue code by the time it gets to chan_local.c's local_queue_frame code... local_queue_frame contains some of the same crazy deadlock avoidance that local_hangup requires, and this recursive lock prevents that deadlock avoidance from happening correctly. This patch removes ast_prod() from the channel lock so only one lock is held during the local_queue_frame function. (closes issue #17185) Reported by: schmoozecom Patches: issue_17185_v1.diff uploaded by dvossel (license 671) issue_17185_v2.diff uploaded by dvossel (license 671) Tested by: schmoozecom, GameGamer43 Review: https://reviewboard.asterisk.org/r/631/ ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@259899 f38db490-d61c-443f-a65b-d21fe96a405b
2010-04-27Merged revisions 259439 via svnmerge from qwell3-54/+59
https://origsvn.digium.com/svn/asterisk/trunk ........ r259439 | qwell | 2010-04-27 16:13:01 -0500 (Tue, 27 Apr 2010) | 5 lines Add gar to the check for AR for those silly OSes (Solaris) that don't have ar. autoconf2.13 couldn't handle AC_PROG_GREP, so I removed it. This is fine, since we don't need to use anything that the configure script doesn't. ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@259486 f38db490-d61c-443f-a65b-d21fe96a405b
2010-04-26Merged revisions 259105 via svnmerge from mmichelson1-1/+1
https://origsvn.digium.com/svn/asterisk/trunk ................ r259105 | mmichelson | 2010-04-26 16:45:13 -0500 (Mon, 26 Apr 2010) | 9 lines Merged revisions 259104 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r259104 | mmichelson | 2010-04-26 16:44:43 -0500 (Mon, 26 Apr 2010) | 3 lines Let compilation succeed warning-free when DONT_OPTIMIZE is turned off. ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@259109 f38db490-d61c-443f-a65b-d21fe96a405b
2010-04-26Merged revisions 259023 via svnmerge from mmichelson1-1/+7
https://origsvn.digium.com/svn/asterisk/trunk ................ r259023 | mmichelson | 2010-04-26 16:13:35 -0500 (Mon, 26 Apr 2010) | 19 lines Merged revisions 259018 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r259018 | mmichelson | 2010-04-26 16:03:08 -0500 (Mon, 26 Apr 2010) | 13 lines Prevent Newchannel manager events for dummy channels. No Newchannel manager event will be fired for channels that are allocated to not match a registered technology type. Thus bogus channels allocated solely for variable substitution or CDR operations do not result in a Newchannel event. (closes issue #16957) Reported by: atis Review: https://reviewboard.asterisk.org/r/601 ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@259103 f38db490-d61c-443f-a65b-d21fe96a405b
2010-04-22Merged revisions 258671,258675 via svnmerge from mnicholson3-7/+19
https://origsvn.digium.com/svn/asterisk/trunk ................ r258671 | mnicholson | 2010-04-22 16:57:59 -0500 (Thu, 22 Apr 2010) | 32 lines Merged revisions 193391,258670 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r193391 | mnicholson | 2009-05-08 16:01:25 -0500 (Fri, 08 May 2009) | 8 lines Set the proper disposition on originated calls. (closes issue #14167) Reported by: jpt Patches: call-file-missing-cdr2.diff uploaded by mnicholson (license 96) Tested by: dlotina, rmartinez, mnicholson ........ r258670 | mnicholson | 2010-04-22 16:49:07 -0500 (Thu, 22 Apr 2010) | 11 lines Fix broken CDR behavior. This change allows a CDR record previously marked with disposition ANSWERED to be set as BUSY or NO ANSWER. Additionally this change partially reverts r235635 and does not set the AST_CDR_FLAG_ORIGINATED flag on CDRs generated from ast_call(). To preserve proper CDR behavior, the AST_CDR_FLAG_DIALED flag is now cleared from all brige CDRs in ast_bridge_call(). (closes issue #16797) Reported by: VarnishedOtter Tested by: mnicholson ........ (closes issue #16222) Reported by: telles Tested by: mnicholson ................ r258675 | mnicholson | 2010-04-22 17:11:23 -0500 (Thu, 22 Apr 2010) | 2 lines Fix previous commit. ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@258676 f38db490-d61c-443f-a65b-d21fe96a405b
2010-04-22Merged revisions 258632 via svnmerge from russell1-55/+94
https://origsvn.digium.com/svn/asterisk/trunk For 1.6.2, only merge the bug fixes, not the unit test. ........ r258632 | russell | 2010-04-22 16:06:53 -0500 (Thu, 22 Apr 2010) | 22 lines Add ast_event subscription unit test and fix some ast_event API bugs. This patch introduces another test in test_event.c that exercises most of the subscription related ast_event API calls. I made some minor additions to the existing event allocation test to increase API coverage by the test code. Finally, I made a list in a comment of API calls not yet touched by the test module as a to-do list for future test development. During the development of this test code, I discovered a number of bugs in the event API. 1) subscriptions to AST_EVENT_ALL were not handled appropriately in a couple of different places. The API allows a subscription to all event types, but with IE parameters, just as if it was a subscription to a specific event type. However, the parameters were being ignored. This affected ast_event_check_subscriber() and event distribution to subscribers. 2) Some of the logic in ast_event_check_subscriber() for checking subscriptions against query parameters was wrong. Review: https://reviewboard.asterisk.org/r/617/ ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@258672 f38db490-d61c-443f-a65b-d21fe96a405b
2010-04-19Merged revisions 257949 via svnmerge from qwell1-1/+1
https://origsvn.digium.com/svn/asterisk/trunk ........ r257949 | qwell | 2010-04-19 16:57:56 -0500 (Mon, 19 Apr 2010) | 1 line Change log message to match severity. ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@257950 f38db490-d61c-443f-a65b-d21fe96a405b
2010-04-19Merged revisions 257947 via svnmerge from qwell1-1/+1
https://origsvn.digium.com/svn/asterisk/trunk ........ r257947 | qwell | 2010-04-19 16:49:30 -0500 (Mon, 19 Apr 2010) | 6 lines Don't consider a missing indications.conf to be a critical error. There were many changes in revision 176627 which would avoid the error that a missing config would have caused. Other than this, there are no other config files (including asterisk.conf, surprisingly) that are required. ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@257948 f38db490-d61c-443f-a65b-d21fe96a405b
2010-04-19Merged revisions 257810 via svnmerge from twilson1-6/+10
https://origsvn.digium.com/svn/asterisk/trunk ........ r257810 | twilson | 2010-04-19 12:57:41 -0500 (Mon, 19 Apr 2010) | 5 lines Fix incomplete CDR merge from r195881 Because res/res_features.c was removed and main/cdr.c added, these changes didn't make it to trunk and the 1.6.x branches ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@257850 f38db490-d61c-443f-a65b-d21fe96a405b
2010-04-15Merged revisions 257560 via svnmerge from tilghman1-40/+50
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-14Merged revisions 257262 via svnmerge from tilghman1-29/+40
https://origsvn.digium.com/svn/asterisk/trunk ........ r257262 | tilghman | 2010-04-14 17:57:35 -0500 (Wed, 14 Apr 2010) | 15 lines Yet another issue where the conversion of the application delimiter to comma caused an issue. Application arguments within the feature map could possibly contain a comma, which conflicts with the syntax of the features.conf configuration file. This patch allows the argument to be wrapped in parentheses or quoted, to allow the application arguments to be interpreted as a single configuration parameter. (closes issue #16646) Reported by: pinga-fogo Patches: 20100414__issue16646.diff.txt uploaded by tilghman (license 14) Tested by: tilghman Review: https://reviewboard.asterisk.org/r/547/ ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@257265 f38db490-d61c-443f-a65b-d21fe96a405b
2010-04-13Merged revisions 257146 via svnmerge from mnicholson1-1/+26
https://origsvn.digium.com/svn/asterisk/trunk ................ r257146 | mnicholson | 2010-04-13 13:10:30 -0500 (Tue, 13 Apr 2010) | 16 lines Merged revisions 257070 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r257070 | mnicholson | 2010-04-13 11:46:30 -0500 (Tue, 13 Apr 2010) | 9 lines Add an option to restore past broken behavor of the Events manager action Before r238915, certain values for the EventMask parameter of the Events action would result in no response being returned. This patch adds an option to restore that broken behavior. Also while fixing this bug I discovered that passing an empty EventMasks parameter would also result in no response being returned, this has been fixed as well while being preserved when the broken behavior is requested. (closes issue #17023) Reported by: nblasgen Review: https://reviewboard.asterisk.org/r/602/ ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@257184 f38db490-d61c-443f-a65b-d21fe96a405b
2010-04-12Merged revisions 256821 via svnmerge from lmadsen1-2/+2
https://origsvn.digium.com/svn/asterisk/trunk ........ r256821 | lmadsen | 2010-04-12 09:39:37 -0500 (Mon, 12 Apr 2010) | 8 lines CLI command logger set level auto complete. A simple patch to enable auto tab complete. (closes issue #17152) Reported by: pabelanger Patches: 0017152.patch uploaded by pabelanger (license 224) ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@256822 f38db490-d61c-443f-a65b-d21fe96a405b
2010-04-08Backport /proc/%d/fd method of closing file descriptors to 1.6.2.tilghman1-13/+34
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@256483 f38db490-d61c-443f-a65b-d21fe96a405b
2010-04-02Merged revisions 256010 via svnmerge from russell1-3/+1
https://origsvn.digium.com/svn/asterisk/trunk ................ r256010 | russell | 2010-04-02 18:30:58 -0500 (Fri, 02 Apr 2010) | 9 lines Merged revisions 256009 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r256009 | russell | 2010-04-02 18:30:15 -0500 (Fri, 02 Apr 2010) | 2 lines Remove extremely verbose debug message. ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@256013 f38db490-d61c-443f-a65b-d21fe96a405b
2010-04-02Merged revisions 255952 via svnmerge from tilghman1-1/+1
https://origsvn.digium.com/svn/asterisk/trunk ........ r255952 | tilghman | 2010-04-02 15:19:01 -0500 (Fri, 02 Apr 2010) | 8 lines Pass the PID of the Asterisk process, not the PID of the canary. (closes issue #17065) Reported by: globalnetinc Patches: astcanary.patch uploaded by makoto (license 38) Tested by: frawd, globalnetinc ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@255955 f38db490-d61c-443f-a65b-d21fe96a405b
2010-03-25Fix DEBUG_THREADS issue with out-of-tree modules.qwell1-9/+48
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 254453 via svnmerge from twilson1-0/+1
https://origsvn.digium.com/svn/asterisk/trunk ................ r254453 | twilson | 2010-03-25 11:03:51 -0500 (Thu, 25 Mar 2010) | 9 lines Merged revisions 254451 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r254451 | twilson | 2010-03-25 10:57:29 -0500 (Thu, 25 Mar 2010) | 2 lines Handle new SRCCHANGE control message here too ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@254499 f38db490-d61c-443f-a65b-d21fe96a405b
2010-03-25Recorded merge of revisions 254454 via svnmerge from mmichelson1-14/+37
https://origsvn.digium.com/svn/asterisk/trunk ................ r254454 | mmichelson | 2010-03-25 11:04:48 -0500 (Thu, 25 Mar 2010) | 50 lines Recorded merge of revisions 254452 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r254452 | mmichelson | 2010-03-25 10:59:56 -0500 (Thu, 25 Mar 2010) | 44 lines Several fixes regarding RFC2833 DTMF detection. Here is a copy and paste of the details from my request on reviewboard that dealt with these changes: Fix 1. The first change in place is to fix Mantis issue 15811, which deals with a situation where Asterisk will incorrectly interpret out of order RFC2833 frames as duplicate DTMF digits. For instance, we would receive a sequence like: seqno 1: DTMF 1 seqno 2: DTMF 1 seqno 3: DTMF 1 seqno 4: DTMF 1 seqno 6: DTMF 1 (end) seqno 5: DTMF 1 seqno 7: DTMF 1 (end) seqno 8: DTMF 1 (end) Prior to this patch when we received the frame with seqno 5, we would interpret this as a new DTMF 1. With this patch, we will check the seqno of the incoming digit and not process the frame if the seqno is lower than the last recorded seqno. Note that we do not record the seqno of the dropped DTMF frame for future processing. While the above situation is what was designed to be fixed, the patch is written in such a way that the following would also be fixed too: seqno 9: DTMF 1 seqno 10: DTMF 1 (end) seqno 11: DTMF 1 (end) seqno 13: DTMF 2 seqno 12: DTMF 1 (end) seqno 14: DTMF 2 seqno 15: DTMF 2 (end) seqno 16: DTMF 2 (end) seqno 17: DTMF 2 (end) In this second situation, the beginning of the DTMF 2 arrives before the final end frame of the DTMF 1. With the patch, seqno 12 is no processed and thus we properly interpret the DTMF. Fix 2. The second change in place is to fix an issue like the following: seqno 1: DTMF 1 seqno 2: DTMF 1 seqno 3: DTMF 1 (end) *packet lost* seqno 4: DTMF 1 (end) *packet lost* seqno 5: DTMF 1 (end) *packet lost* seqno 6: DTMF 2 When we receive seqno 6, we had code in place that was supposed to properly end the previously unended DTMF 1. The problem was that the code was essentially a no-op. The code would set up an end frame for the DTMF 1 but would immediately overwrite the frame with the begin for DTMF 2. I changed process_dtmf_rfc2833() so that instead of returning a single frame, it is given as an output parameter a list of frames. Each frame that needs to be returned is appended to this list. Fix 3. The final change is a minor one where an AST_CONTROL_SRCCHANGE frame could get lost. If we process a cisco DTMF or an RFC 3389 frame and no frame was returned, then we would return &ast_null_frame. The problem is that earlier in the function, we may have generated an AST_CONTROL_SRCCHANGE frame and put it in the list of frames we wish to return. This frame would be lost in such a case. The patch fixes this problem ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@254482 f38db490-d61c-443f-a65b-d21fe96a405b
2010-03-23Merged revisions 254050 via svnmerge from jpeeler1-2/+5
https://origsvn.digium.com/svn/asterisk/trunk ........ r254050 | jpeeler | 2010-03-23 16:17:23 -0500 (Tue, 23 Mar 2010) | 14 lines Exit native bridging early for greater timing accuracy with warnings This changes native bridging to break one millisecond early so that the more accurate timeval calculations done in the generic bridge can be performed using the bridge config. Currently the time between exiting native bridging slightly late can sometimes cause a large enough discrepancy for warnings to be missed. For the record, 1.4 does not attempt to native bridge at all when warnings are enabled. (closes issue #15815) Reported by: adomjan Review: https://reviewboard.asterisk.org/r/577/ ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@254068 f38db490-d61c-443f-a65b-d21fe96a405b
2010-03-22Merged revisions 253800 via svnmerge from mnicholson1-3/+1
https://origsvn.digium.com/svn/asterisk/trunk ................ r253800 | mnicholson | 2010-03-22 14:52:52 -0500 (Mon, 22 Mar 2010) | 11 lines Merged revisions 253799 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r253799 | mnicholson | 2010-03-22 14:50:00 -0500 (Mon, 22 Mar 2010) | 4 lines Unconditionally copy the caller's account code to the called party. (related to issue #16331) ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@253801 f38db490-d61c-443f-a65b-d21fe96a405b
2010-03-20Merged revisions 253540 via svnmerge from russell3-0/+3
https://origsvn.digium.com/svn/asterisk/trunk ........ r253540 | russell | 2010-03-20 07:03:07 -0500 (Sat, 20 Mar 2010) | 2 lines Resolve more compiler warnings on FreeBSD. ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@253620 f38db490-d61c-443f-a65b-d21fe96a405b