aboutsummaryrefslogtreecommitdiffstats
path: root/pbx/pbx_dundi.c
AgeCommit message (Collapse)AuthorFilesLines
2007-09-21Merged revisions 83432 via svnmerge from russell1-12/+10
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r83432 | russell | 2007-09-21 09:37:20 -0500 (Fri, 21 Sep 2007) | 4 lines gcc 4.2 has a new set of warnings dealing with cosnt pointers. This set of changes gets all of Asterisk (minus chan_alsa for now) to compile with gcc 4.2. (closes issue #10774, patch from qwell) ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@83433 f38db490-d61c-443f-a65b-d21fe96a405b
2007-09-20Fix memory leaks in pbx_dundi, cdr_pgsql, and the configuration file parser.file1-8/+5
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@83229 f38db490-d61c-443f-a65b-d21fe96a405b
2007-09-18Merged revisions 82802 via svnmerge from russell1-1/+31
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r82802 | russell | 2007-09-18 11:31:01 -0500 (Tue, 18 Sep 2007) | 4 lines When copying the contents from the wildcard peer, do a deep copy instead of shallow copy so that it doesn't crash when beging destroyed. (closes issue #10546, patch by me) ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@82803 f38db490-d61c-443f-a65b-d21fe96a405b
2007-09-11Merged revisions 82250 via svnmerge from russell1-3/+36
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r82250 | russell | 2007-09-11 11:03:42 -0500 (Tue, 11 Sep 2007) | 4 lines The sample dundi.conf claims support for a wildcard peer entry - [*], but the code did not support it. This patch makes it work. (closes issue #10546, patch by dds, with some changes by me) ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@82251 f38db490-d61c-443f-a65b-d21fe96a405b
2007-09-11Merged revisions 82243 via svnmerge from file1-0/+5
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r82243 | file | 2007-09-11 11:56:39 -0300 (Tue, 11 Sep 2007) | 6 lines (closes issue #10577) Reported by: jamesgolovich Patches: asterisk-dundifree.diff.txt uploaded by jamesgolovich (license 176) Don't leak memory when unloading DUNDi. ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@82244 f38db490-d61c-443f-a65b-d21fe96a405b
2007-08-28Add proper channel locking around the uses of datastore_add and _find. Thererussell1-1/+8
are still more places in the tree that I have not yet changed if someone wants to go through and find the places they are used without the channel locked. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@81262 f38db490-d61c-443f-a65b-d21fe96a405b
2007-08-27This should have been trunk only, I guess. oh well ... it's harmless.russell1-1/+2
Merged revisions 81065 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r81065 | russell | 2007-08-27 11:38:33 -0500 (Mon, 27 Aug 2007) | 1 line explicity define a variable as a boolean ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@81098 f38db490-d61c-443f-a65b-d21fe96a405b
2007-08-27Merged revisions 81074 via svnmerge from russell1-0/+1
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r81074 | russell | 2007-08-27 12:27:48 -0500 (Mon, 27 Aug 2007) | 3 lines Add a \todo to note that this module leaks most of the memory it allocates on unload and should be fixed (when I'm not in the middle of something else ...). ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@81076 f38db490-d61c-443f-a65b-d21fe96a405b
2007-08-25localize a variable and remove a duplicate error messagerussell1-4/+2
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@80897 f38db490-d61c-443f-a65b-d21fe96a405b
2007-08-17Correct the argument separator for a Dial statement in pbx_dundi.qwell1-1/+1
Closes issue #10483, patch by lunn git-svn-id: http://svn.digium.com/svn/asterisk/trunk@79888 f38db490-d61c-443f-a65b-d21fe96a405b
2007-08-16Don't reload a configuration file if nothing has changed.tilghman1-6/+8
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@79747 f38db490-d61c-443f-a65b-d21fe96a405b
2007-08-16(closes issue #10467)file1-1/+2
Reported by: lunn Patches: pbx_dundi.diff uploaded by lunn (license 179) Don't print a warning saying an ethernet interface was found when it indeed was. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@79688 f38db490-d61c-443f-a65b-d21fe96a405b
2007-08-01Convert code that checks the _softhangup member of ast_channel directory to userussell1-4/+4
the ast_check_hangup() funciton. This function takes scheduled hangups into account. (closes issue #10230, patch by Juggie) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@77858 f38db490-d61c-443f-a65b-d21fe96a405b
2007-07-26Do a massive conversion for using the ast_verb() macrorussell1-7/+2
(closes issue #10277, patches by mvanbaak) Basically, this changes ... if (option_verbose > 2) ast_verbose(VERBOSE_PREFIX_3, "Something\n"); to ... ast_verb(3, "Something\n"); git-svn-id: http://svn.digium.com/svn/asterisk/trunk@77299 f38db490-d61c-443f-a65b-d21fe96a405b
2007-07-19After some study, thought, comparing, etc. I've backed out the previous ↵murf1-4/+4
universal mod to make ast_flags a 64 bit thing. Instead, I added a 64-bit version of ast_flags (ast_flags64), and 64-bit versions of the test-flag, set-flag, etc. macros, and an app_parse_options64 routine, and I use these in app_dial alone, to eliminate the 30-option limit it had grown to meet. There is room now for 32 more options and flags. I was heavily tempted to implement some of the other ideas that were presented, but this solution does not intro any new versions of dial, doesn't have a different API, has a minimal/zero impact on code outside of dial, and doesn't seriously (I hope) affect the code structure of dial. It's the best I can think of right now. My goal was NOT to rewrite dial. I leave that to a future, coordinated effort. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@75983 f38db490-d61c-443f-a65b-d21fe96a405b
2007-07-18This corrects the problem with flags and %lld formats on 64-bit machines, ↵murf1-2/+2
where uint64_t is NOT acceptable for %lld, and also works on 32-bit machines. At least, with gcc. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@75585 f38db490-d61c-443f-a65b-d21fe96a405b
2007-07-18Merged revisions 75583 via svnmerge from file1-6/+7
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r75583 | file | 2007-07-18 11:18:53 -0300 (Wed, 18 Jul 2007) | 5 lines (closes issue #10224) Reported by: irroot Record the threadid of each running thread before shutting them down as the thread themselves may change the value. ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@75584 f38db490-d61c-443f-a65b-d21fe96a405b
2007-07-17via 10206, I have added an option (e) to Dial to allow the h exten to get ↵murf1-3/+3
run on peer. Had to upgrade ast_flag stuff to 64 bits to do this. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@75400 f38db490-d61c-443f-a65b-d21fe96a405b
2007-07-09Merged revisions 74045 via svnmerge from file1-4/+13
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r74045 | file | 2007-07-09 11:49:05 -0300 (Mon, 09 Jul 2007) | 2 lines Few minor thread synchronization tweaks. (issue #10124 reported by gzero) ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@74046 f38db490-d61c-443f-a65b-d21fe96a405b
2007-06-27Merged revisions 72006 via svnmerge from file1-2/+15
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r72006 | file | 2007-06-26 20:58:35 -0400 (Tue, 26 Jun 2007) | 2 lines Make unloading of pbx_dundi actually work. ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@72007 f38db490-d61c-443f-a65b-d21fe96a405b
2007-05-24use the OpenSSL AES implementation if it's available (unless configured not to)kpfleming1-14/+15
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@66071 f38db490-d61c-443f-a65b-d21fe96a405b
2007-05-24Add a new API call for creating detached threads. Then, go replace all of therussell1-18/+5
places in the code where the same block of code for creating detached threads was replicated. (patch from bbryant) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@65968 f38db490-d61c-443f-a65b-d21fe96a405b
2007-05-15Make sure that DUNDIRESULT is given an ID.russell1-0/+5
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@64469 f38db490-d61c-443f-a65b-d21fe96a405b
2007-04-30Add support for setting the CoS for VLAN traffic (802.1p) in Linux. Therussell1-6/+3
file doc/qos.tex has been updated to document the new functionality. (issue #9540, patch submitted by IgorG) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@62457 f38db490-d61c-443f-a65b-d21fe96a405b
2007-04-28Merge changes from team/russell/dundi_resultsrussell1-2/+194
This introduces two new dialplan functions: DUNDIQUERY and DUNDIRESULT. DUNDIQUERY lets you intitiate a DUNDi query from the dialplan. Then, DUNDIRESULT will let you find out how many results there are, and access each one without having to the query again. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@62267 f38db490-d61c-443f-a65b-d21fe96a405b
2007-03-07Add the ability to dynamically specify weights for responses to DUNDi queries.russell1-7/+31
This can be done using a global variable or a dialplan function. Using the SHELL() function will allow you to use an external script to determine what the weight in the response should be. This can be very useful in load balancing applications. (inspired by discussions with blitzrage and jsmith in #asterisk-bugs) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@58304 f38db490-d61c-443f-a65b-d21fe96a405b
2007-02-28Convert the PBX core to use read/write locks. This yields a nifty ↵file1-2/+2
performance improvement when it comes to simultaneous calls going through the dialplan. Using murf's test the old mutex based core took an average of 57.3 seconds while the rwlock based core took 31.1 seconds. That's a nifty 26.2 seconds performance improvement. The other good part is that if we do need to switch back then we just have to change the lock/unlock API calls. I converted everywhere that used to touch the mutex locks directly to use them. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@57184 f38db490-d61c-443f-a65b-d21fe96a405b
2007-01-31Merged revisions 53046 via svnmerge from russell1-0/+6
https://origsvn.digium.com/svn/asterisk/branches/1.4 ................ r53046 | russell | 2007-01-31 15:32:08 -0600 (Wed, 31 Jan 2007) | 11 lines Merged revisions 53045 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.2 ........ r53045 | russell | 2007-01-31 15:25:11 -0600 (Wed, 31 Jan 2007) | 3 lines Fix a bunch of places where pthread_attr_init() was called, but pthread_attr_destroy() was not. ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@53047 f38db490-d61c-443f-a65b-d21fe96a405b
2007-01-05const-ify some more APIs, and fix rev 49710 from branch-1.4 in a better way herekpfleming1-1/+1
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@49711 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-06Staticize one, and Constify a bunch of usage strings for CLI commands.russell1-15/+15
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48303 f38db490-d61c-443f-a65b-d21fe96a405b
2006-11-10Fine, take this.file1-1/+1
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@47465 f38db490-d61c-443f-a65b-d21fe96a405b
2006-11-10Hello compiler working, goodbye compiler warning. (fix compiler warning ↵file1-1/+1
introduced from pbx_dundi optimizations) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@47461 f38db490-d61c-443f-a65b-d21fe96a405b
2006-11-10Various little bits of code cleanup to reduce nesting, remove useless casts,russell1-39/+37
and to remove a duplicated error message after a memory allocation error git-svn-id: http://svn.digium.com/svn/asterisk/trunk@47410 f38db490-d61c-443f-a65b-d21fe96a405b
2006-11-05Make pbx_dundi compile again. Sorry. :(russell1-3/+5
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@47213 f38db490-d61c-443f-a65b-d21fe96a405b
2006-11-04use the AST_MODULE_LOAD_* return codes from load_module()russell1-18/+18
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@47207 f38db490-d61c-443f-a65b-d21fe96a405b
2006-11-04simplify a couple of loopsrussell1-13/+10
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@47206 f38db490-d61c-443f-a65b-d21fe96a405b
2006-11-04Do some minor cleanup to the section of code that sets the EID by getting therussell1-15/+15
mac address for an ethernet interface git-svn-id: http://svn.digium.com/svn/asterisk/trunk@47204 f38db490-d61c-443f-a65b-d21fe96a405b
2006-11-01Add the ability to pass options to the Dial application when using the DUNDirussell1-1/+4
switch in the dialplan by setting the DUNDIDIALARGS channel variable. (issue #8084, patch by bluecrow76, with small modifications and documentation updates) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@46781 f38db490-d61c-443f-a65b-d21fe96a405b
2006-10-12put flags in an enum and remove a couple of unused definesrussell1-10/+9
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@44944 f38db490-d61c-443f-a65b-d21fe96a405b
2006-10-04Merged revisions 44378 via svnmerge from kpfleming1-2/+2
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r44378 | kpfleming | 2006-10-04 14:47:22 -0500 (Wed, 04 Oct 2006) | 4 lines update thread creation code a bit reduce standard thread stack size slightly to allow the pthreads library to allocate the stack+data and not overflow a power-of-2 allocation in the kernel and waste memory/address space add a new stack size for 'background' threads (those that don't handle PBX calls) when LOW_MEMORY is defined ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@44379 f38db490-d61c-443f-a65b-d21fe96a405b
2006-10-03bug #8076 check option_debug before printing to debug channel.mogorman1-50/+91
patch provided in bugnote, with minor changes. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@44253 f38db490-d61c-443f-a65b-d21fe96a405b
2006-09-18merge qwell's CLI verbification workkpfleming1-74/+63
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@43212 f38db490-d61c-443f-a65b-d21fe96a405b
2006-08-31everything that loads a config that needs a config file to runmogorman1-1/+2
now reports AST_MODULE_LOAD_DECLINE when loading if config file is not there, also fixed an error in res_config_pgsql where it had a non static function when it should. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@41633 f38db490-d61c-443f-a65b-d21fe96a405b
2006-08-21merge new_loader_completion branch, including (at least):kpfleming1-21/+12
- restructured build tree and makefiles to eliminate recursion problems - support for embedded modules - support for static builds - simpler cross-compilation support - simpler module/loader interface (no exported symbols) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@40722 f38db490-d61c-443f-a65b-d21fe96a405b
2006-07-21Merge a new implementation of ast_inet_ntoa, our thread safe replacement forrussell1-22/+17
inet_ntoa, which uses thread specific data (aka thread local storage) instead of stack allocatted buffers to store the result. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@38042 f38db490-d61c-443f-a65b-d21fe96a405b
2006-06-07simplify autoconfig include mechanism (make tholo happy he can use lint ↵kpfleming1-4/+4
again :-) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@32846 f38db490-d61c-443f-a65b-d21fe96a405b
2006-05-10remove almost all of the checks of the result from ast_strdupa() or alloca().russell1-2/+1
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-07- use ast_calloc instead of malloc+memsetrussell1-11/+6
- conver one malloc to ast_malloc git-svn-id: http://svn.digium.com/svn/asterisk/trunk@25356 f38db490-d61c-443f-a65b-d21fe96a405b
2006-05-02staticize the list heads from my recent conversions to list macrosrussell1-5/+5
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@24139 f38db490-d61c-443f-a65b-d21fe96a405b
2006-05-01- convert permission lists to use list macrosrussell1-68/+48
- remove unused precachesend and precachereceive variables from dundi_peer This concludes the visit to pbx_dundi ... git-svn-id: http://svn.digium.com/svn/asterisk/trunk@23831 f38db490-d61c-443f-a65b-d21fe96a405b