indentation code happier.
* netdb.h: Comment fix.
* configure.in, getrpcent.c: Use configure to the return types of setrpcent()
and getrpcent(). Also, check for struct rpcent in the system <netdb.h>, and
only define the structure in rpc/netdb.h if it's not in the system file.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@9019
dc483132-0cff-0310-8789-
dd5450dbe970
+Sat Aug 31 01:46:45 1996 Ken Raeburn <raeburn@cygnus.com>
+
+ * pmap_rmt.c (getbroadcastnets): Tweak conditional layout to make
+ emacs indentation code happier.
+
+ * netdb.h: Comment fix.
+
+ Tue Aug 6 18:52:47 1996 Marc Horowitz <marc@mit.edu>
+
+ * configure.in, getrpcent.c: Use configure to the return types of
+ setrpcent() and getrpcent(). Also, check for struct rpcent in the
+ system <netdb.h>, and only define the structure in rpc/netdb.h if
+ it's not in the system file.
+
Tue Aug 13 15:18:16 1996 Tom Yu <tlyu@mit.edu>
* getrpcent.c: Add PROTOTYPE and conditionalize function
SIZEOF_LONG=$ac_cv_sizeof_long
AC_SUBST(SIZEOF_LONG)
+AC_MSG_CHECKING([return type of setrpcent])
+AC_CACHE_VAL(k5_cv_type_setrpcent,
+[AC_TRY_COMPILE([#include <netdb.h>
+#ifdef __cplusplus
+extern "C"
+#endif
+extern void setrpcent();],
+[int i;], k5_cv_type_setrpcent=void, k5_cv_type_setrpcent=int)])dnl
+AC_MSG_RESULT($k5_cv_type_setrpcent)
+AC_DEFINE_UNQUOTED(SETRPCENT_TYPE, $k5_cv_type_setrpcent)
+dnl
+AC_MSG_CHECKING([return type of endrpcent])
+AC_CACHE_VAL(k5_cv_type_endrpcent,
+[AC_TRY_COMPILE([#include <netdb.h>
+#ifdef __cplusplus
+extern "C"
+#endif
+extern void endrpcent();],
+[int i;], k5_cv_type_endrpcent=void, k5_cv_type_endrpcent=int)])dnl
+AC_MSG_RESULT($k5_cv_type_endrpcent)
+AC_DEFINE_UNQUOTED(ENDRPCENT_TYPE, $k5_cv_type_endrpcent)
+
DECLARE_SYS_ERRLIST
V5_SHARED_LIB_OBJS
#include <string.h>
#include <sys/socket.h>
-/* setrpcent is declared as int-returning in netdb.h on hpux */
-/* setrpcent is declared as int-returning in rpc/rpcent.h on Solaris */
-#if !defined(hpux) && !(defined(sun) && defined(__svr4__))
-#define SETRPCENT_TYPE void
-#else
-#define SETRPCENT_TYPE int
-#endif
-
-/* endrpcent is declared as int-returning in netdb.h on hpux */
-#ifndef hpux
-#define ENDRPCENT_TYPE void
-#else
-#define ENDRPCENT_TYPE int
-#endif
-
/*
* Make sure we have a definition for PROTOTYPE.
*/
char **r_aliases; /* alias list */
int r_number; /* rpc program number */
};
-#endif /*STRUCT_RPCENT_ALREADY_PROVIDED*/
+#endif /*STRUCT_RPCENT_IN_RPC_NETDB_H*/
+
struct rpcent *getrpcbyname(), *getrpcbynumber(), *getrpcent();
#endif
#if 0 /* this is uuuuugly */
addrs[i++] = inet_makeaddr(inet_netof
#if defined(hpux) || (defined(sparc) && defined(__svr4__)) || defined(linux) || (defined(__osf__) && defined(__alpha__))
- (sin->sin_addr), INADDR_ANY);
+ (sin->sin_addr),
#else /* hpux or solaris */
- (sin->sin_addr.s_addr), INADDR_ANY);
+ (sin->sin_addr.s_addr),
#endif
+ INADDR_ANY);
#endif
} else {
addrs[i++] = ((struct sockaddr_in*)