2
0
mirror of https://gitlab.com/apparmor/apparmor synced 2025-08-31 06:16:03 +00:00

Make value_list generic so it can be reused.

value_list can be reused by conditionals and list values, so pull it out
and abstract it some more.

Signed-off-by: John Johansen <john.johansen@canonical.com>
Acked-by: Kees Cook <kees@ubuntu.com>
This commit is contained in:
John Johansen
2012-02-16 08:07:28 -08:00
parent e087db57b2
commit b8f36df713
3 changed files with 51 additions and 29 deletions

View File

@@ -49,6 +49,12 @@ struct cod_pattern {
char *regex; // posix regex
};
struct value_list {
char *value;
struct value_list *next;
};
struct cod_entry {
char *namespace;
char *name;
@@ -275,6 +281,9 @@ extern struct var_string *split_out_var(char *string);
extern void free_var_string(struct var_string *var);
/* parser_misc.c */
extern struct value_list *new_value_list(char *value);
extern void free_value_list(struct value_list *list);
extern void print_value_list(struct value_list *list);
extern char *processid(char *string, int len);
extern char *processquoted(char *string, int len);
extern char *processunquoted(char *string, int len);