Opens and rewinds the network services database file.
Format
#include <netdb.h>
void setservent (int stay_open);
Arguments
- stay_open
- Specifies a value used to indicate when to close the network
services database file:
- 0 (zero) to close the network services database file after
each call to the getservent routine.
- nonzero to keep the network services database file open
after each call to getservent.
Description
The setservent routine opens the network services database
file and resets the file marker to the beginning of the file.
Passing a nonzero value to the stay_open parameter keeps
the connection open until you call the endservent, or exit routine.
See also endservent, exit, and getservent in this section.
Previous Page | Next Page | Table of Contents | Index