Ensure that we do not exceed the hold's maximum size with a single frame.

(closes issue #12047)
Reported by: fabianoheringer
Tested by: fabianoheringer


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@112125 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Joshua Colp
2008-04-01 16:45:14 +00:00
parent 9ae694024e
commit 214973a574
2 changed files with 6 additions and 1 deletions

View File

@@ -31,10 +31,12 @@
extern "C" {
#endif
#define AST_SLINFACTORY_MAX_HOLD 1280
struct ast_slinfactory {
AST_LIST_HEAD_NOLOCK(, ast_frame) queue;
struct ast_trans_pvt *trans;
short hold[1280];
short hold[AST_SLINFACTORY_MAX_HOLD];
short *offset;
size_t holdlen; /*!< in samples */
unsigned int size; /*!< in samples */