YPCLNT(3) BSD Library Functions Manual YPCLNT(3)
NAME
yp_all, yp_bind, yp_first, yp_get_default_domain, yp_master, yp_match, yp_next, yp_order, yp_unbind, yperr_string, ypprot_err -- Interface to
the YP subsystem
LIBRARY
Standard C Library (libc, -lc)
SYNOPSIS
#include <sys/types.h>
#include <rpc/rpc.h>
#include <rpcsvc/ypclnt.h>
#include <rpcsvc/yp_prot.h>
int
yp_all(const char *indomain, const char *inmap, struct ypall_callback *incallback);
int
yp_bind(const char *dom);
int
yp_first(const char *indomain, const char *inmap, char **outkey, int *outkeylen, char **outval, int *outvallen);
int
yp_get_default_domain(char **outdomain);
int
yp_master(const char *indomain, const char *inmap, char **outname);
int
yp_match(const char *indomain, const char *inmap, const char *inkey, int inkeylen, char **outval, int *outvallen);
int
yp_next(const char *indomain, const char *inmap, const char *inkey, int inkeylen, char **outkey, int *outkeylen, char **outval,
int *outvallen);
int
yp_order(const char *indomain, const char *inmap, int *outorder);
void
yp_unbind(const char *dom);
char *
yperr_string(int incode);
int
ypprot_err(unsigned int incode);
DESCRIPTION
The ypclnt suite provides an interface to the YP subsystem. For a general description of the YP subsystem, see yp(8).
For all functions, input values begin with in and output values begin with out.
Any output values of type char ** should be the addresses of uninitialized character pointers. These values will be reset to the null
pointer (unless the address itself is the null pointer, in which case the error YPERR_BADARGS will be returned). If necessary, memory will
be allocated by the YP client routines using malloc(), and the result will be stored in the appropriate output value. If the invocation of a
YP client routine doesn't return an error, and an output value is not the null pointer, then this memory should be freed by the user when
there is no additional need for the data stored there. For outkey and outval, two extra bytes of memory are allocated for a '
' and '