]> CyberLeo.Net >> Repos - FreeBSD/releng/10.0.git/blob - usr.sbin/ndiscvt/inf.h
- Copy stable/10 (r259064) to releng/10.0 as part of the
[FreeBSD/releng/10.0.git] / usr.sbin / ndiscvt / inf.h
1 /*
2  * $Id: inf.h,v 1.3 2003/11/30 21:58:16 winter Exp $
3  *
4  * $FreeBSD$
5  */
6
7 #define W_MAX   16
8
9 struct section {
10         const char *    name;
11
12         TAILQ_ENTRY(section)    link;
13 };
14 TAILQ_HEAD(section_head, section);
15
16 struct assign {
17         struct section  *section;
18
19         const char *    key;
20         const char *    vals[W_MAX];
21
22         TAILQ_ENTRY(assign)     link;
23 };
24 TAILQ_HEAD(assign_head, assign);
25
26 struct reg {
27         struct section *section;
28
29         const char *    root;
30         const char *    subkey;
31         const char *    key;
32         u_int           flags;
33         const char *    value;
34
35         TAILQ_ENTRY(reg)        link;
36 };
37 TAILQ_HEAD(reg_head, reg);
38
39 #define FLG_ADDREG_TYPE_SZ              0x00000000
40 #define FLG_ADDREG_BINVALUETYPE         0x00000001
41 #define FLG_ADDREG_NOCLOBBER            0x00000002
42 #define FLG_ADDREG_DELVAL               0x00000004
43 #define FLG_ADDREG_APPEND               0x00000008
44 #define FLG_ADDREG_KEYONLY              0x00000010
45 #define FLG_ADDREG_OVERWRITEONLY        0x00000020
46 #define FLG_ADDREG_64BITKEY             0x00001000
47 #define FLG_ADDREG_KEYONLY_COMMON       0x00002000
48 #define FLG_ADDREG_32BITKEY             0x00004000
49 #define FLG_ADDREG_TYPE_MULTI_SZ        0x00010000
50 #define FLG_ADDREG_TYPE_EXPAND_SZ       0x00020000
51 #define FLG_ADDREG_TYPE_DWORD           0x00010001
52 #define FLG_ADDREG_TYPE_NONE            0x00020001
53
54 extern void     section_add     (const char *);
55 extern void     assign_add      (const char *);
56 extern void     define_add      (const char *);
57 extern void     regkey_add      (const char *);
58
59 extern void     push_word       (const char *);
60 extern void     clear_words     (void);
61 extern int      inf_parse       (FILE *, FILE *);