From: Richard Mudgett Date: Tue, 14 Jun 2011 17:21:24 +0000 (+0000) Subject: Add more strict hostname checking to ast_dnsmgr_lookup(). X-Git-Tag: 1.8.5-rc1~11^2~35 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2b2aa6ba3e95d5fc8ecd602c3eb23f262b6771ce;p=thirdparty%2Fasterisk.git Add more strict hostname checking to ast_dnsmgr_lookup(). Change suggested in review. Review: https://reviewboard.asterisk.org/r/1240/ git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@323392 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/main/dnsmgr.c b/main/dnsmgr.c index 8e856d3516..8076b6f805 100644 --- a/main/dnsmgr.c +++ b/main/dnsmgr.c @@ -135,7 +135,7 @@ int ast_dnsmgr_lookup(const char *name, struct ast_sockaddr *result, struct ast_ * 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)) { + if (ast_sockaddr_parse(result, name, PARSE_PORT_FORBID)) { return 0; }