From: Thorsten Kukuk Date: Wed, 26 Nov 2003 10:12:18 +0000 (+0000) Subject: Relevant BUGIDs: 849541 X-Git-Tag: Linux-PAM-0-78-Beta1~23 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=9ebb94c98ea89a15d738d02f07ab5a63220e851b;p=linux-pam Relevant BUGIDs: 849541 Purpose of commit: cleanup Commit summary: --------------- pam_rhosts_auth.c included sys/fsuid.h twice on Linux and uses "#ifdef linux" instead the correct "#ifdef __linux__". --- diff --git a/modules/pam_rhosts/pam_rhosts_auth.c b/modules/pam_rhosts/pam_rhosts_auth.c index adaf16c9..95a1aad3 100644 --- a/modules/pam_rhosts/pam_rhosts_auth.c +++ b/modules/pam_rhosts/pam_rhosts_auth.c @@ -42,7 +42,7 @@ #define USER_RHOSTS_FILE "/.rhosts" /* prefixed by user's home dir */ -#ifdef linux +#ifdef __linux__ #include #endif @@ -74,13 +74,6 @@ int innetgr(const char *, const char *, const char *,const char *); #include #include -#ifdef linux -# include -# ifndef __USE_MISC -# define __USE_MISC -# include -# endif /* __USE_MISC */ -#endif #include #include @@ -522,7 +515,7 @@ pam_iruserok(pam_handle_t *pamh, */ /* We are root, this will not fail */ -#ifdef linux +#ifdef __linux__ /* If we are on linux the better way is setfsuid */ uid = setfsuid(pwd->pw_uid); hostf = fopen(pbuf, "r"); @@ -598,7 +591,7 @@ exit_function: * they are reset before we exit. */ -#ifdef linux +#ifdef __linux__ setfsuid(uid); #else (void)seteuid(uid);