Always set 'homehost' if not specified.

The default for 'homehost' is now '<system>' rather than
unspecified.
This commit is contained in:
NeilBrown 2008-11-04 20:50:38 +11:00
parent cf8de6913b
commit 9180c81bd7
1 changed files with 1 additions and 1 deletions

View File

@ -997,7 +997,7 @@ int main(int argc, char *argv[])
if (homehost == NULL)
homehost = conf_get_homehost();
if (homehost && strcmp(homehost, "<system>")==0) {
if (homehost == NULL || strcmp(homehost, "<system>")==0) {
if (gethostname(sys_hostname, sizeof(sys_hostname)) == 0) {
sys_hostname[sizeof(sys_hostname)-1] = 0;
homehost = sys_hostname;