diff options
author | mnicholson <mnicholson@f38db490-d61c-443f-a65b-d21fe96a405b> | 2009-11-30 21:36:53 +0000 |
---|---|---|
committer | mnicholson <mnicholson@f38db490-d61c-443f-a65b-d21fe96a405b> | 2009-11-30 21:36:53 +0000 |
commit | d4148c528889f30aa834b697d0b506f26ae0abea (patch) | |
tree | 153b541a4784d79fc30e978f6fdab7e6cacab6e4 /include | |
parent | 0427366c3b6eac4a8605848d9fdc604719889f41 (diff) |
Merged revisions 231688 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk
................
r231688 | mnicholson | 2009-11-30 15:31:55 -0600 (Mon, 30 Nov 2009) | 15 lines
Merged revisions 231614 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r231614 | mnicholson | 2009-11-30 15:11:44 -0600 (Mon, 30 Nov 2009) | 8 lines
Remove duplicate entries from voicemail format lists. This prevents app_voicemail from entering an infinite loop when the same format is specified twice in the format list.
(closes issue #15625)
Reported by: Shagg63
Tested by: mnicholson
Review: https://reviewboard.asterisk.org/r/429/
........
................
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.1@231690 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'include')
-rw-r--r-- | include/asterisk/file.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/include/asterisk/file.h b/include/asterisk/file.h index 43b32fd12..8def42ae5 100644 --- a/include/asterisk/file.h +++ b/include/asterisk/file.h @@ -40,6 +40,9 @@ extern "C" { struct ast_filestream; struct ast_format; +/*! The maximum number of formats we expect to see in a format string */ +#define AST_MAX_FORMATS 10 + /*! Convenient for waiting */ #define AST_DIGIT_ANY "0123456789#*ABCD" #define AST_DIGIT_ANYNUM "0123456789" @@ -325,6 +328,14 @@ int ast_file_init(void); #define AST_RESERVED_POINTERS 20 +/*! Remove duplicate formats from a format string. */ +/*! + * \param fmts a format string, this string will be modified + * \retval NULL error + * \return a pointer to the reduced format string, this is a pointer to fmts + */ +char *ast_format_str_reduce(char *fmts); + #if defined(__cplusplus) || defined(c_plusplus) } #endif |