aboutsummaryrefslogtreecommitdiffstats
path: root/main
AgeCommit message (Collapse)AuthorFilesLines
2008-03-13Fixing a potential buffer overflow in the manager command ModuleCheck.mmichelson1-2/+2
Though this overflow is exploitable remotely, we are NOT issuing a security advisory for this since in order to exploit the overflow, the attacker would have to establish an authenticated manager session AND have the system privilege. By gaining this privilege, the attacker already has more powerful weapons at his disposal than overflowing a buffer with a malformed manager header, so the vulnerability in this case really lies with the authentication method that allowed the attacker to gain the system privilege in the first place. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@108529 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-12Make the default prefix empty, like it was in Asterisk 1.4.russell1-4/+1
(closes issue #12198, reported by bkruse, patched by me) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@108346 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-12Rename ast_tcptls_server_instance to session_instance, since this pertains torussell3-18/+18
server and client usage. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@108295 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-12Doxygenify slinfactory a bit.file1-0/+49
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@108226 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-12Merged revisions 108135 via svnmerge from russell1-8/+13
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r108135 | russell | 2008-03-12 14:57:42 -0500 (Wed, 12 Mar 2008) | 40 lines (closes issue #12187, reported by atis, fixed by me after some brainstorming on the issue with mmichelson) - Update copyright info on app_chanspy. - Fix a race condition that caused app_chanspy to crash. The issue was that the chanspy datastore magic that was used to ensure that spyee channels did not disappear out from under the code did not completely solve the problem. It was actually possible for chanspy to acquire a channel reference out of its datastore to a channel that was in the middle of being destroyed. That was because datastore destruction in ast_channel_free() was done near the end. So, this left the code in app_chanspy accessing a channel that was partially, or completely invalid because it was in the process of being free'd by another thread. The following sort of shows the code path where the race occurred: ============================================================================= Thread 1 (PBX thread for spyee chan) || Thread 2 (chanspy) --------------------------------------||------------------------------------- ast_channel_free() || - remove channel from channel list || - lock/unlock the channel to ensure || that no references retrieved from || the channel list exist. || --------------------------------------||------------------------------------- || channel_spy() - destroy some channel data || - Lock chanspy datastore || - Retrieve reference to channel || - lock channel || - Unlock chanspy datastore --------------------------------------||------------------------------------- - destroy channel datastores || - call chanspy datastore d'tor || which NULL's out the ds' || - Operate on the channel ... reference to the channel || || - free the channel || || || - unlock the channel --------------------------------------||------------------------------------- ============================================================================= ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@108137 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-12Merged revisions 108083 via svnmerge from file1-14/+35
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r108083 | file | 2008-03-12 15:26:37 -0300 (Wed, 12 Mar 2008) | 4 lines Add a trigger mode that triggers on both read and write. The actual function that returns the combined audio frame though will wait until both sides have fed in audio, or until one side stops (such as the case when you call Wait). (closes issue #11945) Reported by: xheliox ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@108084 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-12Merged revisions 108031 via svnmerge from russell1-1/+2
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r108031 | russell | 2008-03-12 11:59:07 -0500 (Wed, 12 Mar 2008) | 4 lines Destroy the channel lock after the channel datastores. (inspired by issue #12187) ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@108032 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-12Revert several changes from revision 102525, as the changes were nottilghman1-2/+2
compatible, and, in fact, introduced regressions. (Closes issue #12190) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@107960 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-11An offhand comment from Russell made me realize that the configuration filetilghman1-16/+22
caching would not work properly for users.conf and any other file read from more than one place. I needed to add the filename which requested the config file to get it to work properly. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@107791 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-11Merged revisions 107646 via svnmerge from file1-0/+2
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r107646 | file | 2008-03-11 16:20:01 -0300 (Tue, 11 Mar 2008) | 4 lines Make sure the visible indication is on the right channel so when the masquerade happens the proper indication is enacted. (closes issue #11707) Reported by: iam ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@107659 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-11Clarify comment about masquerading and playback of the parking slot.file1-1/+1
(closes issue #12180) Reported by: davidw git-svn-id: http://svn.digium.com/svn/asterisk/trunk@107465 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-11Merged revisions 107408 via svnmerge from kpfleming1-1/+1
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r107408 | kpfleming | 2008-03-11 09:07:59 -0500 (Tue, 11 Mar 2008) | 5 lines check for compiler support for -fno-strict-overflow before using it (tested with Debian's gcc 4.3, 4.1 and 3.4) (closes issue #12179) Reported by: Netview ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@107409 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-11Merged revisions 107352 via svnmerge from kpfleming3-3/+9
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r107352 | kpfleming | 2008-03-11 06:04:29 -0500 (Tue, 11 Mar 2008) | 11 lines fix up various compiler warnings found with gcc-4.3: - the output of flex includes a static function called 'input' that is not used, so for the moment we'll stop having the compiler tell us about unused variables in the flex source files (a better fix would be to improve our flex post-processing to remove the unused function) - main/stdtime/localtime.c makes assumptions about signed integer overflow, and gcc-4.3's improved optimizer tries to take advantage of handling potential overflow conditions at compile time; for now, suppress these optimizations until we can fiure out if the code needs improvement - main/udptl.c has some references to uninitialized variables; in one case there was no bug, but in the other it was certainly possibly for unexpected behavior to occur - main/editline/readline.c had an unused variable ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@107373 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-10(closes issue #6019)tilghman1-11/+83
Reported by: ssokol Patches: 20080304__bug6019.diff.txt uploaded by Corydon76 (license 14) Tested by: putnopvut git-svn-id: http://svn.digium.com/svn/asterisk/trunk@107231 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-10Merged revisions 107161 via svnmerge from russell1-1/+1
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r107161 | russell | 2008-03-10 15:17:11 -0500 (Mon, 10 Mar 2008) | 8 lines Fix another bug specifically related to asynchronous call origination. Once the PBX is started on the channel using ast_pbx_start(), then the ownership of the channel has been passed on to another thread. We can no longer access it in this code. If the channel gets hung up very quickly, it is possible that we could access a channel that has been free'd. (inspired by BE-386) ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@107162 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-10Merged revisions 107158 via svnmerge from russell1-1/+8
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r107158 | russell | 2008-03-10 15:04:27 -0500 (Mon, 10 Mar 2008) | 9 lines Fix some bugs related to originating calls. If the code failed to start a PBX on the channel (such as if you set a call limit based on the system's load average), then there were cases where a channel that has already been free'd using ast_hangup() got accessed. This caused weird memory corruption and crashes to occur. (fixes issue BE-386) (much debugging credit goes to twilson, final patch written by me) ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@107159 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-10Merged revisions 107102 via svnmerge from russell1-1/+1
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r107102 | russell | 2008-03-10 12:13:17 -0500 (Mon, 10 Mar 2008) | 2 lines Resolve a compiler warning. ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@107103 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-10Merged revisions 107099 via svnmerge from russell1-1/+5
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r107099 | russell | 2008-03-10 11:58:57 -0500 (Mon, 10 Mar 2008) | 3 lines Fix a race condition where the generator can go away (closes issue #12175, reported by edantie, patched by me) ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@107100 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-10way back in July, in r.75706, a fix was made ot the strftime usages, which ↵murf1-5/+7
was good, but in this case, the check for a nil time was accidentally removed, and now it is restored, to keep timevals like '1969-12-31 17:00:00' from showing up in the cdrs. No idea what databases will do with this. No bugs filed as yet, but it felt like a bug. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@107019 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-10Merged revisions 107016 via svnmerge from file1-5/+6
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r107016 | file | 2008-03-10 11:33:02 -0300 (Mon, 10 Mar 2008) | 7 lines Move where unanswered CDRs are dropped to the CDR core, not everything uses app_dial. (closes issue #11516) Reported by: ys Patches: branch_1.4_cdr.diff uploaded by ys (license 281) Tested by: anest, jcapp, dartvader ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@107017 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-07Merged revisions 106842 via svnmerge from qwell1-1/+1
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r106842 | qwell | 2008-03-07 16:14:45 -0600 (Fri, 07 Mar 2008) | 5 lines Fix hardcoded grep in editline, were GNU grep is required. (closes issue #12124) Reported by: dmartin ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@106843 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-07Merged revisions 106788 via svnmerge from file1-0/+1
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r106788 | file | 2008-03-07 15:32:00 -0400 (Fri, 07 Mar 2008) | 4 lines Ignore source update control frame. (closes issue #12168) Reported by: plack ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@106789 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-07(closes issue #6002)murf2-221/+386
Reported by: rizzo Tested by: murf Proposal of the changes to be made, and then an announcement of how they were accomplished: http://lists.digium.com/pipermail/asterisk-dev/2008-February/032065.html and: http://lists.digium.com/pipermail/asterisk-dev/2008-March/032124.html Here is a recap, file by file, of what I have done: pbx/pbx_config.c pbx/pbx_ael.c All funcs that were passed a ptr to the context list, now will ALSO be passed a hashtab ptr to the same set. Why? because (for the time being), the dialplan is stored in both, to facilitate a quick, low-cost move to hash-tables to speed up dialplan processing. If it was deemed necessary to pass the context LIST, well, it is just as necessary to have the TABLE available. This is because the list/table in question might not be the global one, but temporary ones we would use to stage the dialplan on, and then swap into the global position when things are ready. We now have one external function for apps to use, "ast_context_find_or_create()" instead of the pre-existing "find" and "create", as all existing usages used both in tandem anyway. pbx_config, and pbx_ael, will stage the reloaded dialplan into local lists and tables, and then call merge_contexts_and_delete, which will merge (now) existing contexts and priorities from other registrars into this local set by copying them. Then, merge_contexts_and_delete will lock down the contexts, swap the lists and tables, and unlock (real quick), and then destroy the old dialplan. chan_sip.c chan_iax.c chan_skinny.c All the channel drivers that would add regcontexts now use the ast_context_find_or_create now. chan_sip also includes a small fix to get rid of warnings about removing priorities that never got entered. apps/app_meetme.c apps/app_dial.c apps/app_queue.c All the apps that added a context/exten/priority were also modified to use ast_context_find_or_create instead. include/asterisk/pbx.h ast_context_create() is removed. Find_or_create_ is the new method. ast_context_find_or_create() interface gets the hashtab added. ast_merge_contexts_and_delete() gets the local hashtab arg added. ast_wrlock_contexts_version() is added so you can detect if someone else got a writelock between your readlocking and writelocking. ast_hashtab_compare_contexts was made public for use in pbx_config/pbx_ael ast_hashtab_hash_contexts was in like fashion make public. include/asterisk/pval.h ast_compile_ael2() interface changed to include the local hashtab table ptr. main/features.c For the sake of the parking context, we use ast_context_find_or_create(). main/pbx.c I changed all the "tree" names to "table" instead. That's because the original implementation was based on binary trees. (had a free library). Then I moved to hashtabs. Now, the names move forward too. refcount field added to contexts, so you can keep track of how many modules wanted this context to exist. Some log messages that are warnings were inflated from LOG_NOTICE to LOG_WARNING. Added some calls to ast_verb(3,...) for debug messages Lots of little mods to ast_context_remove_extension2, which is now excersized in ways it was not previously; one definite bug fixed. find_or_create was upgraded to handle both local lists/tables as well as the globals. context_merge() was added to do the per-context merging of the old/present contexts/extens/prios into the new/proposed local list/tables ast_merge_contexts_and_delete() was heavily modified. ast_add_extension2() was also upgraded to handle changes. the context_destroy() code was re-engineered to handle the new way of doing things, by exten/prio instead of by context. res/ael/pval.c res/ael/ael.tab.c res/ael/ael.tab.h res/ael/ael.y res/ael/ael_lex.c res/ael/ael.flex utils/ael_main.c utils/extconf.c utils/conf2ael.c utils/Makefile Had to change the interface to ast_compile_ael2(), to include the hashtab ptr. This ended up involving several external apps. The main gotcha was I had to include lock.h and hashtab.h in several places. As a side note, I tested this stuff pretty thoroughly, I replicated the problems originally reported by Luigi, and made triply sure that reloads worked, and everything worked thru "stop gracefully". I found a and fixed a few bugs as I was merging into trunk, that did not appear in my tests of bug6002. How's this for verbose commit messages? git-svn-id: http://svn.digium.com/svn/asterisk/trunk@106757 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-07Merged revisions 106606 via svnmerge from tilghman1-0/+1
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r106606 | tilghman | 2008-03-07 09:20:52 -0600 (Fri, 07 Mar 2008) | 3 lines Properly initialize rtp->schedid (Closes issue #12154) ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@106607 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-07Merged revisions 106552 via svnmerge from tilghman3-8/+10
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r106552 | tilghman | 2008-03-07 00:36:33 -0600 (Fri, 07 Mar 2008) | 6 lines Safely use the strncat() function. (closes issue #11958) Reported by: norman Patches: 20080209__bug11958.diff.txt uploaded by Corydon76 (license 14) ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@106553 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-07Merge changes from team/russell/g722-sillyness ...russell2-3/+11
Fix a number of other places where the number of samples in a G722 frame was not properly handled because of various reasons. main/rtp.c: - When a G722 frame is read from the smoother, the number of samples in the frame must be divided by 2 before being sent out over the network. Even though G722 is 16 kHz, an error in some previous spec has made it so that we have to list the number of samples such as if it was 8 kHz. main/file.c: - When scheduling the next time to expect a frame, take into account that the format of the file we're reading from may not be 8 kHz. codecs/codec_g722.c: - When converting from G722 to slinear, g722_decode() expects its samples parameter to be in the silly (real samples / 2) format. Make it so. - When converting from slinear to G722, properly set the number of samples in the frame to be the number of bytes of output * 2. formats/format_pcm.c: - This format module handles G722, among a number of other formats. However, the read() and seek() functions did not account for the fact that G722 has 2 samples per byte. (closes issue #12130, reported by rickross, patched by me) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@106501 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-06Fix file playback in many cases.qwell1-41/+71
(closes issue #12115) Reported by: pj Patches: v2-fileexists.patch uploaded by dimas (license 88) (with modifications by me) Tested by: dimas, qwell, russell git-svn-id: http://svn.digium.com/svn/asterisk/trunk@106439 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-06Merged revisions 106437 via svnmerge from mmichelson1-3/+1
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r106437 | mmichelson | 2008-03-06 16:10:07 -0600 (Thu, 06 Mar 2008) | 8 lines Quell an annoying message that is likely to print every single time that ast_pbx_outgoing_app is called. The reason is that __ast_request_and_dial allocates the cdr for the channel, so it should be expected that the channel will have a cdr on it. Thanks to joetester on IRC for pointing this out ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@106438 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-05Merged revisions 106235 via svnmerge from file4-2/+21
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r106235 | file | 2008-03-05 18:32:10 -0400 (Wed, 05 Mar 2008) | 4 lines Add a control frame to indicate the source of media has changed. Depending on the underlying technology it may need to change some things. (closes issue #12148) Reported by: jcomellas ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@106239 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-05Adding the Atxfer manager command. With this, you may initiatemmichelson1-0/+70
an attended transfer over AMI (closes issue #10585) Reported by: ornati Patches: atxfer-trunk-r90428.diff uploaded by ornati (license 210) (with modifications from me) Tested by: putnopvut git-svn-id: http://svn.digium.com/svn/asterisk/trunk@106236 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-05Fix code up to what it was meant to be.file1-2/+1
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@106110 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-05Create a centralized configuration option for silencethresholdtilghman4-5/+75
(closes issue #11236) Reported by: philipps Patches: 20080218__bug11236.diff.txt uploaded by Corydon76 (license 14) Tested by: philipps git-svn-id: http://svn.digium.com/svn/asterisk/trunk@106072 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-05Merged revisions 105932 via svnmerge from russell2-12/+4
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r105932 | russell | 2008-03-04 19:52:18 -0600 (Tue, 04 Mar 2008) | 5 lines Fix a bug that I just noticed in the RTP code. The calculation for setting the len field in an ast_frame of audio was wrong when G.722 is in use. The len field represents the number of ms of audio that the frame contains. It would have set the value to be twice what it should be. ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@105933 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-04There are several places in manager.c where BUFSIZ is used for a buffermmichelson1-6/+6
which will contain nowhere near that amount of data. This makes these buffers more reasonably sized. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@105864 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-04Fix minor misuses of snprintftilghman1-4/+4
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@105841 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-04Whitespace changes onlytilghman32-661/+547
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@105840 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-04add a destroy API call for a server instancerussell3-2/+8
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@105804 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-04More public API name changes to use an appropriate ast_ prefixrussell3-17/+17
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@105785 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-04Rename public object server_instance to ast_tcptls_server_instancerussell3-15/+15
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@105773 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-04Merged revisions 105676 via svnmerge from file1-0/+1
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r105676 | file | 2008-03-04 14:10:34 -0400 (Tue, 04 Mar 2008) | 2 lines In addition to setting the marker bit let's change our ssrc so they know for sure it is a different source. ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@105677 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-04Merged revisions 105674 via svnmerge from file1-0/+15
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r105674 | file | 2008-03-04 14:05:28 -0400 (Tue, 04 Mar 2008) | 8 lines When a new source of audio comes in (such as music on hold) make sure the marker bit gets set. (closes issue #10355) Reported by: wdecarne Patches: 10355.diff uploaded by file (license 11) (closes issue #11491) Reported by: kanderson ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@105675 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-04Make it so you don't have to cast away const in a couple placesrussell1-2/+2
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@105594 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-04remove unnecessary castsrussell1-2/+2
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@105593 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-04 - Add curly braces around the while looprussell1-6/+10
- Properly break out of the loop on error when an included context is not found git-svn-id: http://svn.digium.com/svn/asterisk/trunk@105590 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-04Use ast_copy_string() instead of strncpy(), and use sizeof() instead ofrussell1-1/+4
a magic number git-svn-id: http://svn.digium.com/svn/asterisk/trunk@105589 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-03Merged revisions 105565 via svnmerge from russell1-1/+3
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r105565 | russell | 2008-03-03 10:01:50 -0600 (Mon, 03 Mar 2008) | 3 lines Update the copyright information for autoservice. Most of the code in this file now is stuff that I have written recently ... ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@105566 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-033) In addition to merging the changes below, change trunk back to a regularrussell3-26/+43
LIST instead of an RWLIST. The way this list works makes it such that a RWLIST provides no additional benefit. Also, a mutex is needed for use with the thread condition. Merged revisions 105563 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r105563 | russell | 2008-03-03 09:50:43 -0600 (Mon, 03 Mar 2008) | 24 lines Merge in some changes from team/russell/autoservice-nochans-1.4 These changes fix up some dubious code that I came across while auditing what happens in the autoservice thread when there are no channels currently in autoservice. 1) Change it so that autoservice thread doesn't keep looping around calling ast_waitfor_n() on 0 channels twice a second. Instead, use a thread condition so that the thread properly goes to sleep and does not wake up until a channel is put into autoservice. This actually fixes an interesting bug, as well. If the autoservice thread is already running (almost always is the case), then when the thread goes from having 0 channels to have 1 channel to autoservice, that channel would have to wait for up to 1/2 of a second to have the first frame read from it. 2) Fix up the code in ast_waitfor_nandfds() for when it gets called with no channels and no fds to poll() on, such as was the case with the previous code for the autoservice thread. In this case, the code would call alloca(0), and pass the result as the first argument to poll(). In this case, the 2nd argument to poll() specified that there were no fds, so this invalid pointer shouldn't actually get dereferenced, but, this code makes it explicit and ensures the pointers are NULL unless we have valid data to put there. (related to issue #12116) ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@105564 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-03Merged revisions 105560 via svnmerge from file1-1/+8
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r105560 | file | 2008-03-03 11:28:59 -0400 (Mon, 03 Mar 2008) | 7 lines It is possible for no audio to pass between the current digit and next digit so expand logic that clears emulation to AST_FRAME_NULL. (closes issue #11911) Reported by: edgreenberg Patches: v1-11911.patch uploaded by dimas (license 88) Tested by: tbsky ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@105561 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-01Add support for 16KHz signed linear.file1-2/+2
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@105509 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-01Asterisk, when parking can drop rights a caller when a parking timeout ↵twilson3-6/+62
occurs. Also, when doing built-in attended transfers, sometimes incorrectly passes rights from the transferrer to the transferee. This patch tries to fixes the parking issue and lays some groundwork for later fixing the transfer issue. (closes issue #11520) Reported by: pliew Tested by: otherwiseguy git-svn-id: http://svn.digium.com/svn/asterisk/trunk@105477 f38db490-d61c-443f-a65b-d21fe96a405b