aboutsummaryrefslogtreecommitdiffstats
path: root/main
AgeCommit message (Collapse)AuthorFilesLines
2009-09-03Merge code associated with AST-2009-006dvossel2-13/+18
(closes issue #12912) Reported by: rathaus Tested by: tilghman, russell, dvossel, dbrooks git-svn-id: http://svn.digium.com/svn/asterisk/tags/1.4.26.2@216015 f38db490-d61c-443f-a65b-d21fe96a405b
2009-08-10Changes to make 1.4.26 into 1.4.26.1v1.4.26.1tilghman11-47/+47
git-svn-id: http://svn.digium.com/svn/asterisk/tags/1.4.26.1@211596 f38db490-d61c-443f-a65b-d21fe96a405b
2009-07-13Print CID match in "show dialplan".russell1-1/+4
(closes issue #14702) Reported by: klaus3000 Patches: patch_asterisk_1.4.23_CID_matching.txt uploaded by klaus3000 (license 65) git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@206126 f38db490-d61c-443f-a65b-d21fe96a405b
2009-07-08Fixes 8khz assumptionsdvossel1-21/+24
Many calculations assume 8khz is the codec rate. This is not always the case. This patch only addresses chan_iax.c and res_rtp_asterisk.c, but I am sure there are other areas that make this assumption as well. Review: https://reviewboard.asterisk.org/r/306/ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@205471 f38db490-d61c-443f-a65b-d21fe96a405b
2009-07-08moving ast_devstate_to_extenstate to pbx.c from devicestate.cdvossel2-25/+26
ast_devstate_to_extenstate belongs in pbx.c. This change fixes a compile time error with chan_vpb as well. git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@205409 f38db490-d61c-443f-a65b-d21fe96a405b
2009-07-08Add redirection warnings for the invalid language codes previously removed.tilghman1-0/+72
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@205188 f38db490-d61c-443f-a65b-d21fe96a405b
2009-07-02moving device state functions from pbx.h to devicestate.h to sync with other ↵dvossel2-113/+113
branches git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@204755 f38db490-d61c-443f-a65b-d21fe96a405b
2009-07-02Improved mapping of extension states from combined device states.dvossel2-73/+160
This fixes a few issues with incorrect extension states and adds a cli command, core show device2extenstate, to display all possible state mappings. (closes issue #15413) Reported by: legart Patches: exten_helper.diff uploaded by dvossel (license 671) Tested by: dvossel, legart, amilcar Review: https://reviewboard.asterisk.org/r/301/ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@204681 f38db490-d61c-443f-a65b-d21fe96a405b
2009-06-30More incorrect language codes, plus ensuring that regionalizations use the ↵tilghman1-188/+188
specified language, and not English for grammar. (closes issue #15022) Reported by: greenfieldtech Patches: 20090519__issue15022.diff.txt uploaded by tilghman (license 14) git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@204556 f38db490-d61c-443f-a65b-d21fe96a405b
2009-06-30Fix ast_say_counted_noun to correctly handle Polish. Fix a comment typo in ↵qwell1-2/+2
passing. git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@204474 f38db490-d61c-443f-a65b-d21fe96a405b
2009-06-30"tw" is the language specification for Twi (from Ghana) not Taiwanese.tilghman1-37/+34
(closes issue #15346) Reported by: volivier Patches: 20090617__issue15346__1.4.diff.txt uploaded by tilghman (license 14) 20090617__issue15346__trunk.diff.txt uploaded by tilghman (license 14) 20090617__issue15346__1.6.0.diff.txt uploaded by tilghman (license 14) 20090617__issue15346__1.6.1.diff.txt uploaded by tilghman (license 14) 20090617__issue15346__1.6.2.diff.txt uploaded by tilghman (license 14) Tested by: volivier git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@204469 f38db490-d61c-443f-a65b-d21fe96a405b
2009-06-26Don't fast forward past the end of a message.russell1-0/+7
This is nice change for users of the voicemail application. If someone gets a little carried away with fast forwarding through a message, they can easily get to the end and accidentally exit the voicemail application by hitting the fast forward key during the following prompt. This adds some safety by not allowing a fast forward past the end of a message. (closes issue #14554) Reported by: lacoursj Patches: 21761.patch uploaded by lacoursj (license 707) Tested by: lacoursj git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@203785 f38db490-d61c-443f-a65b-d21fe96a405b
2009-06-25I didn't see that Mark already fixed the underlying issue!twilson1-3/+2
Yay for removing useless code. git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@203380 f38db490-d61c-443f-a65b-d21fe96a405b
2009-06-25Don't try to free NULLtwilson1-1/+3
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@203311 f38db490-d61c-443f-a65b-d21fe96a405b
2009-06-25Prevent false positives when freeing a NULL pointer with MALLOC_DEBUG enabled.mmichelson1-1/+7
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@203230 f38db490-d61c-443f-a65b-d21fe96a405b
2009-06-22Report CallerID change during a masquerade.russell1-15/+25
Reported by: markster git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@202496 f38db490-d61c-443f-a65b-d21fe96a405b
2009-06-17Change the datastore traversal in ast_do_masquerade to use a safe list ↵mmichelson1-1/+5
traversal. It is possible for datastore fixup functions to remove the datastore from the list and free it. In particular, the queue_transfer_fixup in app_queue does this. While I don't yet know of this causing any crashes, it certainly could. Found while discussing a separate issue with Brian Degenhardt. git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@201450 f38db490-d61c-443f-a65b-d21fe96a405b
2009-06-16Improve support for media paths that can generate multiple frames at once.kpfleming5-169/+254
There are various media paths in Asterisk (codec translators and UDPTL, primarily) that can generate more than one frame to be generated when the application calling them expects only a single frame. This patch addresses a number of those cases, at least the primary ones to solve the known problems. In addition it removes the broken TRACE_FRAMES support, fixes a number of bugs in various frame-related API functions, and cleans up various code paths affected by these changes. https://reviewboard.asterisk.org/r/175/ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@200991 f38db490-d61c-443f-a65b-d21fe96a405b
2009-06-12Suppress a warning message and give a better return code when generatingmmichelson1-0/+10
inband ringing after a call is answered. (closes issue #15158) Reported by: madkins Patches: 15158.patch uploaded by mmichelson (license 60) Tested by: madkins git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@200360 f38db490-d61c-443f-a65b-d21fe96a405b
2009-06-05Fixes issue with hints giving unexpected results.dvossel1-19/+12
Hints with two or more devices that include ONHOLD gave unexpected results. (closes issue #15057) Reported by: p_lindheimer Patches: onhold_trunk.diff uploaded by dvossel (license 671) pbx.c.1.4.patch uploaded by p (license 558) devicestate.c.trunk.patch uploaded by p (license 671) Tested by: p_lindheimer, dvossel Review: https://reviewboard.asterisk.org/r/254/ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@199297 f38db490-d61c-443f-a65b-d21fe96a405b
2009-06-04Safely handle AMI connections/reload requests that occur during startup.seanbright2-9/+89
During asterisk startup, a lock on the list of modules is obtained by the primary thread while each module is initialized. Issue 13778 pointed out a problem with this approach, however. Because the AMI is loaded before other modules, it is possible for a module reload to be issued by a connected client (via Action: Command), causing a deadlock. The resolution for 13778 was to move initialization of the manager to happen after the other modules had already been lodaded. While this fixed this particular issue, it caused a problem for users (like FreePBX) who call AMI scripts via an #exec in a configuration file (See issue 15189). The solution I have come up with is to defer any reload requests that come in until after the server is fully booted. When a call comes in to ast_module_reload (from wherever) before we are fully booted, the request is added to a queue of pending requests. Once we are done booting up, we then execute these deferred requests in turn. Note that I have tried to make this a bit more intelligent in that it will not queue up more than 1 request for the same module to be reloaded, and if a general reload request comes in ('module reload') the queue is flushed and we only issue a single deferred reload for the entire system. As for how this will impact existing installations - Before 13778, a reload issued before module initialization was completed would result in a deadlock. After 13778, you simply couldn't connect to the manager during startup (which causes problems with #exec-that-calls-AMI configuration files). I believe this is a good general purpose solution that won't negatively impact existing installations. (closes issue #15189) (closes issue #13778) Reported by: p_lindheimer Patches: 06032009_15189_deferred_reloads.diff uploaded by seanbright (license 71) Tested by: p_lindheimer, seanbright Review: https://reviewboard.asterisk.org/r/272/ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@199022 f38db490-d61c-443f-a65b-d21fe96a405b
2009-06-03Generic call forward api, ast_call_forward()dvossel1-5/+88
The function ast_call_forward() forwards a call to an extension specified in an ast_channel's call_forward string. After an ast_channel is called, if the channel's call_forward string is set this function can be used to forward the call to a new channel and terminate the original one. I have included this api call in both channel.c's ast_request_and_dial() and res_feature.c's feature_request_and_dial(). App_dial and app_queue already contain call forward logic specific for their application and options. (closes issue #13630) Reported by: festr Review: https://reviewboard.asterisk.org/r/271/ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@198891 f38db490-d61c-443f-a65b-d21fe96a405b
2009-05-29Use AST_CDR_NOANSWER instead of AST_CDR_NULL as the default CDR disposition.mnicholson2-2/+11
This change also involves the addition of an AST_CDR_FLAG_ORIGINATED flag that is used on originated channels to distinguish: them from dialed channels. (closes issue #12946) Reported by: meral Patches: null-cdr2.diff uploaded by mnicholson (license 96) Tested by: mnicholson, dbrooks (closes issue #15122) Reported by: sum Tested by: sum git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@198068 f38db490-d61c-443f-a65b-d21fe96a405b
2009-05-28Allow for media to arrive from an alternate source when responding to a ↵mmichelson1-5/+21
reinvite with 491. When we receive a SIP reinvite, it is possible that we may not be able to process the reinvite immediately since we have also sent a reinvite out ourselves. The problem is that whoever sent us the reinvite may have also sent a reinvite out to another party, and that reinvite may have succeeded. As a result, even though we are not going to accept the reinvite we just received, it is important for us to not have problems if we suddenly start receiving RTP from a new source. The fix for this is to grab the media source information from the SDP of the reinvite that we receive. This information is passed to the RTP layer so that it will know about the alternate source for media. Review: https://reviewboard.asterisk.org/r/252 git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@197588 f38db490-d61c-443f-a65b-d21fe96a405b
2009-05-28Add flags to chanspy audiohook so that audio stays in sync.mmichelson1-1/+11
There are two flags being added to the chanspy audiohook here. One is the pre-existing AST_AUDIOHOOK_TRIGGER_SYNC flag. With this set, we ensure that the read and write slinfactories on the audiohook do not skew beyond a certain tolerance. In addition, there is a new audiohook flag added here, AST_AUDIOHOOK_SMALL_QUEUE. With this flag set, we do not allow for a slinfactory to build up a substantial amount of audio before flushing it. For this particular issue, this means that the person spying on the call will hear the conversations in real time with very little delay in the audio. (closes issue #13745) Reported by: geoffs Patches: 13745.patch uploaded by mmichelson (license 60) Tested by: snblitz git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@197537 f38db490-d61c-443f-a65b-d21fe96a405b
2009-05-27Fix broken attended transfersjpeeler1-5/+6
The bridge was terminating immediately after the attended transfer was completed. The problem was because upon reentering ast_channel_bridge nexteventts was checked to see if it was set and if so could possibly return AST_BRIDGE_COMPLETE. (closes issue #15183) Reported by: andrebarbosa Tested by: andrebarbosa, tootai, loloski git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@197124 f38db490-d61c-443f-a65b-d21fe96a405b
2009-05-21This commit prevents cdr records with AST_CDR_FLAG_ANSLOCKED and ↵mnicholson1-0/+24
AST_CDR_FLAG_LOCKED from being updated in certain cases. This is accomplished by adding two functions to update the answer time and disposition of calls that checks for the proper lock flags. These functions are used in the ast_bridge_call() function so that ForkCDR(A) calls are respected. This patch also modifies the way ast_bridge_call() chooses the cdr record to base the bridged_cdr on. Previously the first unlocked cdr record would be chosen, now instead the first cdr record is chosen and forked cdr records are moved to the bridge_cdr. This allows the original cdr record and any forked cdr records to be properly updated with answer and end times. (closes issue #13797) Reported by: sh0t Tested by: sh0t (closes issue #14744) Reported by: deepesh git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@195881 f38db490-d61c-443f-a65b-d21fe96a405b
2009-05-18Fix a typo which caused loss of audio when using G729 in some scenarios with ↵file1-1/+1
a smoother present. (closes issue #15105) Reported by: bamby Patches: process-vad-correctly.diff uploaded by bamby (license 430) git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@195206 f38db490-d61c-443f-a65b-d21fe96a405b
2009-05-18Fix a bug where the codecs of the called party leg were not properly sent ↵file1-1/+2
back to the caller call leg when reinvited. (closes issue #13569) Reported by: bkw918 git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@195095 f38db490-d61c-443f-a65b-d21fe96a405b
2009-05-18Don't try to unlock a bogus channel.russell1-0/+1
(closes issue #15144) Reported by: cristiandimache git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@195020 f38db490-d61c-443f-a65b-d21fe96a405b
2009-05-13Remove an extraneous unlocking operation from ast_channel_free.mmichelson1-1/+0
In the case that we could not remove the desired channel from the list of channels, there was an extra call to unlock the channel list. Since we unlock the list later on in the function anyway, this results in the list being unlocked twice yet only being locked once. (closes issue #15098) Reported by: tim_ringenbach Patches: remove_extra_unlock.diff uploaded by tim (license 540) git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@194356 f38db490-d61c-443f-a65b-d21fe96a405b
2009-05-13Pull in a piece of murf's 88166 patch that makes it safe to call dbailey1-7/+8
pbx_substitute_variables_helper_full with a non-zero'd buffer git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@194322 f38db490-d61c-443f-a65b-d21fe96a405b
2009-05-13Fix RFC2833 issues with DTMF getting duplicated and with duration wrapping over.file1-23/+58
(closes issue #14815) Reported by: geoff2010 Patches: v1-14815.patch uploaded by dimas (license 88) Tested by: geoff2010, file, dimas, ZX81, moliveras (closes issue #14460) Reported by: moliveras Tested by: moliveras git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@194208 f38db490-d61c-443f-a65b-d21fe96a405b
2009-05-13Fix logic for how to proceed with a single digit extension.tilghman1-1/+1
(closes issue #15091) Reported by: andrew Patches: 20090512__issue15091.diff.txt uploaded by tilghman (license 14) Tested by: andrew git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@194137 f38db490-d61c-443f-a65b-d21fe96a405b
2009-05-08Set the proper disposition on originated calls.mnicholson1-0/+11
(closes issue #14167) Reported by: jpt Patches: call-file-missing-cdr2.diff uploaded by mnicholson (license 96) Tested by: dlotina, rmartinez, mnicholson git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@193391 f38db490-d61c-443f-a65b-d21fe96a405b
2009-05-08Make absolute paths for logger channels work properlykpfleming1-11/+5
(Note: This is not a new feature, it was previously undocumented and broken.) The Asterisk logger has a feature to support absolute pathnames for logger channels, but the code implementing the feature was broken. This has been fixed, and the absolute path feature is now documented in the sample logger.conf. git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@193193 f38db490-d61c-443f-a65b-d21fe96a405b
2009-05-07Fix Background within a Macro for FreePBX.tilghman1-2/+17
If the single digit DTMF is an extension in the specified context, then go there and signal no DTMF. Otherwise, we should exit with that DTMF. If we're in Macro, we'll exit and seek that DTMF as the beginning of an extension in the Macro's calling context. If we're not in Macro, then we'll simply seek that extension in the calling context. Previously, someone complained about the behavior as it related to the interior of a Gosub routine, and the fix (#14011) inadvertently broke FreePBX (#14940). This change should fix both of these situations, but with the possible incompatibility that if a single digit extension does not exist (but a longer extension COULD have matched), it would have previously gone immediately to the "i" extension, but will now need to wait for a timeout. (closes issue #14940) Reported by: p_lindheimer Patches: 20090420__bug14940.diff.txt uploaded by tilghman (license 14) Tested by: p_lindheimer git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@193119 f38db490-d61c-443f-a65b-d21fe96a405b
2009-05-01Fix DTMF not being sent to other side after a partial feature matchjpeeler1-1/+20
This fixes a regression from commit 176701. The issue was that ast_generic_bridge never exited after the feature digit timeout had elapsed, which prevented the queued DTMF from being sent to the other side. This issue was reported to me directly. git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@191488 f38db490-d61c-443f-a65b-d21fe96a405b
2009-04-21Add check in configure script to check for GLOB_NOMAGIC and GLOB_BRACE in ↵dbailey1-8/+1
glob.h This allows config.c to compile when linked against uclibc that does not support these parameters git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@189601 f38db490-d61c-443f-a65b-d21fe96a405b
2009-04-20Clean up problem with manager implementation of mmap where it was not ↵dbailey2-12/+14
testing against MAP_FAILED response. Got rid of shadowed variable used in processign the mmap results. Change test of mmap results to compare against MAP_FAILED git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@189391 f38db490-d61c-443f-a65b-d21fe96a405b
2009-04-20Move the check for chan->fdno == -1 to after the zombie/hangup check.mmichelson1-7/+7
Many users were finding that their hung up channels were staying up and causing 100% CPU usage. (issue #14723) Reported by: seadweller Patches: 14723_1-4-tip.patch uploaded by mmichelson (license 60) Tested by: falves11, bamby git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@189277 f38db490-d61c-443f-a65b-d21fe96a405b
2009-04-17Make Busy() application set the CDR disposition to BUSY.mnicholson1-1/+3
(closes issue #14306) Reported by: cristiandimache git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@189009 f38db490-d61c-443f-a65b-d21fe96a405b
2009-04-15Update ast_readvideo_callback to match ast_readaudio_callback.mmichelson1-2/+11
This fixes potential refcount errors that may occur on ast_filestreams. AST-208 git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@188582 f38db490-d61c-443f-a65b-d21fe96a405b
2009-04-14audio_audiohook_write_list() does not correctly update sample size after ↵dvossel1-0/+1
ast_translate. audio_audiohook_write_list() does not take into account that the sample size may change after translation depending on if the original frame is is 8khz or 16khz. While no 16kz codecs are supported in 1.4 at the moment, this will save headaches in the future if they ever are. the sample size is now updated after translating to reflect this possibility. Thanks to jcolp and mmichelson for helping me work this out. (issue AST-197) git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@188287 f38db490-d61c-443f-a65b-d21fe96a405b
2009-04-09Race condition between ast_cli_command() and 'module unload' could cause a ↵tilghman1-3/+14
deadlock. Add lock timeouts to avoid this potential deadlock. (closes issue #14705) Reported by: jamessan Patches: 20090320__bug14705.diff.txt uploaded by tilghman (license 14) Tested by: jamessan git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@187428 f38db490-d61c-443f-a65b-d21fe96a405b
2009-04-09Oops, missed this file in the last commit.tilghman1-0/+266
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@187301 f38db490-d61c-443f-a65b-d21fe96a405b
2009-04-09Add debugging mode for diagnosing file descriptor leaks.tilghman3-4/+8
(Related to issue #14625) git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@187300 f38db490-d61c-443f-a65b-d21fe96a405b
2009-04-08Backport resolution for file descriptor leak in 1.6.0 to 1.4.tilghman1-105/+187
This fixes short reads in http manager sessions, such as those done by the ast-gui branch. (Fixes AST-198) git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@187209 f38db490-d61c-443f-a65b-d21fe96a405b
2009-04-08Make a couple of changes with regards to a new message printed in ast_read().mmichelson1-6/+12
"ast_read() called with no recorded file descriptor" is a new message added after a bug was discovered. Unfortunately, it seems there are a bunch of places that potentially make such calls to ast_read() and trigger this error message to be displayed. This commit does two things to help to make this message appear less. First, the message has been downgraded to a debug level message if dev mode is not enabled. The message means a lot more to developers than it does to end users, and so developers should take an effort to be sure to call ast_read only when a channel is ready to be read from. However, since this doesn't actually cause an error in operation and is not something a user can easily fix, we should not spam their console with these messages. Second, the message has been moved to after the check for any pending masquerades. ast_read() being called with no recorded file descriptor should not interfere with a masquerade taking place. This could be seen as a simple way of resolving issue #14723. However, I still want to try to clear out the existing ways of triggering this message, since I feel that would be a better resolution for the issue. git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@186984 f38db490-d61c-443f-a65b-d21fe96a405b
2009-04-07Set the AST_FEATURE_WARNING_ACTIVE flag when a p2p bridge returns ↵mmichelson1-0/+3
AST_BRIDGE_RETRY. Without this flag set, warning sounds will not be properly played to either party of the bridge. (closes issue #14845) Reported by: adomjan git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@186832 f38db490-d61c-443f-a65b-d21fe96a405b