mirror of
https://github.com/signalwire/freeswitch.git
synced 2025-03-13 12:40:17 +00:00
mod_commands: if no bind ip specified for stun fsapi command, use the guess ip.
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@13140 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
parent
d505cec790
commit
44baede5d6
@ -527,7 +527,7 @@ SWITCH_STANDARD_API(stun_function)
|
||||
char *stun_ip = NULL;
|
||||
switch_port_t stun_port = (switch_port_t)SWITCH_STUN_DEFAULT_PORT;
|
||||
char *p;
|
||||
char ip_buf[50] = "";
|
||||
char ip_buf[256] = "";
|
||||
char *ip = NULL;
|
||||
char *pip = NULL;
|
||||
switch_port_t port = 0;
|
||||
@ -560,6 +560,8 @@ SWITCH_STANDARD_API(stun_function)
|
||||
|
||||
if (pip) {
|
||||
switch_copy_string(ip_buf, pip, sizeof(ip_buf));
|
||||
} else {
|
||||
switch_find_local_ip(ip_buf, sizeof(ip_buf), AF_INET);
|
||||
}
|
||||
|
||||
switch_core_new_memory_pool(&pool);
|
||||
|
Loading…
x
Reference in New Issue
Block a user