mirror of
https://github.com/topjohnwu/selinux.git
synced 2024-12-02 16:46:18 +00:00
libselinux: context_new(): drop dead assignment
The variable `i` is not used inside this loop, and it later unconditionally set to 0. Found by clang-analyzer. Signed-off-by: Christian Göttsche <cgzones@googlemail.com>
This commit is contained in:
parent
319429ba33
commit
782fa6ea38
@ -37,7 +37,7 @@ context_t context_new(const char *str)
|
||||
}
|
||||
n->current_str = n->component[0] = n->component[1] = n->component[2] =
|
||||
n->component[3] = 0;
|
||||
for (i = count = 0, p = str; *p; p++) {
|
||||
for (count = 0, p = str; *p; p++) {
|
||||
switch (*p) {
|
||||
case ':':
|
||||
count++;
|
||||
|
Loading…
Reference in New Issue
Block a user