2 * Sherlock Library -- Parsing Attribute Sets
4 * (c) 2006 Martin Mares <mj@ucw.cz>
6 * This software may be freely distributed and used according to the terms
7 * of the GNU Lesser General Public License.
10 #include "sherlock/sherlock.h"
11 #include "sherlock/object.h"
12 #include "sherlock/attrset.h"
13 #include "ucw/clists.h"
14 #include "sherlock/conf.h"
21 struct cf_section attr_set_cf = {
22 CF_TYPE(struct attr_node),
24 CF_USER("Attr", PTR_TO(struct attr_node, attr), &cf_type_attr),
29 struct cf_section attr_set_cf_sub = {
30 CF_TYPE(struct attr_node),
32 CF_USER("Attr", PTR_TO(struct attr_node, attr), &cf_type_attr_sub),
38 attr_set_commit(struct attr_set *set, clist *l)
41 bit_array_zero(set->a, ATTR_SET_SIZE);
42 CLIST_FOR_EACH(struct attr_node *, n, *l)
43 bit_array_set(set->a, n->attr);