From d8efa2902b83540504be0eb78ed5a74c8b28ad55 Mon Sep 17 00:00:00 2001 From: Benny Prijono Date: Sat, 22 Dec 2007 07:43:45 +0000 Subject: Fixed bug caused by ticket #427: frame type not properly initialized to PJMEDIA_FRAME_TYPE_AUDIO, causing audio frames to be dropped in the conference bridge (thanks P.J. Cast) git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@1637 74dad513-b988-da41-8d7b-12977e46ad98 --- pjmedia/src/pjmedia/conference.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'pjmedia') diff --git a/pjmedia/src/pjmedia/conference.c b/pjmedia/src/pjmedia/conference.c index ee655a42..abf7239a 100644 --- a/pjmedia/src/pjmedia/conference.c +++ b/pjmedia/src/pjmedia/conference.c @@ -1280,8 +1280,13 @@ static pj_status_t read_port( pjmedia_conf *conf, } else { - /* Initialize frame type to None */ - *type = PJMEDIA_FRAME_TYPE_NONE; + /* Initialize frame type */ + if (cport->rx_buf_count == 0) { + *type = PJMEDIA_FRAME_TYPE_NONE; + } else { + /* we got some samples in the buffer */ + *type = PJMEDIA_FRAME_TYPE_AUDIO; + } /* * If we don't have enough samples in rx_buf, read from the port -- cgit v1.2.3