diff options
-rw-r--r-- | security/selinux/ss/sidtab.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/security/selinux/ss/sidtab.c b/security/selinux/ss/sidtab.c index 53a54a77f1f8..4a516ff4bcde 100644 --- a/security/selinux/ss/sidtab.c +++ b/security/selinux/ss/sidtab.c | |||
@@ -156,12 +156,10 @@ void sidtab_map_remove_on_error(struct sidtab *s, | |||
156 | while (cur != NULL) { | 156 | while (cur != NULL) { |
157 | ret = apply(cur->sid, &cur->context, args); | 157 | ret = apply(cur->sid, &cur->context, args); |
158 | if (ret) { | 158 | if (ret) { |
159 | if (last) { | 159 | if (last) |
160 | last->next = cur->next; | 160 | last->next = cur->next; |
161 | } else { | 161 | else |
162 | s->htable[i] = cur->next; | 162 | s->htable[i] = cur->next; |
163 | } | ||
164 | |||
165 | temp = cur; | 163 | temp = cur; |
166 | cur = cur->next; | 164 | cur = cur->next; |
167 | context_destroy(&temp->context); | 165 | context_destroy(&temp->context); |