diff options
author | brooks <brooks@FreeBSD.org> | 2006-08-30 15:14:00 +0000 |
---|---|---|
committer | brooks <brooks@FreeBSD.org> | 2006-08-30 15:14:00 +0000 |
commit | a06320cbe1f01dc7ab687807afa089a48de92136 (patch) | |
tree | d5dc6a8357f967be1aa3f32ea888303fde568c7d /usr.sbin/sysinstall/config.c | |
parent | 4c70accca4d8f2bb84cda7c58cafe529f3a3c0f2 (diff) | |
download | FreeBSD-src-a06320cbe1f01dc7ab687807afa089a48de92136.zip FreeBSD-src-a06320cbe1f01dc7ab687807afa089a48de92136.tar.gz |
When generating localhost entries in /etc/hosts, put localhost before
localhost.domain so that naive users of gethost* think 1:: and 127.0.0.1
are "localhost" which is what the user expects. This also matches the
sample hosts file in src/etc/hosts.
Diffstat (limited to 'usr.sbin/sysinstall/config.c')
-rw-r--r-- | usr.sbin/sysinstall/config.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.sbin/sysinstall/config.c b/usr.sbin/sysinstall/config.c index ba8e1cd..850e9ba 100644 --- a/usr.sbin/sysinstall/config.c +++ b/usr.sbin/sysinstall/config.c @@ -636,8 +636,8 @@ skip: return DITEM_FAILURE; /* Add an entry for localhost */ if (dp) { - fprintf(fp, "::1\t\t\tlocalhost.%s localhost\n", dp); - fprintf(fp, "127.0.0.1\t\tlocalhost.%s localhost\n", dp); + fprintf(fp, "::1\t\t\tlocalhost localhost.%s\n", dp); + fprintf(fp, "127.0.0.1\t\tlocalhost localhost.%s\n", dp); } else { fprintf(fp, "::1\t\t\tlocalhost\n"); fprintf(fp, "127.0.0.1\t\tlocalhost\n"); |