|
@@ -321,10 +321,10 @@ enum {
|
|
};
|
|
};
|
|
|
|
|
|
static match_table_t tokens = {
|
|
static match_table_t tokens = {
|
|
- {Opt_context, "context=%s"},
|
|
|
|
- {Opt_fscontext, "fscontext=%s"},
|
|
|
|
- {Opt_defcontext, "defcontext=%s"},
|
|
|
|
- {Opt_rootcontext, "rootcontext=%s"},
|
|
|
|
|
|
+ {Opt_context, CONTEXT_STR "%s"},
|
|
|
|
+ {Opt_fscontext, FSCONTEXT_STR "%s"},
|
|
|
|
+ {Opt_defcontext, DEFCONTEXT_STR "%s"},
|
|
|
|
+ {Opt_rootcontext, ROOTCONTEXT_STR "%s"},
|
|
{Opt_error, NULL},
|
|
{Opt_error, NULL},
|
|
};
|
|
};
|
|
|
|
|
|
@@ -2287,10 +2287,10 @@ static inline int match_prefix(char *prefix, int plen, char *option, int olen)
|
|
|
|
|
|
static inline int selinux_option(char *option, int len)
|
|
static inline int selinux_option(char *option, int len)
|
|
{
|
|
{
|
|
- return (match_prefix("context=", sizeof("context=")-1, option, len) ||
|
|
|
|
- match_prefix("fscontext=", sizeof("fscontext=")-1, option, len) ||
|
|
|
|
- match_prefix("defcontext=", sizeof("defcontext=")-1, option, len) ||
|
|
|
|
- match_prefix("rootcontext=", sizeof("rootcontext=")-1, option, len));
|
|
|
|
|
|
+ return (match_prefix(CONTEXT_STR, sizeof(CONTEXT_STR)-1, option, len) ||
|
|
|
|
+ match_prefix(FSCONTEXT_STR, sizeof(FSCONTEXT_STR)-1, option, len) ||
|
|
|
|
+ match_prefix(DEFCONTEXT_STR, sizeof(DEFCONTEXT_STR)-1, option, len) ||
|
|
|
|
+ match_prefix(ROOTCONTEXT_STR, sizeof(ROOTCONTEXT_STR)-1, option, len));
|
|
}
|
|
}
|
|
|
|
|
|
static inline void take_option(char **to, char *from, int *first, int len)
|
|
static inline void take_option(char **to, char *from, int *first, int len)
|