in_tkt.c: Use HAVE_SETREUID and HAVE_SETRESUID to define setreuid properly
authorEzra Peisach <epeisach@mit.edu>
Thu, 18 May 1995 19:08:19 +0000 (19:08 +0000)
committerEzra Peisach <epeisach@mit.edu>
Thu, 18 May 1995 19:08:19 +0000 (19:08 +0000)
configure.in: Check for setreuid and setresuid

git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@5824 dc483132-0cff-0310-8789-dd5450dbe970

src/lib/krb4/ChangeLog
src/lib/krb4/configure.in
src/lib/krb4/in_tkt.c

index c59459df2a618faaa3eab3a234d6eff52c304725..e83a3f12564f7d711ac055208bf89d75299f0ccf 100644 (file)
@@ -1,3 +1,10 @@
+Thu May 18 14:43:51 1995  Ezra Peisach  <epeisach@kangaroo.mit.edu>
+
+       * in_tkt.c: Use HAVE_SETREUID and HAVE_SETRESUID to define 
+               setreuid properly.
+
+       * configure.in: Check for setreuid and setresuid
+
 Sun May  7 08:05:56 1995  Ezra Peisach  <epeisach@kangaroo.mit.edu>
 
        * mk_preauth.c: Add <string.h> and either <stdlib.h> or provide
index dd118adda18abd67bf4966e14ec2bf22b608646c..dd1efc350cebf0894d435e356b2f063076c56231 100644 (file)
@@ -43,6 +43,8 @@ else
        AC_DEFINE(BITS32)
 fi
 AC_FUNC_CHECK(strsave,AC_DEFINE(HAVE_STRSAVE))
+AC_FUNC_CHECK(setreuid,AC_DEFINE(HAVE_SETREUID))
+AC_FUNC_CHECK(setresuid,AC_DEFINE(HAVE_SETRESUID))
 ET_RULES
 SubdirLibraryRule([$(OBJS)])
 KRB_INCLUDE
index 4674f3116c3397e7877373255cc5980e45ac0dd9..419089c68599dfeb8fecdedc3799a30be8f4fe09 100644 (file)
@@ -31,11 +31,12 @@ extern int krb_debug;
  * success, or KFAILURE if something goes wrong.
  */
 
-#ifdef hpux
-/* should be HAS_RESUID */
+#ifndef HAVE_SETREUID
+#ifdef HAVE_SETRESUID
+/* for hpux */
 #define setreuid(r,e) setresuid(r,e,-1)
 #else
-#ifdef __svr4__
+/* for svr4 */
 #define setreuid(r,e) setuid(r)
 #endif
 #endif