aboutsummaryrefslogtreecommitdiffstats
path: root/utils/check_expr.c
AgeCommit message (Collapse)AuthorFilesLines
2008-12-17A possibly "horrible fix" for a "horribly broken"murf1-0/+17
situation. As stuff shifts around in the asterisk code, the miscellaneous inclusions from the standalone stuff gets broken. There's no easy fix for this situation. I made sure that everything in utils builds without problem ***AND*** that aelparse runs the regressions correctly with the following make menuselect options both on and off: DONT_OPTIMIZE DEBUG_THREADS DEBUG_CHANNEL_LOCKS MALLOC_DEBUG MTX_PROFILE DEBUG_SCHEDULER DEBUG_THREADLOCALS DETECT_DEADLOCKS CHANNEL_TRACE I think from now on, I'm going to #undef all these features in the various utils native files; I guess I could do the same for the copied-in files, surrounded by STANDALONE ifdef. A standalone isn't going to care about threads, mutexes, etc. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@165071 f38db490-d61c-443f-a65b-d21fe96a405b
2008-12-13Merge ast_str_opaque branch (discontinue usage of ast_str internals)tilghman1-51/+0
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@163991 f38db490-d61c-443f-a65b-d21fe96a405b
2008-11-29incorporates r159808 from branches/1.4:kpfleming1-2/+2
------------------------------------------------------------------------ r159808 | kpfleming | 2008-11-29 10:58:29 -0600 (Sat, 29 Nov 2008) | 7 lines update dev-mode compiler flags to match the ones used by default on Ubuntu Intrepid, so all developers will see the same warnings and errors since this branch already had some printf format attributes, enable checking for them and tag functions that didn't have them format attributes in a consistent way ------------------------------------------------------------------------ in addition: move some format attributes from main/utils.c to the header files they belong in, and fix up references to the relevant functions based on new compiler warnings git-svn-id: http://svn.digium.com/svn/asterisk/trunk@159818 f38db490-d61c-443f-a65b-d21fe96a405b
2008-05-29Avoid build warning when execinfo.h isn't available.seanbright1-7/+7
(closes issue #12751) Reported by: ys Patches: check_expr.diff uploaded by ys (license 281) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@118911 f38db490-d61c-443f-a65b-d21fe96a405b
2008-05-28Fix a linkage error related to the lock backtrace supportrussell1-0/+7
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@118695 f38db490-d61c-443f-a65b-d21fe96a405b
2008-05-23A new feature thanks to the fine folks at Switchvox!mmichelson1-4/+20
If a deadlock is detected, then the typical lock information will be printed along with a backtrace of the stack for the offending threads. Use of this requires compiling with DETECT_DEADLOCKS and having glibc installed. Furthermore, issuing the "core show locks" CLI command will print the normal lock information as well as a backtraces for each lock. This requires that DEBUG_THREADS is enabled and that glibc is installed. All the backtrace features may be disabled by running the configure script with --without-execinfo as an argument git-svn-id: http://svn.digium.com/svn/asterisk/trunk@118173 f38db490-d61c-443f-a65b-d21fe96a405b
2008-04-10Merged revisions 114051 via svnmerge from mmichelson1-1/+6
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r114051 | mmichelson | 2008-04-10 15:59:49 -0500 (Thu, 10 Apr 2008) | 3 lines Fix 1.4 build when LOW_MEMORY is enabled. ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@114052 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-18Go through and fix a bunch of places where character strings were being ↵twilson1-1/+1
interpreted as format strings. Most of these changes are solely to make compiling with -Wsecurity and -Wformat=2 happy, and were not actual problems, per se. I also added format attributes to any printf wrapper functions I found that didn't have them. -Wsecurity and -Wmissing-format-attribute added to --enable-dev-mode. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@109447 f38db490-d61c-443f-a65b-d21fe96a405b
2008-02-28Merged revisions 105116 via svnmerge from russell1-2/+2
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r105116 | russell | 2008-02-28 16:23:05 -0600 (Thu, 28 Feb 2008) | 8 lines Fix a bug in the lock tracking code that was discovered by mmichelson. The issue is that if the lock history array was full, then the functions to mark a lock as acquired or not would adjust the stats for whatever lock is at the end of the array, which may not be itself. So, do a sanity check to make sure that we're updating lock info for the proper lock. (This explains the bizarre stats on lock #63 in BE-396, thanks Mark!) ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@105144 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-10Add ast_atomic_fetchadd_int_slow to check_expr for platforms that need it.file1-0/+8
(closes issue #11484) Reported by: snuffy git-svn-id: http://svn.digium.com/svn/asterisk/trunk@92206 f38db490-d61c-443f-a65b-d21fe96a405b
2007-11-26closes issue #11341; made changes to make utils again right with the ↵murf1-0/+2
MTX_PROFILE world. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@89595 f38db490-d61c-443f-a65b-d21fe96a405b
2007-11-21more header removal/normalizationrizzo1-22/+5
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@89473 f38db490-d61c-443f-a65b-d21fe96a405b
2007-10-17and then, I noticed the clicompat stuff.murf1-15/+0
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@86182 f38db490-d61c-443f-a65b-d21fe96a405b
2007-10-17more stub routines to allow linkage in stand-alone environment, with thread ↵murf1-0/+15
debugs turned on git-svn-id: http://svn.digium.com/svn/asterisk/trunk@86181 f38db490-d61c-443f-a65b-d21fe96a405b
2007-10-09Remove redundant includes (patch by snuffy) (Closes issue #10922)tilghman1-2/+2
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@85140 f38db490-d61c-443f-a65b-d21fe96a405b
2007-10-08Fix up tree so that it compiles when MTX Profiling is enabled.file1-0/+5
(closes issue #10898) Reported by: snuffy Patches: 10898-mtx_prof.diff uploaded by qwell (license 4) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@85025 f38db490-d61c-443f-a65b-d21fe96a405b
2007-10-01OK. THis a DEBUG_THREADS situation.murf1-1/+7
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@84331 f38db490-d61c-443f-a65b-d21fe96a405b
2007-10-01picky gcc versions... sigh.murf1-0/+4
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@84330 f38db490-d61c-443f-a65b-d21fe96a405b
2007-10-01This mod will allow check_expr to compile in the presence of DEBUG_THREAD ↵murf1-0/+16
situations. At least, it does for me. And it's less expensive than several other approaches I tried. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@84329 f38db490-d61c-443f-a65b-d21fe96a405b
2007-08-22Ensure that the object code for ast_atomic_fetchadd_int() gets included in therussell1-0/+5
check_expr binary when building with LOW_MEMORY defined. (reported by Brian Capouch on the asterisk-dev list, patch by me) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@80262 f38db490-d61c-443f-a65b-d21fe96a405b
2007-08-15This commit closes bug 7605, and half-closes 7638. The AEL code has been ↵murf1-0/+65
redistributed/repartitioned to allow code re-use both inside and outside of Asterisk. This commit introduces the utils/conf2ael program, and an external config-file reader, for both normal config files, and for extensions.conf (context, exten, prio); It provides an API for programs outside of asterisk to use to play with the dialplan and config files. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@79595 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-0/+1
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-05In regards to changes for 9508, expr2 system choking on floating point ↵murf1-1/+8
numbers, I'm adding this update to round out (no pun intended) and make this FP-capable version of the Expr2 stuff interoperate better with previous integer-only usage, by providing Functions syntax, with 20 builtin functions for floating pt to integer conversions, and some general floating point math routines that might commonly be used also. Along with this, I made it so if a function was not a builtin, it will try and find it in the ast_custom_function list, and if found, execute it and collect the results. Thus, you can call system functions like CDR(), CHANNEL(), etc, from within $\[..\] exprs, without having to wrap them in $\{...\} (curly brace) notation. Did a valgrind on the standalone and made sure there's no mem leaks. Looks good. Updated the docs, too. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@73449 f38db490-d61c-443f-a65b-d21fe96a405b
2007-01-24Merged revisions 52052 via svnmerge from murf1-60/+91
https://origsvn.digium.com/svn/asterisk/branches/1.4 ................ r52052 | murf | 2007-01-24 11:26:22 -0700 (Wed, 24 Jan 2007) | 9 lines Merged revisions 52002 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.2 ........ r52002 | murf | 2007-01-24 10:43:50 -0700 (Wed, 24 Jan 2007) | 1 line updated check_expr via 8322 (refactoring of expression checking impl); elfring contributed a nice code reorg, I contributed some time to get it working again, better messages ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@52053 f38db490-d61c-443f-a65b-d21fe96a405b
2006-11-06check for failure after call to calloc() (issue #8295)russell1-0/+2
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@47232 f38db490-d61c-443f-a65b-d21fe96a405b
2005-11-29git-svn-id: http://svn.digium.com/svn/asterisk/trunk@7221 ↵kpfleming1-0/+0
f38db490-d61c-443f-a65b-d21fe96a405b
2005-09-14update MANY more files with proper copyright/license info (thanks Ian!)kpfleming1-0/+18
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@6596 f38db490-d61c-443f-a65b-d21fe96a405b
2005-08-29don't make expression evaluator allocate a memory buffer for each resultkpfleming1-6/+7
to be returned; use the buffers already present in the PBX for this purpose update testexpr2/check_expr to allocate buffers for expression evaluation git-svn-id: http://svn.digium.com/svn/asterisk/trunk@6440 f38db490-d61c-443f-a65b-d21fe96a405b
2005-06-21enhance check_expr to check for parsing errors in dialplans (bug #4556)kpfleming1-74/+188
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@5959 f38db490-d61c-443f-a65b-d21fe96a405b
2005-06-09add tool to check extensions.conf files for problems with new expression ↵kpfleming1-0/+191
parser (bug #4491) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@5886 f38db490-d61c-443f-a65b-d21fe96a405b