Skip to content

Commit 79e2007

Browse files
committed
Revert "Platform (Linux): use $HOSTNAME if available"
$HOSTNAME doesn't seem to be a standard variable This reverts commit 02eb604.
1 parent 02eb604 commit 79e2007

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

src/util/platform/FFPlatform_unix.c

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -150,10 +150,7 @@ static void getUserName(FFPlatform* platform, const struct passwd* pwd)
150150

151151
static void getHostName(FFPlatform* platform, const struct utsname* uts)
152152
{
153-
const char* hostname = getenv("HOSTNAME");
154-
if(!ffStrSet(hostname) && uts)
155-
hostname = uts->nodename;
156-
ffStrbufAppendS(&platform->hostName, hostname);
153+
ffStrbufAppendS(&platform->hostName, uts->nodename);
157154
}
158155

159156
static void getUserShell(FFPlatform* platform, const struct passwd* pwd)

0 commit comments

Comments
 (0)