]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
update
authorAnthony Minessale <anthony.minessale@gmail.com>
Tue, 6 Jun 2006 16:22:08 +0000 (16:22 +0000)
committerAnthony Minessale <anthony.minessale@gmail.com>
Tue, 6 Jun 2006 16:22:08 +0000 (16:22 +0000)
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@1548 d0543943-73ff-0310-b7d9-9358b9ac24b2

conf/freeswitch.xml
src/mod/endpoints/mod_exosip/mod_exosip.c
src/mod/languages/mod_perl/switch_swig.c

index 90974fe7c92d5cdc89f178a29b17758af3473ee9..9ec6fa2da5bb67ff83362e0a9ac113e7b9840bd4 100644 (file)
         <param name="rfc2833-pt" value="101"/>
        <!-- disable to trade async for more calls -->
        <param name="use-rtp-timer" value="true"/>
+       <!-- auto sense NAT issues and adjust accordingly -->
+       <param name="use-rtp-auto-adjust" value="true"/>
         <!-- pick one (default if not specified is 'guess'); -->
         <param name="rtp-ip" value="guess"/>
         <!-- <param name-"rtp-ip" value="10.0.0.1"/> -->
index efc0af9dafe63630bc5ae84d164904d7a2c86d5b..a5c7de602842f6659f586780062ea5f2deafa968 100644 (file)
@@ -76,7 +76,8 @@ typedef enum {
        TFLAG_VAD_IN = ( 1 << 12),
        TFLAG_VAD_OUT = ( 1 << 13),
        TFLAG_VAD = ( 1 << 14),
-       TFLAG_TIMER = ( 1 << 15)
+       TFLAG_TIMER = ( 1 << 15),
+       TFLAG_AA = (1 << 16)
 } TFLAGS;
 
 
@@ -539,6 +540,10 @@ static switch_status_t activate_rtp(struct private_object *tech_pvt)
                flags |= SWITCH_RTP_FLAG_USE_TIMER;
        }
 
+       if (switch_test_flag(tech_pvt, TFLAG_AA)) {
+               flags |= SWITCH_RTP_FLAG_AUTOADJ;
+       }
+
        tech_pvt->rtp_session = switch_rtp_new(tech_pvt->local_sdp_audio_ip,
                                               tech_pvt->local_sdp_audio_port,
                                               tech_pvt->remote_sdp_audio_ip,
@@ -1933,6 +1938,8 @@ static int config_exosip(int reload)
                                globals.debug = atoi(val);
                        } else if (!strcmp(var, "use-rtp-timer") && switch_true(val)) {
                                  switch_set_flag(&globals, TFLAG_TIMER);
+                       } else if (!strcmp(var, "use-rtp-auto-adjust") && switch_true(val)) {
+                                 switch_set_flag(&globals, TFLAG_AA);
                        } else if (!strcmp(var, "port")) {
                                globals.port = atoi(val);
                        } else if (!strcmp(var, "rfc2833-pt")) {
index 1c4b458e65d125f2b39771a6ea0c5748956700f1..754bdcabf4a977a8ce091bed9c8dbc9aaa5702aa 100644 (file)
@@ -18,12 +18,13 @@ void fs_core_set_globals(void)
 int fs_core_init(char *path)
 {
        switch_status_t status;
+       const char *err = NULL;
 
        if (switch_strlen_zero(path)) {
                path = NULL;
        }
 
-       status = switch_core_init(path);
+       status = switch_core_init(path, &err);
 
        return status == SWITCH_STATUS_SUCCESS ? 1 : 0;
 }