diff options
author | Benny Prijono <bennylp@teluu.com> | 2006-04-29 08:31:09 +0000 |
---|---|---|
committer | Benny Prijono <bennylp@teluu.com> | 2006-04-29 08:31:09 +0000 |
commit | f58301dc3d3da0e92ac077618730f628416546cb (patch) | |
tree | 6cf25fd834a6df6a2b452df335f3fd57e488b274 /pjsip/src/pjsua-lib/pjsua_call.c | |
parent | facbd77aee687ac9d282597e415bab3d0df8d181 (diff) |
Improve codec handling in pjsua cmd-line options, and add URI to call
git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@422 74dad513-b988-da41-8d7b-12977e46ad98
Diffstat (limited to 'pjsip/src/pjsua-lib/pjsua_call.c')
-rw-r--r-- | pjsip/src/pjsua-lib/pjsua_call.c | 20 |
1 files changed, 12 insertions, 8 deletions
diff --git a/pjsip/src/pjsua-lib/pjsua_call.c b/pjsip/src/pjsua-lib/pjsua_call.c index b5e32780..b8fff57f 100644 --- a/pjsip/src/pjsua-lib/pjsua_call.c +++ b/pjsip/src/pjsua-lib/pjsua_call.c @@ -1047,13 +1047,14 @@ static void pjsua_call_on_media_update(pjsip_inv_session *inv, pjmedia_conf_connect_port( pjsua.mconf, pjsua.wav_slot, call->conf_slot, 0); - } else if (pjsua.auto_loop && call->inv->role == PJSIP_ROLE_UAS) { + } + if (pjsua.auto_loop && call->inv->role == PJSIP_ROLE_UAS) { pjmedia_conf_connect_port( pjsua.mconf, call->conf_slot, call->conf_slot, 0); - } else if (pjsua.auto_conf) { - + } + if (pjsua.auto_conf) { int i; pjmedia_conf_connect_port( pjsua.mconf, 0, call->conf_slot, 0); @@ -1070,11 +1071,14 @@ static void pjsua_call_on_media_update(pjsip_inv_session *inv, call->conf_slot, 0); } - } else { - - /* Connect new call to the sound device port (port zero) in the - * main conference bridge. - */ + } + + /* Normal operation: if no auto_xx is given, connect new call to + * the sound device port (port zero) in the main conference bridge. + */ + if (pjsua.auto_play == 0 && pjsua.auto_loop == 0 && + pjsua.auto_conf == 0) + { pjmedia_conf_connect_port( pjsua.mconf, 0, call->conf_slot, 0); pjmedia_conf_connect_port( pjsua.mconf, call->conf_slot, 0, 0); } |