Commit 3197f5ad authored by John Johansen's avatar John Johansen

apparmor: don't check for vmalloc_addr if kvzalloc() failed

Signed-off-by: default avatarJohn Johansen <john.johansen@canonical.com>
parent 15756178
...@@ -75,14 +75,14 @@ static struct table_header *unpack_table(char *blob, size_t bsize) ...@@ -75,14 +75,14 @@ static struct table_header *unpack_table(char *blob, size_t bsize)
u32, be32_to_cpu); u32, be32_to_cpu);
else else
goto fail; goto fail;
}
out:
/* if table was vmalloced make sure the page tables are synced /* if table was vmalloced make sure the page tables are synced
* before it is used, as it goes live to all cpus. * before it is used, as it goes live to all cpus.
*/ */
if (is_vmalloc_addr(table)) if (is_vmalloc_addr(table))
vm_unmap_aliases(); vm_unmap_aliases();
}
out:
return table; return table;
fail: fail:
kvfree(table); kvfree(table);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment