]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
Set the length of the ast_sockaddr, so that we can set it's port later.
authorSean Bright <sean@malleable.com>
Sun, 19 Feb 2012 17:50:29 +0000 (17:50 +0000)
committerSean Bright <sean@malleable.com>
Sun, 19 Feb 2012 17:50:29 +0000 (17:50 +0000)
Without this, the call to ast_sockaddr_set_port a few lines later is a noop.
........

Merged revisions 355901 from http://svn.asterisk.org/svn/asterisk/branches/1.8

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/10@355902 65c4cc65-6c06-0410-ace0-fbb531ad65f3

channels/chan_iax2.c

index 91e5830b27bb524002ad3928f4d5372834d735e1..6935d839f982c68c899dbeaab2e683638f42aa07 100644 (file)
@@ -12508,6 +12508,7 @@ static struct iax2_peer *build_peer(const char *name, struct ast_variable *v, st
                peer->pokeexpire = -1;
                peer->sockfd = defaultsockfd;
                peer->addr.ss.ss_family = AF_INET;
+               peer->addr.len = sizeof(struct sockaddr_in);
                if (ast_string_field_init(peer, 32))
                        peer = peer_unref(peer);
        }