summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenny Prijono <bennylp@teluu.com>2008-08-28 10:44:46 +0000
committerBenny Prijono <bennylp@teluu.com>2008-08-28 10:44:46 +0000
commit44713297a9609e7834819b986ec5c66998d2b35c (patch)
treeca871e353232ae2755cc08b5b5d5095f012278c8
parent6306133a89d163c30a07852b2877732699bdac6e (diff)
Print warning instead of assert when Speex AEC is instantiated with multichannels
git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@2252 74dad513-b988-da41-8d7b-12977e46ad98
-rw-r--r--pjmedia/src/pjmedia/echo_speex.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/pjmedia/src/pjmedia/echo_speex.c b/pjmedia/src/pjmedia/echo_speex.c
index 033597e8..96bd8c9c 100644
--- a/pjmedia/src/pjmedia/echo_speex.c
+++ b/pjmedia/src/pjmedia/echo_speex.c
@@ -20,6 +20,7 @@
#include <pjmedia/echo.h>
#include <pjmedia/errno.h>
#include <pj/assert.h>
+#include <pj/log.h>
#include <pj/pool.h>
#include <speex/speex_echo.h>
#include <speex/speex_preprocess.h>
@@ -66,7 +67,10 @@ PJ_DEF(pj_status_t) speex_aec_create(pj_pool_t *pool,
clock_rate * tail_ms / 1000,
channel_count, channel_count);
#else
- PJ_ASSERT_RETURN(channel_count==1, PJ_EINVAL);
+ if (channel_count != 1) {
+ PJ_LOG(2,("echo_speex.c", "Multichannel EC is not supported by this "
+ "echo canceller. It may not work."));
+ }
echo->state = speex_echo_state_init(echo->samples_per_frame,
clock_rate * tail_ms / 1000);
#endif