Merged revisions 281687 via svnmerge from

https://origsvn.digium.com/svn/asterisk/branches/1.8

........
  r281687 | simon.perreault | 2010-08-11 09:30:59 -0400 (Wed, 11 Aug 2010) | 9 lines
  
  Fix parsing of IPv6 address literals in outboundproxy
  
  (closes issue #17757)
  Reported by: oej
  Patches:
        17757.diff uploaded by sperreault (license 252)
        sip.conf.diff uploaded by sperreault (license 252)
  Tested by: oej
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@281688 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
2010-08-11 13:31:39 +00:00
parent 1990c4347e
commit a491cac965
4 changed files with 34 additions and 8 deletions

View File

@@ -229,6 +229,26 @@ static inline char *ast_sockaddr_stringify_port(const struct ast_sockaddr *addr)
return ast_sockaddr_stringify_fmt(addr, AST_SOCKADDR_STR_PORT);
}
/*!
* \since 1.8
*
* \brief
* Splits a string into its host and port components
*
* \param str[in] The string to parse. May be modified by writing a NUL at the end of
* the host part.
* \param host[out] Pointer to the host component within \a str.
* \param port[out] Pointer to the port component within \a str.
* \param flags If set to zero, a port MAY be present. If set to PARSE_PORT_IGNORE, a
* port MAY be present but will be ignored. If set to PARSE_PORT_REQUIRE,
* a port MUST be present. If set to PARSE_PORT_FORBID, a port MUST NOT
* be present.
*
* \retval 1 Success
* \retval 0 Failure
*/
int ast_sockaddr_split_hostport(char *str, char **host, char **port, int flags);
/*!
* \since 1.8
*