mirror of
https://github.com/dlang/phobos.git
synced 2025-04-28 22:21:09 +03:00
Fix for 4251 - assumeUnique cannot receive in char[]
This commit is contained in:
parent
17e87a472d
commit
7f67f8d932
1 changed files with 2 additions and 2 deletions
|
@ -1051,7 +1051,7 @@ Address[] getAddress(in char[] hostname, ushort port)
|
|||
auto ih = new InternetHost;
|
||||
if (!ih.getHostByName(hostname))
|
||||
throw new AddressException(
|
||||
"Unable to resolve host '" ~ assumeUnique(hostname) ~ "'");
|
||||
text("Unable to resolve host '", hostname, "'"));
|
||||
|
||||
Address[] results;
|
||||
foreach (uint addr; ih.addrList)
|
||||
|
@ -1468,7 +1468,7 @@ public:
|
|||
if(!ih.getHostByName(addr))
|
||||
//throw new AddressException("Invalid internet address");
|
||||
throw new AddressException(
|
||||
"Unable to resolve host '" ~ assumeUnique(addr) ~ "'");
|
||||
text("Unable to resolve host '", addr, "'"));
|
||||
uiaddr = ih.addrList[0];
|
||||
}
|
||||
sin.sin_family = AddressFamily.INET;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue