summaryrefslogtreecommitdiff
path: root/channels
AgeCommit message (Collapse)Author
2007-08-07Merged revisions 78375 via svnmerge from Jason Parker
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r78375 | qwell | 2007-08-07 13:25:15 -0500 (Tue, 07 Aug 2007) | 3 lines Properly check the capabilities count to avoid a segfault. (ASA-2007-019) ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@78378 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-08-07Merged revisions 78371 via svnmerge from Russell Bryant
https://origsvn.digium.com/svn/asterisk/branches/1.4 ................ r78371 | russell | 2007-08-07 12:45:30 -0500 (Tue, 07 Aug 2007) | 12 lines Merged revisions 78370 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.2 ........ r78370 | russell | 2007-08-07 12:44:04 -0500 (Tue, 07 Aug 2007) | 4 lines Revert patch committed for issue #9660. It broke E&M trunks. (closes issue #10360) (closes issue #10364) ........ ................ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@78372 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-08-07Can't forget outsignaling!Joshua Colp
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@78347 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-08-07Just for jsmith... make signaling a valid option that acts like signalling.Joshua Colp
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@78346 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-08-06Add a TalkingToChan to the response of the "agents" manager action.Jason Parker
This is similar to the existing "talking to" that you see what using the "agent show" CLI command. Closes issue #10102 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@78312 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-08-06Merged revisions 78242 via svnmerge from Russell Bryant
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r78242 | russell | 2007-08-06 15:44:09 -0500 (Mon, 06 Aug 2007) | 4 lines Fix an issue where dynamic threads can get free'd, but still exist in the dynamic thread list. (closes issue #10392, patch from Mihai, with credit to his colleague, Pete) ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@78243 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-08-06Fixing a compiler warning which warns that a variable may be used ↵Mark Michelson
unitialized. Thanks to mvanbaak for pointing this out. git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@78192 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-08-06Merged revisions 78103 via svnmerge from Mark Michelson
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r78103 | mmichelson | 2007-08-03 15:25:22 -0500 (Fri, 03 Aug 2007) | 7 lines Changed the behavior of sip's realtime_peer function to match the corresponding way of matching for non-realtime peers. Now matches are made on both the IP address and port number, or if the insecure setting is set to "port" then just match on the IP address. In order to accomplish this, I also added a new API call, ast_category_root, which returns the first variable of an ast_category struct ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@78186 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-08-06Merged revisions 78182 via svnmerge from Joshua Colp
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r78182 | file | 2007-08-06 13:32:44 -0300 (Mon, 06 Aug 2007) | 2 lines It is possible for a transfer to occur before the remote device has our tag in which case they send none in the transfer. In this case we need to not fail the transfer dialog lookup. ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@78183 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-08-06Implement setvar functionality in chan_skinnyJason Parker
Closes issue #10379, patch by mvanbaak. git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@78179 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-08-05Merged revisions 78139 via svnmerge from Tilghman Lesher
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r78139 | tilghman | 2007-08-04 22:29:01 -0500 (Sat, 04 Aug 2007) | 2 lines If peer is not found, the error message is misleading (should be peer not found, not ACL failure) ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@78140 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-08-03Merged revisions 78063 via svnmerge from Russell Bryant
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r78063 | russell | 2007-08-03 12:01:07 -0500 (Fri, 03 Aug 2007) | 4 lines Only pass through HOLD and UNHOLD control frames when the mohinterpret option is set to "passthrough". This was pointed out by Kevin in the middle of a training session. ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@78064 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-08-03Merged revisions 78028 via svnmerge from Russell Bryant
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r78028 | russell | 2007-08-02 21:04:22 -0500 (Thu, 02 Aug 2007) | 6 lines Don't reuse the timespec that was set to 0 in the previous timedwait as it will just return immediately. Also, fix some logic so the thread's lock isn't unlocked twice in the weird case of dynamic threads getting acquired right after a timeout. (pointed out by SteveK) ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@78029 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-08-02Merged revisions 77996 via svnmerge from Jason Parker
https://origsvn.digium.com/svn/asterisk/branches/1.4 (closes issue #9779) ........ r77996 | qwell | 2007-08-02 16:53:39 -0500 (Thu, 02 Aug 2007) | 5 lines Make sure we actually allow 6 chars to be sent. Also make note of the "A" option of date format. Issue 9779, modifications by DEA, wedhorn, and myself. ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77997 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-08-02Merged revisions 77993 via svnmerge from Jason Parker
https://origsvn.digium.com/svn/asterisk/branches/1.4 (closes issue #10325) ........ r77993 | qwell | 2007-08-02 15:22:40 -0500 (Thu, 02 Aug 2007) | 5 lines If a device disconnects, the session will go away. If this happens during call setup, we need to give up. Issue 10325. ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77994 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-08-02Merged revisions 77949 via svnmerge from Russell Bryant
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r77949 | russell | 2007-08-02 14:25:14 -0500 (Thu, 02 Aug 2007) | 5 lines Fix the case where a dynamic thread times out waiting for something to do during the first time it runs. This shouldn't ever happen, but we should account for it anyway. (pointed out by pete, who works with mihai) ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77950 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-08-02Merged revisions 77947 via svnmerge from Jason Parker
https://origsvn.digium.com/svn/asterisk/branches/1.4 (closes issue #10299) ........ r77947 | qwell | 2007-08-02 13:42:36 -0500 (Thu, 02 Aug 2007) | 5 lines Make sure we clear the prompt status message on a hangup. Also rearrange messages to better fit with what a wireshark trace shows it should be. Issue 10299, initial patch and solution by sbisker, modified by me to fit with wireshark trace. ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77948 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-08-02Merged revisions 77943 via svnmerge from Russell Bryant
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r77943 | russell | 2007-08-02 13:04:43 -0500 (Thu, 02 Aug 2007) | 9 lines Fix another race condition in the handling of dynamic threads. If the dynamic thread timed out waiting for something to do, but was acquired to perform an action immediately afterwords, then wait on the condition again to give the other thread a chance to finish setting up the data for what action this thread should perform. Otherwise, if it immediately continues, it will perform the wrong action. (reported on IRC by mihai, patch by me) (related to issue #10289) ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77944 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-08-02Fix an issue that Simon pointed out to me on IRC. There were cases in theRussell Bryant
trunk version of find_idle_thread() where the old full frame processing information was not cleared out. This would have caused full frames to get deferred for processing by threads that weren't actually processing frames for that call. Nice catch!! git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77941 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-08-02Merged revisions 77939 via svnmerge from Russell Bryant
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r77939 | russell | 2007-08-02 11:56:04 -0500 (Thu, 02 Aug 2007) | 4 lines Add another sanity check to vnak_retransmit(). This check ensures that frames that have already been marked for deletion don't get retransmitted. (closes issue #10361, patch from mihai) ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77940 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-08-02Merged revisions 77894 via svnmerge from Jason Parker
https://origsvn.digium.com/svn/asterisk/branches/1.4 (closes issue #10358) ........ r77894 | qwell | 2007-08-02 10:15:45 -0500 (Thu, 02 Aug 2007) | 5 lines Make sure that we show the correct extension if dialed from a macro "From: 5555" rather than "From: s" Issue 10358, initial patch by DEA, reworked by me to use S_OR, tested by sbisker ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77895 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-08-01Merged revisions 77890 via svnmerge from Jason Parker
https://origsvn.digium.com/svn/asterisk/branches/1.4 (closes issue #10291) ........ r77890 | qwell | 2007-08-01 17:28:56 -0500 (Wed, 01 Aug 2007) | 4 lines Put in some additional debug information for softkey/stimulus messages. Issue 10291, patch by DEA. ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77891 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-08-01Merged revisions 77887 via svnmerge from Russell Bryant
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r77887 | russell | 2007-08-01 17:16:17 -0500 (Wed, 01 Aug 2007) | 23 lines Fix some race conditions which have been causing weird problems in chan_iax2. The most notable problem is that people have been seeing storms of VNAK frames being sent due to really old frames mysteriously being in the retransmission queue and never getting removed. It was possible that a dynamic thread got created, but did not acquire its lock before the thread that created it signals it to perform an action. When this happens, the thread will sleep until it hits a timeout, and then get destroyed. So, the action never gets performed and in some cases, means a frame doesn't get transmitted and never gets freed since the scheduler never gets a chance to reschedule transmission. Another less severe race condition is in the handling of a timeout for a dynamic thread. It was possible for it to be acquired to perform at action at the same time that it hit a timeout. When this occurs, whatever action it was acquired for would never get performed. (patch contributed by Mihai and SteveK) (closes issue #10289) (closes issue #10248) (closes issue #10232) (possibly related to issue #10359) ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77889 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-08-01Merged revisions 77883 via svnmerge from Jason Parker
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r77883 | qwell | 2007-08-01 16:08:42 -0500 (Wed, 01 Aug 2007) | 7 lines Fix an issue that caused one-way audio on some newer devices (specifically the 7921), due to sending packets in the wrong order during hangup. Also make sure we clear tones/messages on the correct line/instance. Issue 10291, patch by DEA, tested by sbisker and myself. ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77884 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-08-01Merged revisions 77869 via svnmerge from Joshua Colp
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r77869 | file | 2007-08-01 14:56:59 -0300 (Wed, 01 Aug 2007) | 2 lines Add some fixes for building on Solaris. ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77870 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-08-01Convert code that checks the _softhangup member of ast_channel directory to useRussell Bryant
the ast_check_hangup() funciton. This function takes scheduled hangups into account. (closes issue #10230, patch by Juggie) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77858 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-07-31thanks to Russel, for pointing out that the dialoglist_lock/unlock routines ↵Steve Murphy
also need to be macros if DETECT_DEADLOCKS is set git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77829 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-07-31Merged revisions 77824 via svnmerge from Mark Michelson
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r77824 | mmichelson | 2007-07-31 10:21:22 -0500 (Tue, 31 Jul 2007) | 6 lines This patch makes Asterisk send 100 Trying provisional responses upon receipt of re-invites. This makes it so that if there are two or more Asterisk servers between endpoints, the Asterisk servers will not keep retransmitting the re-invites. (closes issue #10274, reported by cstadlmann, patched by me with approval from file) ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77825 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-07-31there is no use in having functions that have no code in them, and hide the ↵Kevin P. Fleming
locking info when DEBUG_THREADS is enabled... i could have fixed this to be dependent on DEBUG_THREADS, but it would be just as easy for someone to add their test/debugging code to the macros as it would have been to the functions git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77821 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-07-31use a different method for overriding the send_digit_begin pointer, as the ↵Kevin P. Fleming
old one fails to compile on my 64-bit system with gcc-4.1 and --enable-dev-mode turned on git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77820 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-07-31Discovered in experiments on core files: if you wrap the lock and unlock ↵Steve Murphy
calls with sip_pvt_lock and sip_pvt_unlock, you lose the tracing info you would normally get via DETECT_DEADLOCKS; so I turn these two functions into macros when DETECT_DEADLOCKS is called. This way, you get meaningful stuff in the file and func slots in the lock_info struct. git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77810 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-07-30Change another unnecessary use of the increment operator to explicitly set ↵Russell Bryant
the var to 1 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77800 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-07-30Explicitly set a variable to 1 instead of using the increment operator.Russell Bryant
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77799 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-07-30Merged revisions 77794 via svnmerge from Russell Bryant
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r77794 | russell | 2007-07-30 15:16:43 -0500 (Mon, 30 Jul 2007) | 8 lines Fix an issue that could potentially cause corruption of the global iax frame queue. In the network_thread() loop, it traverses the list using the AST_LIST_TRAVERSE_SAFE macro. However, to remove an element of the list within this loop, it used AST_LIST_REMOVE, instead of AST_LIST_REMOVE_CURRENT, which I believe could leave some of the internal variables of the SAFE macro invalid. Mihai says that he already made this change in his local copy and it didn't help his VNAK storm issues, but I still think it's wrong. :) ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77797 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-07-30minor code rearrangements:Luigi Rizzo
+ place the link field at the beginning of struct sip_pvt, and not somewhere in the middle; + in __sip_reliable_xmit, remove a duplicate assignment, and put the statements in a more logical order (i.e. first copy the payload and associated info, then copy arguments from the caller, then finish initializing the headers...) nothing to backport. git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77766 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-07-30rename handle_request() to handle_incoming(), as the formerLuigi Rizzo
was misleading - the function deals with all incoming packets, be them requests or responses. git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77753 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-07-29move some dialog-only flags to proper variables, namelyLuigi Rizzo
SIP_NOVIDEO, SIP_DIALOG_ANSWEREDELSEWHERE, SIP_PAGE2_NOTEXT, SIP_PAGE2_OUTGOING_CALL These are seldom used so the diff is relatively small. Note that 'OUTGOING_CALL' is dangerously similar to another dialog flag, 'SIP_OUTGOING', so the description will need to clarify the different meaning of the two. Also note that the description of NOTEXT is a bit unclear - does it mean we don't support it, or 'not requested or not supported' ? On passing fix a comment referring to video instead of text. Finally, mark with XXX a possibly misleading debugging message. (maybe the latter is worth backporting). git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77739 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-07-29use a function, cli_yesno(), to produce the output Yes or No forLuigi Rizzo
CLI lines. This helps maintaining consistency on output, slightly improves readability, and maybe one day will make it easier to translate the output in other languages (though i have a hard time believing that a CLI user who needs 'yes' and 'no' to be translated can actually figure out what he/she is doing!) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77726 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-07-29move the two remaining peer flags to proper variables.Luigi Rizzo
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77725 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-07-29move RT_FROMCONTACT to a proper sip_peer field.Luigi Rizzo
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77712 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-07-29Move some global 'flags' to individual variables.Luigi Rizzo
Start putting these variables in a single struct (called 'sip_cfg' for the time being, but it could as well be 'global' or some other name) so it is easy, when reading the code, to figure out what they are for. The downside of using struct fields instead of individual global variables is that the compiler cannot tell if there are unused fields. But the advantage of not cluttering the namespace and manilpulating all these variables at once certainly overcome the disadvantagess. Nothing to backport, again. git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77711 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-07-29minor simplification of a conditional statementLuigi Rizzo
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77697 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-07-29build the version of sip_tech with no send_digit_beginLuigi Rizzo
at load time instead of duplicating the initializer. This should remove the risk of forgetting fields in the initializer. git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77684 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-07-29remove bit position from description of SIP_* flags. Luigi Rizzo
use AST_FORMAT_AUDIO_MASK instead of playing with AST_FORMAT_MAX_AUDIO to determine audio formats. There is a dubious use of AST_FORMAT_MAX_AUDIO in sip_request_call() which surely needs fixing, namely: /* mask request with some set of allowed formats. * XXX this needs to be fixed. * The original code uses AST_FORMAT_AUDIO_MASK, but it is * unclear what to use here. We have global_capabilities, which is * configured from sip.conf, and sip_tech.capabilities, which is * hardwired to all audio formats. */ The latter is possibly something to backport when fixed. git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77682 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-07-29back on cleaning up the usage of flags.Luigi Rizzo
Move together flags used in the same way (e.g. dialog only, dialog-peer, ...) so it will become easier to deal with them in a more systematic way. This is being done in stages so it will be easier to detect breakage, if any should occur. git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77669 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-07-29more documentation on internal representation of incoming SIP messages.Luigi Rizzo
Remove definitions for now-unused flags, and add references to print routines for other flags. git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77668 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-07-29make register_unref() return NULL so it is easy to cleanupLuigi Rizzo
the original pointer while calling the function. on passing add some comments on one of the places where it is used, and explain why it is safe there. again, a no-op for practical purposes. git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77654 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-07-28add some documentation to auto_congest(), and someLuigi Rizzo
dialog_ref/unref (they are a no-op at the moment). Also clean a pointer after freeing memory to avoid dangling references, and write a for() loop in canonical form. In practice, everything in this commit is a no-op. git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77653 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-07-28more dialog_ref()/dialog_unref() callsLuigi Rizzo
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77650 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-07-28more dialog_ref()/dialog_unref() callsLuigi Rizzo
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77648 65c4cc65-6c06-0410-ace0-fbb531ad65f3