Commit Graph

139 Commits

Author SHA1 Message Date
Naveen Albert ab1dbfef75 func_strings: Add trim functions.
Adds TRIM, LTRIM, and RTRIM, which can be used
for trimming leading and trailing whitespace
from strings.

ASTERISK-30222 #close

Change-Id: I50fb0c40726d044a7a41939fa9026f3da4872554
2022-09-22 05:49:00 -05:00
Naveen Albert 51d262af12 xmldocs: Improve examples.
Use example tags instead of regular para tags
where possible.

ASTERISK-30090

Change-Id: Iada8bbfda08f30b118cedf2d040bbb21e4966ec5
2022-06-09 03:47:41 -05:00
Naveen Albert 0c70d497bc documentation: Adds versioning information.
Adds version information for applications, functions,
and manager events/actions.

This is not completely exhaustive by any means but
covers most new things added that have release
versioning information in the issue tracker.

ASTERISK-29940 #close

Change-Id: I506401e93c799715dbbe97c0a8ba18af2bf5e131
2022-04-26 17:40:39 -05:00
Josh Soref 1b1f5f9f67 funcs: Spelling fixes
Correct typos of the following word families:

effectively
emitted
expect
anthony

ASTERISK-29714

Change-Id: Ic16f9ec855bb6d14ec8e170b90af9a36b06d488a
2021-11-15 19:28:27 -06:00
Naveen Albert b8fc77a35b func_strings: Add STRBETWEEN function
Adds the STRBETWEEN function, which can be used to insert a
substring between each character in a string. For instance,
this can be used to insert pauses between DTMF tones in a
string of digits.

ASTERISK-29627

Change-Id: Ice23009d4a8e9bb9718d2b2301d405567087d258
2021-09-10 15:53:25 -05:00
Kevin Harwell 4b5d11ec17 func_strings: HASHKEY - negative array index can cause corruption
This patch makes it so only matching non-empty key names, and keys created by
the HASH function are eligible for inclusion in the comma separated string. It
also fixes a bug where it was possible to write to a negative index if the
result buffer was empty.

ASTERISK-28159
patches:
  ASTERISK-28159.diff submitted by Michael Walton (license 6502)

Change-Id: I6e57fe7307dfd856271753aed5ba64c59b511487
2018-11-19 14:41:57 -05:00
Sean Bright fd0ca1c3f9 Remove as much trailing whitespace as possible.
Change-Id: I873c1c6d00f447269bd841494459efccdd2c19c0
2017-12-22 09:23:22 -05:00
Richard Mudgett cfe72c39cf LISTFILTER: Remove outdated ERROR message.
Feeding LISTFILTER an empty variable results in an invalid ERROR message.
Earlier changes made the message useless because we can no longer tell if
the variable is empty or does not exist.  It is valid to try to remove a
value from an empty list just as it is valid to try to remove a value that
is not in a non-empty list.

* Removed the outdated ERROR message.

* Added more test cases to the LISTFILTER unit test.

Change-Id: Ided9040e6359c44a335ef54e02ef5950a1863134
2017-01-22 17:56:15 -06:00
Corey Farrell a6e5bae3ef Remove ASTERISK_REGISTER_FILE.
ASTERISK_REGISTER_FILE no longer has any purpose so this commit removes
all traces of it.

Previously exported symbols removed:
* __ast_register_file
* __ast_unregister_file
* ast_complete_source_filename

This also removes the mtx_prof static variable that was declared when
MTX_PROFILE was enabled.  This variable was only used in lock.c so it
is now initialized in that file only.

ASTERISK-26480 #close

Change-Id: I1074af07d71f9e159c48ef36631aa432c86f9966
2016-10-27 09:53:55 -04:00
Matt Jordan 4a58261694 git migration: Refactor the ASTERISK_FILE_VERSION macro
Git does not support the ability to replace a token with a version
string during check-in. While it does have support for replacing a
token on clone, this is somewhat sub-optimal: the token is replaced
with the object hash, which is not particularly easy for human
consumption. What's more, in practice, the source file version was often
not terribly useful. Generally, when triaging bugs, the overall version
of Asterisk is far more useful than an individual SVN version of a file. As a
result, this patch removes Asterisk's support for showing source file
versions.

Specifically, it does the following:

