diff --git a/main/dnsmgr.c b/main/dnsmgr.c index 23e1ab6ef645687406c75ec0155a7bd4eb336ffe..9002ec87fe7a5bc1a066e0011ec0b128f3ea796b 100644 --- a/main/dnsmgr.c +++ b/main/dnsmgr.c @@ -131,6 +131,14 @@ int ast_dnsmgr_lookup(const char *name, struct ast_sockaddr *result, struct ast_ return 0; } + /* + * If it's actually an IP address and not a name, there's no + * need for a managed lookup. + */ + if (ast_sockaddr_parse(result, name, 0)) { + return 0; + } + ast_verb(4, "doing dnsmgr_lookup for '%s'\n", name); /* do a lookup now but add a manager so it will automagically get updated in the background */