version 1.12, 1999/01/31 20:46:12 |
version 1.13, 1999/09/16 11:45:45 |
Line 37 __RCSID("$NetBSD$"); |
|
Line 37 __RCSID("$NetBSD$"); |
|
#endif |
#endif |
|
|
#include "namespace.h" |
#include "namespace.h" |
|
|
|
#include <assert.h> |
#include <stdlib.h> |
#include <stdlib.h> |
#include <string.h> |
#include <string.h> |
#include <time.h> |
#include <time.h> |
|
|
#include <rpc/rpc.h> |
#include <rpc/rpc.h> |
#include <rpcsvc/yp_prot.h> |
#include <rpcsvc/yp_prot.h> |
#include <rpcsvc/ypclnt.h> |
#include <rpcsvc/ypclnt.h> |
Line 81 ypmatch_add(map, key, keylen, val, valle |
|
Line 84 ypmatch_add(map, key, keylen, val, valle |
|
struct ypmatch_ent *ep; |
struct ypmatch_ent *ep; |
time_t t; |
time_t t; |
|
|
|
_DIAGASSERT(map != NULL); |
|
_DIAGASSERT(key != NULL); |
|
_DIAGASSERT(val != NULL); |
|
|
(void)time(&t); |
(void)time(&t); |
|
|
for (ep = ypmc; ep; ep = ep->next) |
for (ep = ypmc; ep; ep = ep->next) |
Line 145 ypmatch_find(map, key, keylen, val, vall |
|
Line 152 ypmatch_find(map, key, keylen, val, vall |
|
struct ypmatch_ent *ep; |
struct ypmatch_ent *ep; |
time_t t; |
time_t t; |
|
|
|
_DIAGASSERT(map != NULL); |
|
_DIAGASSERT(key != NULL); |
|
_DIAGASSERT(val != NULL); |
|
|
if (ypmc == NULL) |
if (ypmc == NULL) |
return 0; |
return 0; |
|
|
Line 182 yp_match(indomain, inmap, inkey, inkeyle |
|
Line 193 yp_match(indomain, inmap, inkey, inkeyle |
|
struct ypreq_key yprk; |
struct ypreq_key yprk; |
int r, nerrs = 0; |
int r, nerrs = 0; |
|
|
if (outval == NULL) |
if (outval == NULL || outvallen == NULL) |
return YPERR_BADARGS; |
return YPERR_BADARGS; |
*outval = NULL; |
*outval = NULL; |
*outvallen = 0; |
*outvallen = 0; |