diff options
author | wpaul <wpaul@FreeBSD.org> | 1996-05-31 16:01:51 +0000 |
---|---|---|
committer | wpaul <wpaul@FreeBSD.org> | 1996-05-31 16:01:51 +0000 |
commit | 7db7b1cde125e2f1b07ce515a44386287ffe20e3 (patch) | |
tree | 09d1229ceb91ce3fd14b2705728d76c9b2ed0f9f /usr.sbin/ypserv/yp_server.c | |
parent | d4c70b6e6444ede1b94fe2e860bc791d28cd0604 (diff) | |
download | FreeBSD-src-7db7b1cde125e2f1b07ce515a44386287ffe20e3.zip FreeBSD-src-7db7b1cde125e2f1b07ce515a44386287ffe20e3.tar.gz |
Small touch-ups -- no functional changes.
Fix some comments to reflect reality (in some cases I made changes
to code but not to the comments).
Change some instances of 'inline' to '__inline' to pacify
gcc -ansi -pedantic.
Use rcsid strings more consistently.
Make 'oldaddr' static in yp_access().
Use strcpy()/strcat() in yp_open_db_cache() instead of snprintf().
(Seems to be a little faster this way.)
Diffstat (limited to 'usr.sbin/ypserv/yp_server.c')
-rw-r--r-- | usr.sbin/ypserv/yp_server.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/usr.sbin/ypserv/yp_server.c b/usr.sbin/ypserv/yp_server.c index 27a1279..f32a983 100644 --- a/usr.sbin/ypserv/yp_server.c +++ b/usr.sbin/ypserv/yp_server.c @@ -45,7 +45,7 @@ #include <rpc/rpc.h> #ifndef lint -static char rcsid[] = "$Id: yp_server.c,v 1.5 1996/04/26 04:35:53 wpaul Exp wpaul $"; +static const char rcsid[] = "$Id: yp_server.c,v 1.9 1996/04/28 04:38:52 wpaul Exp $"; #endif /* not lint */ int forked = 0; @@ -54,10 +54,6 @@ DB *spec_dbp = NULL; /* Special global DB handle for ypproc_all. */ char *master_string = "YP_MASTER_NAME"; char *order_string = "YP_LAST_MODIFIED"; -#define YP_ALL_TIMEOUT 10 - -static int yp_all_timed_out = 0; - /* * NIS v2 support. This is where most of the action happens. */ @@ -646,7 +642,7 @@ static struct ypmaplist *yp_maplist_create(domain) !S_ISREG(statbuf.st_mode)) continue; if ((cur = (struct ypmaplist *) - malloc(sizeof(struct ypmaplist))) < 0) { + malloc(sizeof(struct ypmaplist))) == NULL) { yp_error("malloc() failed: %s",strerror(errno)); closedir(dird); yp_maplist_free(yp_maplist); |