* Rename ASTERISK_FILE_VERSION macro to ASTERISK_REGISTER_FILE, and
  remove passing the version in with the macro. Other facilities
  than 'core show file version' make use of the file names, such as
  setting a debug level only on a specific file. As such, the act of
  registering source files with the Asterisk core still has use. The
  macro rename now reflects the new macro purpose.

* main/asterisk:
  - Refactor the file_version structure to reflect that it no longer
    tracks a version field.
  - Remove the "core show file version" CLI command. Without the file
    version, it is no longer useful.
  - Remove the ast_file_version_find function. The file version is no
    longer tracked.
  - Rename ast_register_file_version/ast_unregister_file_version to
    ast_register_file/ast_unregister_file, respectively.

* main/manager: Remove value from the Version key of the ModuleCheck
  Action. The actual key itself has not been removed, as doing so would
  absolutely constitute a backwards incompatible change. However, since
  the file version is no longer tracked, there is no need to attempt to
  include it in the Version key.

* UPGRADE: Add notes for:
  - Modification to the ModuleCheck AMI Action
  - Removal of the "core show file version" CLI command

Change-Id: I6cf0ff280e1668bf4957dc21f32a5ff43444a40e
2015-04-13 03:48:57 -04:00
Mark Michelson fc52fd8884 Allow the PUSH and UNSHIFT functions to set inheritable channel variables.
........

Merged revisions 416500 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 416501 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 416502 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@416503 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-06-17 18:45:11 +00:00
Scott Griepentrog 43bd3580e2 pbx.c: prevent potential crash from recursive replace()
Recurisve usage of replace() resulted in corruption of the
temporary string storage and potential crash.  By changing
the string to be allocated separtely per instance, this is
eliminated.

ASTERISK-23650 #comment Reported by: Roel van Meer
ASTERISK-23650 #close

Review: https://reviewboard.asterisk.org/r/3539/
........

Merged revisions 414214 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 414215 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 414216 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@414217 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-05-21 19:08:39 +00:00
Corey Farrell fbe0dfaf44 Fix dialplan function NULL channel safety issues
(closes issue ASTERISK-23391)
Reported by: Corey Farrell
Review: https://reviewboard.asterisk.org/r/3386/
........

Merged revisions 411313 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 411314 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 411315 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@411328 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-03-27 19:21:44 +00:00
Scott Griepentrog ff02c8e254 func_strings: use memmove to prevent overlapping memory on strcpy
When calling REPLACE() with an empty replace-char argument, strcpy
is used to overwrite the the matching <find-char>.  However as the
src and dest arguments to strcpy must not overlap, it causes other
parts of the string to be overwritten with adjacent characters and
the result is mangled.  Patch replaces call to strcpy with memmove
and adds a test suite case for REPLACE.

(closes issue ASTERISK-22910)
Reported by: Gareth Palmer
Review: https://reviewboard.asterisk.org/r/3083/
Patches:
    func_strings.patch uploaded by Gareth Palmer (license 5169)
........

Merged revisions 404674 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 404675 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 404676 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@404677 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-01-02 19:38:09 +00:00
Rusty Newton 2a6df87fcd func_strings: Documentation fix for QUOTE()
Example output was inaccurate.

(issue ASTERISK-22970)
(closes issue ASTERISK-22970)
Reported by: Gareth Palmer
Patches:
   func_strings.patch uploaded by Gareth Palmer (license 5169)
........

Merged revisions 404081 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 404087 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 404099 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@404100 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-12-18 00:36:54 +00:00
Walter Doekes 07d3705b42 Check result of ast_var_assign() calls for memory allocation failure (2).
Missed a spot in the previous commit.
........

Merged revisions 396310 from http://svn.asterisk.org/svn/asterisk/branches/11


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@396311 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-08-06 08:43:22 +00:00
Walter Doekes ccdfe67bf2 Check result of ast_var_assign() calls for memory allocation failure.
We try to keep the system running even when all available memory is
spent.

Review: https://reviewboard.asterisk.org/r/2734/
........

Merged revisions 396279 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 396287 from http://svn.asterisk.org/svn/asterisk/branches/11


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@396309 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-08-06 08:36:15 +00:00
Matthew Jordan a3592db1fb Clarify documentation for function PASSTHRU
It is not apparent to the average user that the PASSTHRU function should not
be passed as ${PASSTHRU(string)} but just as PASSTHRU(string) to functions
which take a variable name and not its contents.

This patch clarifies the behavior in the documentation and provides an example.

