Chapter Contents

Previous

Next
getrpcent

getrpcent



Returns the rpcent Structure

Portability: UNIX compatible


SYNOPSIS
DESCRIPTION
RETURN VALUE
CAUTION
PORTABILITY
IMPLEMENTATION
RELATED FUNCTIONS


SYNOPSIS

#include <netdb.h>

struct rpcent *getrpcent(void);


DESCRIPTION

getrpcent returns a pointer to the rpcent structure, which is defined in <netdb.h> . The source of the data in this structure is the SUN RPC program numbers file, that is, a file with the same format as the /etc/rpc file on a UNIX operating system.

Refer to /etc/rpc for information on the logic used to determine the location of the protocols file.


RETURN VALUE

If getrpcent succeeds, it returns a pointer to the rpcent structure. A null pointer indicates an error occurred or there were no more network entries.


CAUTION

The value that getrpcent returns points to a static structure within the library. You must copy the information from this structure before you make further getrpcbyname , getrpcbynumber , or getrpcent calls.


PORTABILITY

getrpcent is portable to other systems that support Sun RPC 4.0.


IMPLEMENTATION

This function is built from the Sun RPC 4.0 distribution.


RELATED FUNCTIONS

endrpcent , getrpcbyname , getrpcbynumber , setrpcent


Chapter Contents

Previous

Next

Top of Page

Copyright © 2001 by SAS Institute Inc., Cary, NC, USA. All rights reserved.