summaryrefslogtreecommitdiff
path: root/utils/login.c
diff options
context:
space:
mode:
Diffstat (limited to 'utils/login.c')
-rw-r--r--utils/login.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/utils/login.c b/utils/login.c
index 13e1cfee..cf6de37b 100644
--- a/utils/login.c
+++ b/utils/login.c
@@ -190,13 +190,13 @@ add_utmp_entry (char *args, unsigned args_len, int inherit_host)
if (! host)
host = old_utmp->ut_host;
if (! addr)
- addr = old_utmp->ut_addr;
+ addr = old_utmp->ut_addr[0];
}
}
}
strncpy (utmp.ut_host, host ?: "", sizeof (utmp.ut_host));
- utmp.ut_addr = addr;
+ utmp.ut_addr[0] = addr;
login (&utmp);
}