]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
use portable switch_inet_ntop
authorAnthony Minessale <anthm@freeswitch.org>
Tue, 11 Feb 2014 22:31:21 +0000 (03:31 +0500)
committerAnthony Minessale <anthm@freeswitch.org>
Tue, 11 Feb 2014 22:31:34 +0000 (03:31 +0500)
src/mod/applications/mod_commands/mod_commands.c
src/mod/endpoints/mod_sofia/mod_sofia.c

index cb8b3a3cfcabcbe2f14e106c6a8c3d834094a9c0..a637cf98e9e390df00c95fe18307d00dc24578b4 100644 (file)
@@ -530,7 +530,7 @@ SWITCH_STANDARD_API(gethost_api_function)
 
                if (he) {
                        memcpy(&sa.sin_addr, he->h_addr, sizeof(struct in_addr));
-                       ip = inet_ntop(AF_INET, &sa.sin_addr, buf, sizeof(buf));
+                       ip = switch_inet_ntop(AF_INET, &sa.sin_addr, buf, sizeof(buf));
                        stream->write_function(stream, "%s", ip);
                        return SWITCH_STATUS_SUCCESS;
                }
index a74d7c06ea06751f76997c7a6041ccadb006305e..e230397b72ec205d66684d3f73b9922961a5b055 100644 (file)
@@ -5094,7 +5094,7 @@ static switch_call_cause_t sofia_outgoing_channel(switch_core_session_t *session
 
                                if (he) {
                                        memcpy(&sa.sin_addr, he->h_addr, sizeof(struct in_addr));
-                                       ip = inet_ntop(AF_INET, &sa.sin_addr, buf, sizeof(buf));
+                                       ip = switch_inet_ntop(AF_INET, &sa.sin_addr, buf, sizeof(buf));
                                        tmp = switch_string_replace(dest, host, ip);
 
                                        switch_channel_set_variable_printf(nchannel, "sip_route_uri", "sip:%s", tmp);