parent
2c37a7450b
commit
aca672416c
|
@ -733,10 +733,10 @@ private string hostName()
|
||||||
string hostName;
|
string hostName;
|
||||||
|
|
||||||
version (Posix) {
|
version (Posix) {
|
||||||
import core.sys.posix.sys.utsname;
|
import core.sys.posix.sys.utsname : uname, utsname;
|
||||||
utsname name;
|
utsname name;
|
||||||
if (uname(&name)) return hostName;
|
if (uname(&name)) return hostName;
|
||||||
hostName = name.nodename.to!string();
|
hostName = name.nodename.ptr.to!string;
|
||||||
|
|
||||||
import std.socket;
|
import std.socket;
|
||||||
auto ih = new InternetHost;
|
auto ih = new InternetHost;
|
||||||
|
|
Loading…
Reference in a new issue