aboutsummaryrefslogtreecommitdiffstats
path: root/channel.c
AgeCommit message (Collapse)AuthorFilesLines
2006-05-16Merged revisions 27468 via svnmerge from kpfleming1-0/+3
https://origsvn.digium.com/svn/asterisk/branches/1.2 ........ r27468 | kpfleming | 2006-05-16 15:05:17 -0500 (Tue, 16 May 2006) | 2 lines don't leak frames when deferring DTMF or dropping duplicate ANSWER frames (issue #7041, slightly different fix, reported/patched by clausf) ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@27477 f38db490-d61c-443f-a65b-d21fe96a405b
2006-05-11use the proper method to get out of the bridge loopkpfleming1-5/+5
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@26851 f38db490-d61c-443f-a65b-d21fe96a405b
2006-05-11initialize the bridge result to 'no result', so that we can check for code ↵kpfleming1-2/+2
paths that set it to AST_BRIDGE_COMPLETE inside the loop (thanks Oskar!) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@26849 f38db490-d61c-443f-a65b-d21fe96a405b
2006-05-10remove almost all of the checks of the result from ast_strdupa() or alloca().russell1-7/+2
As it turns out, all of these checks were useless, because alloca will never return NULL. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@26451 f38db490-d61c-443f-a65b-d21fe96a405b
2006-05-10ensure that control frames with payload can be sent to channel drivers via ↵kpfleming1-5/+15
->indicate() update iax2_indicate to pass control frame payload to the connected channel add an API call for sending an indication with payload, and use it for control frames with payload git-svn-id: http://svn.digium.com/svn/asterisk/trunk@26417 f38db490-d61c-443f-a65b-d21fe96a405b
2006-05-09Make sure that we don't accept an answer on an inbound call and don't permit ↵markster1-5/+14
asterisk to answer an outbound call git-svn-id: http://svn.digium.com/svn/asterisk/trunk@26103 f38db490-d61c-443f-a65b-d21fe96a405b
2006-05-09use an enum for control frame typeskpfleming1-1/+16
support sending control frames with payload git-svn-id: http://svn.digium.com/svn/asterisk/trunk@26093 f38db490-d61c-443f-a65b-d21fe96a405b
2006-05-09mark a couple of dubious pieces of coderizzo1-0/+2
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@25894 f38db490-d61c-443f-a65b-d21fe96a405b
2006-05-08Minor cleanup on dtmf calling (bug #7076)markster1-2/+1
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@25567 f38db490-d61c-443f-a65b-d21fe96a405b
2006-05-05 Make the "Avoided Initial Deadlock for '....', X retries!" a LOG_DEBUG msg ↵bweschke1-1/+1
instead of LOG_WARNING as this only has relevance to developers trying to resolve a possible problem. #6949 git-svn-id: http://svn.digium.com/svn/asterisk/trunk@25094 f38db490-d61c-443f-a65b-d21fe96a405b
2006-05-03remove useless variables, and argument checks for functionsrizzo1-11/+6
that can safely handle a NULL argument. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@24464 f38db490-d61c-443f-a65b-d21fe96a405b
2006-05-03no point in clearing a local variable just before returnrizzo1-1/+0
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@24462 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-30remove T38_SUPPORT define that is no longer neededkpfleming1-2/+0
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@23536 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-26more janitor work, patch from bug 6975.mogorman1-27/+28
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@22631 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-24Thanks to the fine work of Russell Bryant and Dancho Lazarov, we now have ↵kpfleming1-7/+7
autoconf and menuselect tools for Asterisk! git-svn-id: http://svn.digium.com/svn/asterisk/trunk@22267 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-21convert to use ast_stream_and_waitrizzo1-9/+5
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@22076 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-21- use symbolic constants and macros to play with the debug flagrizzo1-20/+14
on the frame counters. Document it in the header file. - provide a single exit point for a function; - mark XXX some unclear parts of the code. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@21933 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-21make NULL and "" equivalent in cid fields, mark some missing NULL checks.rizzo1-21/+15
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@21814 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-19move to a different file (channel.c for the time being) therizzo1-0/+55
wrappers around the basic 'say' functions, and redeclare these wrappers as ordinary functions rather than function pointers. This way, alternative implementations of the 'say' functions will only have to implement the basic functions and not the wrappers. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@21338 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-19- use ast_calloc instead of ast_mallocrizzo1-11/+6
- use ast_channel_lock/unlock in a few places - comment some dubious pieces of code - use memset to zero a buffer git-svn-id: http://svn.digium.com/svn/asterisk/trunk@21311 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-18Do not depend on having an end sound for stopping the bridge when time runs ↵file1-3/+3
out. (issue #6979 reported by ppyy) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@21130 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-17actually return the number steps... not the number of steps minus 1kpfleming1-2/+4
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@20964 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-17add an API so that the number of steps required for a translation path can ↵kpfleming1-4/+7
be acquired don't transcode via SLINEAR when the option is enabled but there is a direct path from the source to the destination git-svn-id: http://svn.digium.com/svn/asterisk/trunk@20962 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-16minor formatting fixesrizzo1-2/+2
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@20596 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-16move some duplicated code outside an if/then/else blockrizzo1-13/+14
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@20570 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-16make sure there is [almost] only a single exit point for a very longrizzo1-20/+22
function so the flow is easier to follow. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@20569 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-16simplify the ast_channel walking routines.rizzo1-37/+25
(the previous version was mine, but this way it is definitely more readable). git-svn-id: http://svn.digium.com/svn/asterisk/trunk@20543 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-16move common conditions to the outside block.rizzo1-11/+9
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@20540 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-16simplify logic in ast_generic_bridge()rizzo1-22/+17
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@20514 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-16move common code in one placerizzo1-4/+2
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@20513 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-16avoid returning in the middle of a switch() in ast_answer()rizzo1-3/+1
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@20512 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-16simplify function __ast_request_and_dial() as follows:rizzo1-79/+78
- handle immediately failures in ast_request(); This removes the need for checking 'chan' multiple times afterwards. - handle immediately failures in ast_call(), by moving the one-line case at the top of the 'if' statement; - use ast_strlen_zero in several places instead of expanding it inline; - make outstate always a valid pointer; On passing mark an unclear statement and replace a magic number with sizeof(tmp). git-svn-id: http://svn.digium.com/svn/asterisk/trunk@20511 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-16properly reindent a blockrizzo1-33/+32
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@20484 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-16add a missing ast_channel_unlock() evidenced by previous commits.rizzo1-1/+1
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@20477 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-16remove an extra lock.rizzo1-1/+0
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@20456 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-16- replace some nested 'if' with '&&'rizzo1-44/+34
- bring the short case at the top of an 'if' statement (also fix misformatting) - replace several 'if' with the '?' operator; - invert the condition on an 'if' to reduce the nesting depth (reindentation to be done later). git-svn-id: http://svn.digium.com/svn/asterisk/trunk@20454 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-16Localize some variables documenting their usage.rizzo1-13/+10
Comment a possible problem with locking. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@20453 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-16- Fixes to ast_channel_lock functionsoej1-1/+1
- New get_sip_pvt_byid function (not really used correctly yet...) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@20424 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-16localize some variables, add some comments.rizzo1-11/+10
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@20396 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-16implement ast_waitfordigit() and ast_readstring() in termsrizzo1-61/+2
of their '_full()' version, so we can remove the replicated implementation and, especially, the risk that they get out of sync. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@20389 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-15More ast_channel_lock fixesoej1-39/+43
- Update lock.h with definitions of ast_channel_lock, ast_channel_unlock and ast_channel_trylock - Convert some functions (but not all) in channel.c - Fix some bugs in chan_sip.c - Convert rest of chan_sip.c git-svn-id: http://svn.digium.com/svn/asterisk/trunk@20295 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-15New functions for locking a channel - these simplify debuggingoej1-0/+124
when you have channel locking issues. (Part of the SIP transfer patch, where I had a *lot* of channel locking problems) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@20264 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-14code cleanup (for loop normalization, remove useless casts and parentheses)rizzo1-27/+15
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@20132 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-11Merged revisions 19347 via svnmerge from kpfleming1-41/+34
https://origsvn.digium.com/svn/asterisk/branches/1.2 ........ r19347 | kpfleming | 2006-04-11 16:35:52 -0500 (Tue, 11 Apr 2006) | 2 lines simplify spy queue flushing logic, and always force a flush when one side gets full, even if the other side is not empty (issue #6457) ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@19349 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-11Data stores do not need a lock. As well change the way they are removed from ↵file1-19/+7
the channel when it is destroyed (thanks Russell Wussell) and finally... because C++ is silly... change our list macro info thing to be "entry" instead of "list". git-svn-id: http://svn.digium.com/svn/asterisk/trunk@19062 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-10Presenting a revised data stores and oh my, a generic speech recognition ↵file1-0/+124
API! I wonder what we can do with this now... git-svn-id: http://svn.digium.com/svn/asterisk/trunk@18979 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-06minor formatting cleanup and removal of trailing whitespace.rizzo1-167/+131
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@17863 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-06the fix for bug #6399 makes sense. thanks wrmem for the report.rizzo1-1/+2
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@17753 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-03list word cant be used with g++ and causes problemsmogorman1-6/+6
with h323. patch from bug 6446, renames list to chan_list git-svn-id: http://svn.digium.com/svn/asterisk/trunk@17130 f38db490-d61c-443f-a65b-d21fe96a405b
2006-03-30convert internal timing to be stored as a flag in the ast_options flagsrussell1-3/+3
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@16477 f38db490-d61c-443f-a65b-d21fe96a405b