]> sjero.net Git - linphone/blobdiff - coreapi/linphonecore.c
make sure only one transport is configured
[linphone] / coreapi / linphonecore.c
index 9c69fc88a1d7a1258d4288eb66d8d87be8fde4a8..40b2a647d933056c869c57f702ba1fe042879f64 100644 (file)
@@ -532,10 +532,13 @@ static void sip_config_read(LinphoneCore *lc)
        
        if (tr.udp_port>0 && random_port){
                tr.udp_port=random_port;
+               tr.tls_port=tr.tcp_port=0; /*make sure only one transport is active at a time*/
        }else if (tr.tcp_port>0 && random_port){
                tr.tcp_port=random_port;
+               tr.tls_port=tr.udp_port=0; /*make sure only one transport is active at a time*/
        }else if (tr.tls_port>0 && random_port){
                tr.tls_port=random_port;
+               tr.udp_port=tr.tcp_port=0; /*make sure only one transport is active at a time*/
        } 
 
 #ifdef __linux