summaryrefslogtreecommitdiff
path: root/security/apparmor/mount.c
diff options
context:
space:
mode:
authorColin Ian King <colin.king@canonical.com>2019-06-27 16:09:04 +0300
committerJohn Johansen <john.johansen@canonical.com>2019-11-23 03:37:54 +0300
commit00e0590dbaec6f1bcaa36a85467d7e3497ced522 (patch)
tree5e5baf491acc9a0bfdfb2070d076d533849bdaba /security/apparmor/mount.c
parent136db994852a9b405ac1074de0e7a1c4c840b8ee (diff)
downloadlinux-00e0590dbaec6f1bcaa36a85467d7e3497ced522.tar.xz
apparmor: fix unsigned len comparison with less than zero
The sanity check in macro update_for_len checks to see if len is less than zero, however, len is a size_t so it can never be less than zero, so this sanity check is a no-op. Fix this by making len a ssize_t so the comparison will work and add ulen that is a size_t copy of len so that the min() macro won't throw warnings about comparing different types. Addresses-Coverity: ("Macro compares unsigned to 0") Fixes: f1bd904175e8 ("apparmor: add the base fns() for domain labels") Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: John Johansen <john.johansen@canonical.com>
Diffstat (limited to 'security/apparmor/mount.c')
0 files changed, 0 insertions, 0 deletions