apparmor: Fix an error code in verify_table_headers()
We accidentally return a positive EPROTO instead of a negative -EPROTO.
Since 71 is not an error pointer, that means it eventually results in an
Oops in the caller.
Fixes: d901d6a298
("apparmor: dfa split verification of table headers")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: John Johansen <john.johansen@canonical.com>
This commit is contained in:
parent
a61ecd329c
commit
d53c9f4d21
|
@ -198,7 +198,7 @@ static int verify_table_headers(struct table_header **tables, int flags)
|
|||
static int verify_dfa(struct aa_dfa *dfa)
|
||||
{
|
||||
size_t i, state_count, trans_count;
|
||||
int error = EPROTO;
|
||||
int error = -EPROTO;
|
||||
|
||||
state_count = dfa->tables[YYTD_ID_BASE]->td_lolen;
|
||||
trans_count = dfa->tables[YYTD_ID_NXT]->td_lolen;
|
||||
|
|
Loading…
Reference in New Issue