Commit Graph

24 Commits

Author SHA1 Message Date
Michiel van Baak 12071c18f0 make this compile under devmode
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@158686 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-11-22 15:58:49 +00:00
Tilghman Lesher e316c21986 Two new functions, REALTIME_FIELD, and REALTIME_HASH, which should make
querying realtime from the dialplan a little more consistent and easy to use.
The original REALTIME function is preserved, for those who are already
accustomed to that interface.
(closes issue #13651)
 Reported by: Corydon76
 Patches: 
       20081119__bug13651__2.diff.txt uploaded by Corydon76 (license 14)
 Tested by: blitzrage, Corydon76


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@157870 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-11-19 21:54:39 +00:00
Russell Bryant 5b168ee34b Merge changes from team/group/appdocsxml
This commit introduces the first phase of an effort to manage documentation of the
interfaces in Asterisk in an XML format.  Currently, a new format is available for
applications and dialplan functions.  A good number of conversions to the new format
are also included.

For more information, see the following message to asterisk-dev:

http://lists.digium.com/pipermail/asterisk-dev/2008-October/034968.html


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@153365 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-11-01 21:10:07 +00:00
Michiel van Baak 8e8359465b Older versions of GNU gcc do not allow 'NULL' as sentinel.
They want (char *)NULL as sentinel.
An example is OpenBSD (confirmed on 4.3) that ships with gcc 3.3.4

This commit introduces a contstant SENTINEL which is declared as:
#define SENTINEL ((char *)NULL)

All places I could test compile on my openbsd system are converted.
Update CODING-GUIDELINES to tell about this constant.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@124127 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-06-19 20:48:33 +00:00
Terry Wilson 6e7659e6b1 Add REALTIME_STORE and REALTIME_DESTROY dialplan functions provided by sergee.
I just added the ability to set multiple fields at once after discussions with
Tilghman and Russell.  Currently limited to 30 fields.

(closes issue #11887)
Reported by: sergee
Patches: 
      rt-func-store-destroy-multivalue.diff uploaded by otherwiseguy (license 396)
Tested by: sergee, otherwiseguy


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@102700 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-02-06 16:23:22 +00:00
Joshua Colp 7492c04a23 Add missing braces.
(closes issue #11886)
Reported by: sergee
Patches:
      func_realtime_fix-r101392.diff uploaded by sergee (license 138)


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@101393 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-01-31 15:36:11 +00:00
Luigi Rizzo 7e8835e0d7 remove another set of redundant #include "asterisk/options.h"
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@89512 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-11-21 23:24:55 +00:00
Luigi Rizzo 9335ace850 another bunch of include removals (errno.h and asterisk/logger.h)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@89425 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-11-19 19:09:03 +00:00
Luigi Rizzo fdb7f7ba3d 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: https://origsvn.digium.com/svn/asterisk/trunk@89333 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-11-16 20:04:58 +00:00
Tilghman Lesher 64a0a9aa2c Merged revisions 87262 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r87262 | tilghman | 2007-10-28 08:46:55 -0500 (Sun, 28 Oct 2007) | 7 lines

Add autoservice to several more functions which might delay in their responses.
Also, make sure that func_odbc functions have a channel on which to set
variables.
Reported by russell
Fixed by tilghman
Closes issue #11099

........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@87263 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-10-28 14:11:01 +00:00
Tilghman Lesher 55b1ee298e 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: https://origsvn.digium.com/svn/asterisk/trunk@76703 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-07-23 19:51:41 +00:00
Joshua Colp e498488bde For my next trick I will make it so dialplan functions no longer need to call ast_module_user_add and ast_module_user_remove. These are now called in the ast_func_read and ast_func_write functions outside of the module.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@75255 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-07-16 18:24:29 +00:00
Joshua Colp 96a646734f 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: https://origsvn.digium.com/svn/asterisk/trunk@75183 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-07-16 13:35:20 +00:00
Tilghman Lesher cb8b3e1efb Merged revisions 58933 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r58933 | tilghman | 2007-03-15 17:32:33 -0500 (Thu, 15 Mar 2007) | 2 lines

Function works fine, but the documentation is backwards.

........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@58934 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-03-15 22:33:46 +00:00
Tilghman Lesher 63cc6e10b4 Formatting fixes
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@53980 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-02-12 02:44:33 +00:00
Tilghman Lesher c4c2c546da When calling the Realtime app more than once, unset fields which were
previously set are erroneously still set (Bug 6701).  After discussion,
it was determined this should only be changed in trunk.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@49801 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-01-07 16:21:12 +00:00
Kevin P. Fleming 37182c873e finish const-ifying ast_func_read()
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@49741 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-01-06 00:13:33 +00:00
Luigi Rizzo 7c5f06ddcd replace ast_build_string() with ast_str_*().
Unless i am very mistaken, function_realtime_read() was
broken in that it would always return an empty string
(because ast_build_string() advanced the pointer to the
end of the string, and there was no reference to the
initial value.

This commit should fix this problem.



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@48551 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-12-17 22:57:46 +00:00
Kevin P. Fleming 0a27d8bfe5 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: https://origsvn.digium.com/svn/asterisk/trunk@40722 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-08-21 02:11:39 +00:00
Kevin P. Fleming 472c1ca282 simplify autoconfig include mechanism (make tholo happy he can use lint again :-)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@32846 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-06-07 18:54:56 +00:00
Russell Bryant 3d022d073a fix the build of func_realtime and aelparse with MTX_PROFILE enabled
(issue #7187, #7188, casper)


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@28895 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-20 00:41:36 +00:00
Russell Bryant a21507a60a suppress a compiler warning
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@24534 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-03 19:10:41 +00:00
Luigi Rizzo 2d5900391b remove variable declarations in the middle of two blocks.
While at it, normalize the surrounding code.



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@24495 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-03 18:22:04 +00:00
BJ Weschke a9281a1142 Introducing the REALTIME() dialplan function
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@24376 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-02 22:46:12 +00:00