diff options
author | Joshua Colp <jcolp@digium.com> | 2012-07-18 11:38:05 +0000 |
---|---|---|
committer | Joshua Colp <jcolp@digium.com> | 2012-07-18 11:38:05 +0000 |
commit | cbdb2dbb0e25f7ab23379b02467b055e263d345b (patch) | |
tree | 7056d4775f233cb0bebf533b5c4bafe2b2010e23 /include | |
parent | 9278b5e51efe8a4083e1ff32052cb383e6a171ca (diff) |
Fix a crash occurring as a result of excess stack usage.
This fix involves moving the allocation of some temporary codec structures to the heap and also reduces the number of maximum payloads to something more sane for both regular and low memory builds.
(closes issue ASTERISK-20140)
Reported by: jonnt
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@370171 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'include')
-rw-r--r-- | include/asterisk/rtp_engine.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/include/asterisk/rtp_engine.h b/include/asterisk/rtp_engine.h index 098530f19..bd47e42b1 100644 --- a/include/asterisk/rtp_engine.h +++ b/include/asterisk/rtp_engine.h @@ -76,7 +76,11 @@ extern "C" { #include "asterisk/res_srtp.h" /* Maximum number of payloads supported */ -#define AST_RTP_MAX_PT 256 +#if defined(LOW_MEMORY) +#define AST_RTP_MAX_PT 128 +#else +#define AST_RTP_MAX_PT 196 +#endif /* Maximum number of generations */ #define AST_RED_MAX_GENERATION 5 |