Revert r328492:

"Fix gcc80 -Wsizeof-pointer-memaccess warning."

The warning is bogus: GCC8 only looks at the size of the destination.
We shouldn't be fixing imaginary problems, so perhaps its better to deal
with this later on by disabling such warnings.

Pointed out by:	ed, bde
This commit is contained in:
Pedro F. Giffuni 2018-01-28 03:16:54 +00:00
parent 1dff72eb82
commit a645f2a50a

View File

@ -135,7 +135,8 @@ int opieinsecure FUNCTION_NOARGS
char host[sizeof(utmp.ut_host) + 1];
insecure = 1;
strncpy(host, utmp.ut_host, sizeof(host));
strncpy(host, utmp.ut_host, sizeof(utmp.ut_host));
host[sizeof(utmp.ut_host)] = 0;
if (s = strchr(host, ':')) {
int n = s - host;