selinux: remove redundant assignment to len
authorColin Ian King <colin.king@canonical.com>
Sat, 14 Oct 2017 15:00:49 +0000 (16:00 +0100)
committerPaul Moore <paul@paul-moore.com>
Mon, 16 Oct 2017 22:37:23 +0000 (18:37 -0400)
The variable len is being set to zero and this value is never
being read since len is being set to a different value just
a few lines later.  Remove this redundant assignment. Cleans
up clang warning: Value stored to 'len' is never read

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Paul Moore <paul@paul-moore.com>
security/selinux/ss/conditional.c

index 771c96afe1d53b9a4735e7f850d1266af31e8fe7..c91543a617aca3daafc09be5c8d52edef26ffaa3 100644 (file)
@@ -361,7 +361,6 @@ static int cond_read_av_list(struct policydb *p, void *fp, struct cond_av_list *
 
        *ret_list = NULL;
 
-       len = 0;
        rc = next_entry(buf, fp, sizeof(u32));
        if (rc)
                return rc;