Deleted Added
full compact
ncp_rcfile.h (52153) ncp_rcfile.h (52704)
1/*
2 * Copyright (c) 1999, Boris Popov
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 15 unchanged lines hidden (view full) ---

24 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
25 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
26 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
27 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
28 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
29 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
30 * SUCH DAMAGE.
31 *
1/*
2 * Copyright (c) 1999, Boris Popov
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 15 unchanged lines hidden (view full) ---

24 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
25 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
26 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
27 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
28 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
29 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
30 * SUCH DAMAGE.
31 *
32 * $FreeBSD: head/sys/netncp/ncp_rcfile.h 52153 1999-10-12 11:56:41Z bp $
32 * $FreeBSD: head/sys/netncp/ncp_rcfile.h 52704 1999-10-31 03:39:03Z bp $
33 */
33 */
34#ifndef _NCP_RCFILE_H_
35#define _NCP_RCFILE_H_
34#ifndef _NETNCP_NCP_RCFILE_H_
35#define _NETNCP_NCP_RCFILE_H_
36#include <sys/queue.h>
37
38struct rckey {
39 SLIST_ENTRY(rckey) rk_next;
40 char *rk_name;
41 char *rk_value;
42};
43

--- 5 unchanged lines hidden (view full) ---

49
50struct rcfile {
51 SLIST_ENTRY(rcfile) rf_next;
52 SLIST_HEAD(rcsec_head, rcsection) rf_sect;
53 char *rf_name;
54 FILE *rf_f;
55};
56
36#include <sys/queue.h>
37
38struct rckey {
39 SLIST_ENTRY(rckey) rk_next;
40 char *rk_name;
41 char *rk_value;
42};
43

--- 5 unchanged lines hidden (view full) ---

49
50struct rcfile {
51 SLIST_ENTRY(rcfile) rf_next;
52 SLIST_HEAD(rcsec_head, rcsection) rf_sect;
53 char *rf_name;
54 FILE *rf_f;
55};
56
57int rc_open(char *filename,char *mode,struct rcfile **rcfile);
58int rc_close(struct rcfile *rcp);
59int rc_getstringptr(struct rcfile *rcp,char *section, char *key,char **dest);
60int rc_getstring(struct rcfile *rcp,char *section, char *key,int maxlen,char *dest);
61int rc_getint(struct rcfile *rcp,char *section, char *key,int *value);
62int rc_getbool(struct rcfile *rcp,char *section, char *key,int *value);
57__BEGIN_DECLS
63
58
64#endif /* _NCP_RCFILE_H_ */
59int rc_open(char *, char *,struct rcfile **);
60int rc_close(struct rcfile *);
61int rc_getstringptr(struct rcfile *, char *, char *, char **);
62int rc_getstring(struct rcfile *, char *, char *, int, char *);
63int rc_getint(struct rcfile *, char *, char *, int *);
64int rc_getbool(struct rcfile *, char *, char *, int *);
65
66__END_DECLS
67
68#endif /* _NETNCP_NCP_RCFILE_H_ */