summaryrefslogtreecommitdiff
path: root/channels
diff options
context:
space:
mode:
authorMatthew Jordan <mjordan@digium.com>2013-11-05 21:17:30 +0000
committerMatthew Jordan <mjordan@digium.com>2013-11-05 21:17:30 +0000
commit029ce1e962602c96e6135206631207c4556219d7 (patch)
tree2f7d92ca14021a3637a0444a25983e6e161b29d6 /channels
parentf6bd22b0fd5846bdcfc6b01f480c9449e8bb364a (diff)
chan_sip: Use AST_AF* defined constant when calling ast_get_ip
While the structure passed to ast_get_ip should be set memset to 0, thus initializing the ss_family member to 0, explicitly setting it to AST_AF_UNSPEC is more portable. ........ Merged revisions 402507 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@402508 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'channels')
-rw-r--r--channels/chan_sip.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/channels/chan_sip.c b/channels/chan_sip.c
index d143dc138..3b21d9f37 100644
--- a/channels/chan_sip.c
+++ b/channels/chan_sip.c
@@ -30731,6 +30731,7 @@ static struct sip_peer *build_peer(const char *name, struct ast_variable *v, str
srvlookup = v->value;
}
} else if (!strcasecmp(v->name, "defaultip")) {
+ peer->defaddr.ss.ss_family = AST_AF_UNSPEC;
if (!ast_strlen_zero(v->value) && ast_get_ip(&peer->defaddr, v->value)) {
sip_unref_peer(peer, "sip_unref_peer: from build_peer defaultip");
return NULL;