diff --git a/ChangeLog b/ChangeLog index ca8803a6..c4405a3f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2008-01-01 Nicolas François + + * libmisc/limits.c, libmisc/obscure.c, src/login_nopam.c, + lib/pwauth.c: Avoid empty file when USE_PAM is set. + * src/login_nopam.c: Fix warnings: resolve_hostname takes and + returns a constant string. + 2008-01-01 Nicolas François * src/grpck.c: Split process_flags(), open_files(), and diff --git a/libmisc/limits.c b/libmisc/limits.c index 80c23f77..c211f58b 100644 --- a/libmisc/limits.c +++ b/libmisc/limits.c @@ -441,4 +441,6 @@ void setup_limits (const struct passwd *info) } } +#else /* !USE_PAM */ +extern int errno; /* warning: ANSI C forbids an empty source file */ #endif /* !USE_PAM */ diff --git a/libmisc/obscure.c b/libmisc/obscure.c index 27f15a75..1a931d42 100644 --- a/libmisc/obscure.c +++ b/libmisc/obscure.c @@ -289,4 +289,6 @@ int obscure (const char *old, const char *new, const struct passwd *pwdp) return 1; } +#else /* !USE_PAM */ +extern int errno; /* warning: ANSI C forbids an empty source file */ #endif /* !USE_PAM */ diff --git a/src/login_nopam.c b/src/login_nopam.c index 720a55e0..bc2f75d5 100644 --- a/src/login_nopam.c +++ b/src/login_nopam.c @@ -245,8 +245,8 @@ static int user_match (const char *tok, const char *string) return (NO); } -static char *resolve_hostname (string) -char *string; +static const char *resolve_hostname (string) +const char *string; { /* * Resolve hostname to numeric IP address, as suggested @@ -314,4 +314,6 @@ static int string_match (const char *tok, const char *string) return (NO); } +#else /* !USE_PAM */ +extern int errno; /* warning: ANSI C forbids an empty source file */ #endif /* !USE_PAM */