(closes issue ASTERISK-21717)
Reported by: Richard Miller
patches:
  func_strings.diff uploaded by Richard Miller (license 5685)
........

Merged revisions 394302 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 394303 from http://svn.asterisk.org/svn/asterisk/branches/11


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@394304 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-07-14 02:00:02 +00:00
Mark Michelson da85f8489f Make evaluation of channel variables consistently case-sensitive.
Due to inconsistencies in how variable names were evaluated, the
decision was made to make all evaluations case-sensitive. See the
UPGRADE.txt file or https://wiki.asterisk.org/wiki/display/AST/Case+Sensitivity
for more details.

(closes issue ASTERISK-20163)
reported by Matt Jordan

Review: https://reviewboard.asterisk.org/r/2160


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@375442 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-29 21:27:09 +00:00
Kinsey Moore 9b16c8b0f6 Clean up and ensure proper usage of alloca()
This replaces all calls to alloca() with ast_alloca() which calls gcc's
__builtin_alloca() to avoid BSD semantics and removes all NULL checks
on memory allocated via ast_alloca() and ast_strdupa().

(closes issue ASTERISK-20125)
Review: https://reviewboard.asterisk.org/r/2032/
Patch-by: Walter Doekes (wdoekes)
........

Merged revisions 370642 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 370643 from http://svn.asterisk.org/svn/asterisk/branches/10


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@370655 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-07-31 20:21:43 +00:00
Kinsey Moore a485f44022 Add missing newlines to CLI logging
........

Merged revisions 361471 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 361472 from http://svn.asterisk.org/svn/asterisk/branches/10


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@361476 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-04-06 18:19:03 +00:00
Terry Wilson a9d607a357 Opaquify ast_channel structs and lists
Review: https://reviewboard.asterisk.org/r/1773/


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@357542 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-02-29 16:52:47 +00:00
Walter Doekes db24fc2523 Avoid cppcheck warnings; removing unused vars and a bit of cleanup.
Patch by: Clod Patry
Review: https://reviewboard.asterisk.org/r/1651


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@354429 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-02-08 20:49:48 +00:00
Richard Mudgett 1313c12847 Merged revisions 337119 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/10

