install C version of _doprnt
[unix-history] / usr / src / lib / libc / net / sethostent.c
CommitLineData
a300ef85
JB
1/*
2 * Copyright (c) 1985 Regents of the University of California.
fcd6ac95
KB
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms are permitted
6 * provided that this notice is preserved and that due credit is given
7 * to the University of California at Berkeley. The name of the University
8 * may not be used to endorse or promote products derived from this
9 * software without specific prior written permission. This software
10 * is provided ``as is'' without express or implied warranty.
a300ef85
JB
11 */
12
2ce81398 13#if defined(LIBC_SCCS) && !defined(lint)
fcd6ac95
KB
14static char sccsid[] = "@(#)sethostent.c 6.4 (Berkeley) %G%";
15#endif /* LIBC_SCCS and not lint */
a300ef85 16
c0f8e4ee
KD
17#include <sys/types.h>
18#include <arpa/nameser.h>
19#include <netinet/in.h>
20#include <resolv.h>
a300ef85 21
158ad942
JB
22sethostent(stayopen)
23{
c0f8e4ee
KD
24 if (stayopen)
25 _res.options |= RES_STAYOPEN | RES_USEVC;
158ad942 26}
a300ef85 27
c0f8e4ee
KD
28endhostent()
29{
30 _res.options &= ~(RES_STAYOPEN | RES_USEVC);
31 _res_close();
32}
158ad942
JB
33
34sethostfile(name)
35char *name;
36{
37#ifdef lint
38name = name;
39#endif
40}