/* RE_SID: @(%)/usr/dosnfs/shades_SCCS/unix/pcnfsd/v2/src/SCCS/s.pcnfsd_cache.c 1.1 91/09/03 12:45:14 SMI */
/*
**=====================================================================
** Copyright (c) 1986,1987,1988,1989,1990,1991 by Sun Microsystems, Inc.
** @(#)pcnfsd_cache.c 1.1 9/3/91
**=====================================================================
*/
/*
**=====================================================================
** I N C L U D E F I L E S E C T I O N *
** *
** If your port requires different include files, add a suitable *
** #define in the customization section, and make the inclusion or *
** exclusion of the files conditional on this. *
**=====================================================================
*/
#ifdef USER_CACHE
#define CACHE_SIZE 16 /* keep it small, as linear searches are done */
struct cache {
int cuid;
int cgid;
char cpw[32];
char cuname[10]; /* keep this even for machines with alignment
* problems */
} User_cache[CACHE_SIZE];
/*
**---------------------------------------------------------------------
** User cache support procedures
**---------------------------------------------------------------------
*/
int
check_cache(char *name, char *pw, int *p_uid, int *p_gid)
{
int i;
int c1, c2;