........
  r337119 | rmudgett | 2011-09-20 17:47:45 -0500 (Tue, 20 Sep 2011) | 16 lines
  
  Fix crash with STRREPLACE function.
  
  The ast_func_read() function calls the .read2 callback with the len
  parameter set to zero indicating no size restrictions on the supplied
  ast_str buffer.  The value was used to dimension a local starts[] array
  with the array subsequently used.
  
  * Reworked the strreplace() function to perform the string replacement in
  a straight forward manner.  Eliminated the need for the starts[] array.
  
  (closes issue ASTERISK-18545)
  Reported by: Federico Alves
  Patches:
        jira_asterisk_18545_v10.patch (license #5621) patch uploaded by rmudgett
  Tested by: rmudgett, Federico Alves
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@337123 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-09-20 22:54:21 +00:00
Tilghman Lesher 8c06ce6cc9 Merged revisions 336789 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/10

........
  r336789 | tilghman | 2011-09-19 16:41:16 -0500 (Mon, 19 Sep 2011) | 2 lines
  
  Ensure substring will not be found in the previous match.
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@336790 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-09-19 21:42:11 +00:00
Leif Madsen a525edea59 Merged revisions 328247 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.10

................
  r328247 | lmadsen | 2011-07-14 16:25:31 -0400 (Thu, 14 Jul 2011) | 14 lines
  
  Merged revisions 328209 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.8
  
  ........
    r328209 | lmadsen | 2011-07-14 16:13:06 -0400 (Thu, 14 Jul 2011) | 6 lines
    
    Introduce <support_level> tags in MODULEINFO.
    This change introduces MODULEINFO into many modules in Asterisk in order to show
    the community support level for those modules. This is used by changes committed
    to menuselect by Russell Bryant recently (r917 in menuselect). More information about
    the support level types and what they mean is available on the wiki at
    https://wiki.asterisk.org/wiki/display/AST/Asterisk+Module+Support+States
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@328259 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-07-14 20:28:54 +00:00
Jonathan Rose 1b57da8673 Adds STRREPLACE function
Adds a new STRREPLACe function to func_strings.c that allows users to search and replace
against a variable in the dialplan.

(closes issue #18023)
Reported by: wdoekes

Review: https://reviewboard.asterisk.org/r/1219/ 


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@320040 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-05-20 16:27:12 +00:00
Jeff Peeler 34c30c8ad3 Merged revisions 293159 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.8

................
  r293159 | jpeeler | 2010-10-28 11:11:08 -0500 (Thu, 28 Oct 2010) | 18 lines
  
  Merged revisions 293158 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.6.2
  
  ........
    r293158 | jpeeler | 2010-10-28 11:09:40 -0500 (Thu, 28 Oct 2010) | 11 lines
    
    Fix infinite loop in FILTER(). 
    
    Specifically when you're using characters above \x7f or invalid character
    escapes (e.g. \xgg).
    
    (closes issue #18060)
    Reported by: wdoekes
    Patches: 
          issue18060_func_strings_filter_infinite_loop.patch uploaded by wdoekes (license 717)
    Tested by: wdoekes
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@293160 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-10-28 16:11:53 +00:00
Tilghman Lesher 794ff358a3 Merged revisions 288713 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.8

................
  r288713 | tilghman | 2010-09-24 08:54:17 -0500 (Fri, 24 Sep 2010) | 12 lines
  
  Merged revisions 288712 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.6.2
  
  ........
    r288712 | tilghman | 2010-09-24 08:53:30 -0500 (Fri, 24 Sep 2010) | 5 lines
    
    Solaris won't printf a NULL.
    
    (closes issue #18041)
     Reported by: asgaroth
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@288714 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-09-24 13:55:11 +00:00
Tilghman Lesher 42490d744b Merged revisions 280809 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.8

........
  r280809 | tilghman | 2010-08-03 15:25:10 -0500 (Tue, 03 Aug 2010) | 12 lines
  
  Sneak FIELDNUM() into 1.8.  Returns a 1-based index into a list of a specified item.
  
  Matches up with FIELDQTY() and CUT().
  
  (closes issue #17713)
   Reported by: gareth
   Patches: 
         svn-279754.diff uploaded by gareth (license 208)
   Tested by: gareth, tilghman
  
   Review: https://reviewboard.asterisk.org/r/810/
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@280810 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-08-03 20:29:51 +00:00
Tilghman Lesher da8450323f Kill some startup warnings and errors and make some messages more helpful in tracking down the source.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@275105 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-07-09 17:00:22 +00:00
Russell Bryant 008930a3f2 Fix memory corruption found by unit tests.
ast_str_reset() was being called on a potentially uninitialized pointer.
Valgrind is my hero, once again.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@253579 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-20 16:50:38 +00:00
Tilghman Lesher afb6bac829 Hmmm, apparently needed to be fixed in trunk, too.
(closes issue #16900)
 Reported by: bluecrow76
 Patches: 
       asterisk-1.6.2.4-func_strings.diff uploaded by bluecrow76 (license 270)


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@251682 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-10 20:54:03 +00:00
Tilghman Lesher dd3176cc91 It's amazing what writing a test will find.
(issue #16900)
 Reported by: bluecrow76


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@251677 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-10 20:30:34 +00:00
Russell Bryant e3d176d0d3 Remove unnecessary warning message, make a couple of formatting tweaks
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@248534 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-02-24 06:39:27 +00:00
Tilghman Lesher 47f3850a1e Fussy compiler on another machine...
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@246204 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-02-10 21:24:10 +00:00
Tilghman Lesher 00b5520a6f Fix weird issue with unit tests on optimized build - turned out to be a signing issue.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@246200 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-02-10 21:19:35 +00:00
Tilghman Lesher eaea15aa02 Enable warnings on atypical conditions for the FILTER function (suggested by mmichelson on the -dev list).
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@246022 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-02-10 15:36:57 +00:00
Tilghman Lesher 5b86e43b30 Merged revisions 245944 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
  r245944 | tilghman | 2010-02-10 07:37:13 -0600 (Wed, 10 Feb 2010) | 2 lines
  
  Include examples of FILTER usage in extension patterns where a "." may be a risk.
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@245945 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-02-10 14:06:12 +00:00
Tilghman Lesher f6b5cf960f Make HASHes inheritable across channel creation.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@241012 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-01-18 19:26:07 +00:00
Tilghman Lesher 0bccc4fbe6 Add REPLACE & PASSTHRU functions, overhaul of func_strings, fix API docs for the ast_get_encoded_* functions.
* Add REPLACE function, which searches a given variable for a set of
   characters and replaces each with a given character.
 * Add PASSTHRU function, which passes a literal string back, like a NoOp for
   functions.  Intent is to be able to specify a literal string to another
   function that takes a variable name as an argument.
 * Let the array manipulation functions work with dialplan functions, in
   addition to variables.  This allows the array manipulation functions to
   modify ASTDB and ODBC backends, assuming the func_odbc configuration has
   both read and write functions.
(closes issue #15223)
 Reported by: ajohnson
Patches: 
       20091112__issue15223.diff.txt uploaded by tilghman (license 14)
 Tested by: lmadsen, tilghman


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@230994 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-11-24 04:58:44 +00:00
Matthias Nick 63984d5c21 Merged revisions 221153,221157,221303 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
  r221153 | mnick | 2009-09-30 10:37:39 -0500 (Wed, 30 Sep 2009) | 2 lines
  
  check bounds - prevents for buffer overflow
........
  r221157 | mnick | 2009-09-30 10:41:46 -0500 (Wed, 30 Sep 2009) | 8 lines
  
  added a new dialplan function 'CSV_QUOTE' and changed the cdr_custom.sample.conf
  
  (closes issue #15471)
  Reported by: dkerr
  Patches:
        csv_quote_14.txt uploaded by mnick (license )
  Tested by: mnick
........
  r221303 | mnick | 2009-09-30 14:02:00 -0500 (Wed, 30 Sep 2009) | 2 lines
  
  changed the prototype definition of csv_quote
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@221368 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-09-30 19:42:36 +00:00
Tilghman Lesher 5484d2f5d0 Merged revisions 207945 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
  r207945 | tilghman | 2009-07-21 17:38:54 -0500 (Tue, 21 Jul 2009) | 8 lines
  
  Force an error if a blank is passed to QUOTE (because the documentation states the argument is not optional).
  This change makes URIENCODE and QUOTE behave similarly, since the documentation
  states that the argument is not optional, for both.
  (closes issue #15439)
   Reported by: pkempgen
   Patches: 
         20090706__issue15439.diff.txt uploaded by tilghman (license 14)
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@207946 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-07-21 22:45:32 +00:00
Tilghman Lesher ba6f16d55f Fix documentation for FIELDQTY.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@198470 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-05-31 17:52:28 +00:00
Kevin P. Fleming e6b2e9a750 Const-ify the world (or at least a good part of it)
This patch adds 'const' tags to a number of Asterisk APIs where they are appropriate (where the API already demanded that the function argument not be modified, but the compiler was not informed of that fact). The list includes:

- CLI command handlers
- CLI command handler arguments
- AGI command handlers
- AGI command handler arguments
- Dialplan application handler arguments
- Speech engine API function arguments

In addition, various file-scope and function-scope constant arrays got 'const' and/or 'static' qualifiers where they were missing.

Review: https://reviewboard.asterisk.org/r/251/



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@196072 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-05-21 21:13:09 +00:00
Tilghman Lesher a866a75900 Merge str_substitution branch.
This branch adds additional methods to dialplan functions, whereby the result
buffers are now dynamic buffers, which can be expanded to the size of any
result.  No longer are variable substitutions limited to 4095 bytes of data.
In addition, the common case of needing buffers much smaller than that will
enable substitution to only take up the amount of memory actually needed.
The existing variable substitution routines are still available, but users
of those API calls should transition to using the dynamic-buffer APIs.
Reviewboard: http://reviewboard.digium.com/r/174/


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@191140 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-29 18:53:01 +00:00
Terry Wilson 1ce1f1bb1f Fix example that could fail in certain circumstances
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@190154 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-23 00:44:18 +00:00
Terry Wilson 3fb648d8fa Add funcs for manipulating delimited lists in the dialplan
Adds PUSH and POP for appending to and retrieving/removing from the
end of a list and UNSHIFT and SHIFT for insert to and retrieiving/
removing from the beginning of a list.

Review: http://reviewboard.digium.com/r/230


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@190000 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-22 20:07:41 +00:00
Tilghman Lesher a2ddc0bb5e Don't increment the loop, now that incrementing is taken care of by the
decoder function.
(closes issue #14363)
 Reported by: andrew53
 Patches: 
       func_strings_filter.patch uploaded by andrew53 (license 519)


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@172706 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-01-31 16:40:59 +00:00
Tilghman Lesher c8223fc957 Merge ast_str_opaque branch (discontinue usage of ast_str internals)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@163991 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-12-13 08:36:35 +00:00