Index: channels/chan_sip.c =================================================================== --- channels/chan_sip.c (revision 112128) +++ channels/chan_sip.c (working copy) @@ -2539,7 +2539,7 @@ * is because we only have the IP address and the host field might be * set as a name (and the reverse PTR might not match). */ - if (var) { + if (var && sin) { for (tmp = var; tmp; tmp = tmp->next) { if (!strcasecmp(tmp->name, "host")) { struct hostent *hp;