dect
/
asterisk
Archived
13
0
Fork 0
Commit Graph

79 Commits

Author SHA1 Message Date
rizzo 150b2c22ef remove another set of redundant #include "asterisk/options.h"
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@89512 f38db490-d61c-443f-a65b-d21fe96a405b
2007-11-21 23:24:55 +00:00
rizzo 9cf442d7f7 include "logger.h" and errno.h from asterisk.h - usage shows that they
were included almost everywhere.
Remove some of the instances.



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@89424 f38db490-d61c-443f-a65b-d21fe96a405b
2007-11-19 18:52:04 +00:00
rizzo 883346d64a Start untangling header inclusion in a way that does not affect
build times - tested, there is no measureable difference before and
after this commit.

In this change:

use asterisk/compat.h to include a small set of system headers:
inttypes.h, unistd.h, stddef.h, stddint.h, sys/types.h, stdarg.h,
stdlib.h, alloca.h, stdio.h

Where available, the inclusion is conditional on HAVE_FOO_H as determined
by autoconf.

Normally, source files should not include any of the above system headers,
and instead use either "asterisk.h" or "asterisk/compat.h" which does it
better. 

For the time being I have left alone second-level directories
(main/db1-ast, etc.).



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@89333 f38db490-d61c-443f-a65b-d21fe96a405b
2007-11-16 20:04:58 +00:00
mmichelson 92ac6820ee "show application <foo>" changes for clarity.
(closes issue #11171, reported and patched by blitzrage)

Many thanks!



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@89044 f38db490-d61c-443f-a65b-d21fe96a405b
2007-11-06 19:04:45 +00:00
murf 47c8ea00b8 This commits the performance mods that give the priority processing engine in the pbx, a 25-30% speed boost. The two updates used, are, first, to merge the ast_exists_extension() and the ast_spawn_extension() where they are called sequentially in a loop in the code, into a slightly upgraded version of ast_spawn_extension(), with a few extra args; and, second, I modified the substitute_variables_helper_full, so it zeroes out the byte after the evaluated string instead of demanding you pre-zero the buffer; I also went thru the code and removed the code that zeroed this buffer before every call to the substitute_variables_helper_full. The first fix provides about a 9% speedup, and the second the rest. These figures come from the 'PIPS' benchmark I describe in blogs, conf. reports, etc.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@88166 f38db490-d61c-443f-a65b-d21fe96a405b
2007-11-01 22:26:51 +00:00
russell b3ceaa6a9e Convert code that checks the _softhangup member of ast_channel directory to use
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-08-01 15:39:54 +00:00
tilghman 356721a45c Mostly cleanup of documentation to substitute the pipe with the comma, but a few other formatting cleanups, too.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@77808 f38db490-d61c-443f-a65b-d21fe96a405b
2007-07-31 01:10:47 +00:00
file 5d19e1c92a Merged revisions 77768 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

................
r77768 | file | 2007-07-30 11:51:44 -0300 (Mon, 30 Jul 2007) | 12 lines

Merged revisions 77767 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r77767 | file | 2007-07-30 11:50:02 -0300 (Mon, 30 Jul 2007) | 4 lines

(closes issue #10334)
Reported by: ramonpeek
Pass through the return value from macro_exec through the MacroIf application.

........

................


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@77769 f38db490-d61c-443f-a65b-d21fe96a405b
2007-07-30 14:53:14 +00:00
russell 4f3c4dc7f2 Do a massive conversion for using the ast_verb() macro
(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-26 15:49:18 +00:00
tilghman fd0b69a4e7 Merge the dialplan_aesthetics branch. Most of this patch simply converts applications
using old methods of parsing arguments to using the standard macros.  However, the big
change is that the really old way of specifying application and arguments separated by
a comma will no longer work (e.g. NoOp,foo|bar).  Instead, the way that has been
recommended since long before 1.0 will become the only method available (e.g. NoOp(foo,bar).


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@76703 f38db490-d61c-443f-a65b-d21fe96a405b
2007-07-23 19:51:41 +00:00
file d17ff1ea42 Applications no longer need to call ast_module_user_add and ast_module_user_remove. This is now taken care of in the pbx_exec function outside of the application.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@75200 f38db490-d61c-443f-a65b-d21fe96a405b
2007-07-16 14:39:29 +00:00
file 9e24ed5ccf It is no longer required for each module that deals with a channel to call ast_module_user_hangup_all in it's unload function. The loader will automatically perform this action for it.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@75183 f38db490-d61c-443f-a65b-d21fe96a405b
2007-07-16 13:35:20 +00:00
russell f042431847 Add a massive set of changes for converting to use the ast_debug() macro.
(issue #9957, patches from mvanbaak, caio1982, critch, and dimas)


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@69327 f38db490-d61c-443f-a65b-d21fe96a405b
2007-06-14 19:39:12 +00:00
tilghman eb5d461ed4 Issue 9869 - replace malloc and memset with ast_calloc, and other coding guidelines changes
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@67864 f38db490-d61c-443f-a65b-d21fe96a405b
2007-06-06 21:20:11 +00:00
tilghman bfd11fcd7e Merged revisions 66770 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

................
r66770 | tilghman | 2007-05-31 12:15:09 -0500 (Thu, 31 May 2007) | 10 lines

Merged revisions 66744 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r66744 | tilghman | 2007-05-31 10:58:45 -0500 (Thu, 31 May 2007) | 2 lines

Issue 9818 - Fix for issue 8329 breaks pbx_realtime.  Issue 8329 will remain unfixed for pbx_realtime, but only because we lack core API to do it.

........

................


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@66771 f38db490-d61c-443f-a65b-d21fe96a405b
2007-05-31 17:16:38 +00:00
tilghman 274ae2107a Merged revisions 63478 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

................
r63478 | tilghman | 2007-05-08 17:38:02 -0500 (Tue, 08 May 2007) | 10 lines

Merged revisions 63477 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r63477 | tilghman | 2007-05-08 17:19:15 -0500 (Tue, 08 May 2007) | 2 lines

Issue 9602 - segfault in app_macro

........

................


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@63479 f38db490-d61c-443f-a65b-d21fe96a405b
2007-05-08 22:40:21 +00:00
tilghman 05e190a693 Merged revisions 60713 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

................
r60713 | tilghman | 2007-04-08 09:14:29 -0500 (Sun, 08 Apr 2007) | 10 lines

Merged revisions 60711 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r60711 | tilghman | 2007-04-08 09:00:22 -0500 (Sun, 08 Apr 2007) | 2 lines

Gosub called within a Macro resets the arguments improperly and causes general weirdness. (Issue 8329)

........

................


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@60715 f38db490-d61c-443f-a65b-d21fe96a405b
2007-04-08 14:23:16 +00:00
murf 158c02018c Merged revisions 59188 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

................
r59188 | murf | 2007-03-23 10:09:01 -0600 (Fri, 23 Mar 2007) | 9 lines

Merged revisions 59186 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r59186 | murf | 2007-03-23 09:57:26 -0600 (Fri, 23 Mar 2007) | 1 line

Added a few words in the Macro doc strings about the behavior of macros with hangups (et al.), as per 9337
........

................


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@59190 f38db490-d61c-443f-a65b-d21fe96a405b
2007-03-23 16:17:57 +00:00
tilghman fe7f5ebc0f Merged revisions 53355 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

................
r53355 | tilghman | 2007-02-07 09:33:51 -0600 (Wed, 07 Feb 2007) | 10 lines

Merged revisions 53354 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r53354 | tilghman | 2007-02-07 09:30:02 -0600 (Wed, 07 Feb 2007) | 2 lines

Issue 7440 - Macro called from Macro from the h extension exits prematurely

........

................


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@53356 f38db490-d61c-443f-a65b-d21fe96a405b
2007-02-07 15:35:44 +00:00
murf 3d2d536881 Added a warning to the documentation for Macro in response to bug 7776
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@44336 f38db490-d61c-443f-a65b-d21fe96a405b
2006-10-04 15:37:51 +00:00
mogorman 4a1aaf52ae bug #8076 check option_debug before printing to debug channel.
patch provided in bugnote, with minor changes.


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@44253 f38db490-d61c-443f-a65b-d21fe96a405b
2006-10-03 15:53:07 +00:00
mattf b759835a90 Various updates from PCadach's chan_h323-live branch
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@43294 f38db490-d61c-443f-a65b-d21fe96a405b
2006-09-19 21:07:49 +00:00
mogorman d5df46a93e similar patch for verbose vs debug with minor changes
bug 2617


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@43272 f38db490-d61c-443f-a65b-d21fe96a405b
2006-09-19 16:23:45 +00:00
murf c38db54e51 Committed a fix for 7731, suggested by mnehauser.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@41268 f38db490-d61c-443f-a65b-d21fe96a405b
2006-08-29 13:21:47 +00:00
kpfleming 8b0c007ad9 merge new_loader_completion branch, including (at least):
- 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-08-21 02:11:39 +00:00
murf 5df4de5f05 In app_macro, changed the previously changed upper recursion depth limit to a variable, default of the original val of 7. MACRO_RECURSION is a channel variable that will override the limit, but until I can understand and fix why this limit is neccessary, I am not advertising this variable in the docs.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@40200 f38db490-d61c-443f-a65b-d21fe96a405b
2006-08-17 15:48:49 +00:00
murf 56484aaf19 This change fixes bug 7731, macros not executing more than one level deep in a hung-up situation; also increased maximum recursion depth from 7 to 20, to keep serious coders from painful toe-stubbings
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@39909 f38db490-d61c-443f-a65b-d21fe96a405b
2006-08-15 21:25:19 +00:00
russell e054e18cbd resolve some compiler warnings ...
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@39684 f38db490-d61c-443f-a65b-d21fe96a405b
2006-08-14 03:34:16 +00:00
russell 19758a4ffd add MacroExclusive application, a Macro that only one call can executed at
a time (issue #7366, Steve Davies, with mods by me as discussed in the report)


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@39681 f38db490-d61c-443f-a65b-d21fe96a405b
2006-08-14 03:24:06 +00:00
kpfleming 73c525e6e2 simplify autoconfig include mechanism (make tholo happy he can use lint again :-)
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@32846 f38db490-d61c-443f-a65b-d21fe96a405b
2006-06-07 18:54:56 +00:00
russell a46a4c185c Merged revisions 24837 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r24837 | russell | 2006-05-05 10:44:50 -0400 (Fri, 05 May 2006) | 3 lines

use pbx_checkcondition() instead of ast_true() to evaluate the condition
for MacroIf and WhileIf (issue #7086)

........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@24838 f38db490-d61c-443f-a65b-d21fe96a405b
2006-05-05 14:47:22 +00:00
rizzo 3664249356 This rather large commit changes the way modules are loaded.
As partly documented in loader.c and include/asterisk/module.h,
modules are now expected to return all of their methods and flags
into a structure 'mod_data', and are normally loaded with RTLD_NOW
| RTLD_LOCAL, so symbols are resolved immediately and conflicts
should be less likely.  Only in a small number of cases (res_*,
typically) modules are loaded RTLD_GLOBAL, so they can export
symbols.
 
The core of the change is only the two files loader.c and
include/asterisk/module.h, all the rest is simply adaptation of the
existing modules to the new API, a rather mechanical (but believe
me, time and finger-consuming!) process whose detail you can figure
out by svn diff'ing any single module.

Expect some minor compilation issue after this change, please
report it on mantis http://bugs.digium.com/view.php?id=6968
so we collect all the feedback in one place.

I am just sorry that this change missed SVN version number 20000!



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@20003 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-14 14:08:19 +00:00
kpfleming e4880150b1 since the module API is changing, it's a good time to const-ify the description() and key() return values
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@18552 f38db490-d61c-443f-a65b-d21fe96a405b
2006-04-08 22:01:19 +00:00
rizzo 454a3cb53d use ast_strdup instead of strdup
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@16561 f38db490-d61c-443f-a65b-d21fe96a405b
2006-03-30 21:47:22 +00:00
russell c72e5e1b38 remove the uses of the deprecated STANDARD_LOCAL_USER
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@10241 f38db490-d61c-443f-a65b-d21fe96a405b
2006-02-15 20:11:56 +00:00
tilghman 19e31d4510 Merged revisions 9156 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r9156 | tilghman | 2006-02-05 11:10:19 -0600 (Sun, 05 Feb 2006) | 2 lines

Bug 6176 - Fix race condition

........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@9157 f38db490-d61c-443f-a65b-d21fe96a405b
2006-02-05 17:20:29 +00:00
russell 252fb982f4 on this pass, only remove duplicate log messages
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@8403 f38db490-d61c-443f-a65b-d21fe96a405b
2006-01-21 20:57:06 +00:00
russell b14bdc5a12 revert my pass through the tree to remove checks of the result of ast_strdupa
(revisions 8378 through 8381)


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@8387 f38db490-d61c-443f-a65b-d21fe96a405b
2006-01-21 17:50:04 +00:00
russell 3f2c7248c6 remove lots of useless checks of the result of ast_strdupa
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@8379 f38db490-d61c-443f-a65b-d21fe96a405b
2006-01-21 08:13:12 +00:00
russell c68a2d2d8e Various cleanups from comments in an email from Luigi Rizzo. Thank you!
- Use a cleaner syntax for declaring the allocation macros
- Fix return value for ast_strdup/ast_strndup
- remove safe_strdup from app_macro, since ast_strup does the same thing
- fix a place in app_queue where ast_calloc+strncpy was used instead of
  ast_strdup.  If you are helping out with these conversions, please watch out
  for other places where this is done.
- add a note to the coding guidelines about the fix to app_queue


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@8065 f38db490-d61c-443f-a65b-d21fe96a405b
2006-01-13 18:38:55 +00:00
russell ab6566173e update doxygen docs to specify authors
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@7682 f38db490-d61c-443f-a65b-d21fe96a405b
2005-12-30 21:18:06 +00:00
russell 893828a1d4 reduce some duplicated code when doing a strdup (issue #5986)
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@7472 f38db490-d61c-443f-a65b-d21fe96a405b
2005-12-13 22:03:06 +00:00
tilghman 3365b1cc9f Bug 5858 - Make the chanvars.c functions return a 'const char *'
This should prevent us from unintentionally changing variable
values when they're returned from pbx_builtin_getvar_helper.


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@7304 f38db490-d61c-443f-a65b-d21fe96a405b
2005-12-03 19:25:33 +00:00
kpfleming 24c1e3c222 git-svn-id: http://svn.digium.com/svn/asterisk/trunk@7221 f38db490-d61c-443f-a65b-d21fe96a405b 2005-11-29 18:24:39 +00:00
russell 465d1d7712 make app_queue 1.2 jump compliant (issue #5580)
add missing includes of stdio.h
remove some unused and duplicate headers


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@7026 f38db490-d61c-443f-a65b-d21fe96a405b
2005-11-08 04:48:00 +00:00
kpfleming e61f71745f application doc update
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@6992 f38db490-d61c-443f-a65b-d21fe96a405b
2005-11-07 22:01:22 +00:00
russell d3ddc001a2 issue #5605
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@6979 f38db490-d61c-443f-a65b-d21fe96a405b
2005-11-06 15:09:47 +00:00
russell 2a1fd152ed remove unnecessary checks before calls to ast_strlen_zero
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@6864 f38db490-d61c-443f-a65b-d21fe96a405b
2005-10-26 19:48:14 +00:00
russell 2c3b3edc86 Doxygen documentation update from oej (issue #5505)
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@6847 f38db490-d61c-443f-a65b-d21fe96a405b
2005-10-24 20:12:06 +00:00
russell 58818426d6 Massive cleanups to applications for LOCAL_USER handling and some other things.
In general, LOCAL_USER_ADD/REMOVE should be the first/last thing called in an
application.  An exception is if there is some *fast* setup code that might
halt the execution of the application, such as checking to see if an argument
exists.


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@6832 f38db490-d61c-443f-a65b-d21fe96a405b
2005-10-19 18:19:02 +00:00