Commit 4877bb91 authored by Sudip Mukherjee's avatar Sudip Mukherjee Committed by Greg Kroah-Hartman

component: remove impossible condition

We will be evaluating this condition only if match->num == match->alloc
and that means we have already dereferenced match which implies match
can not be NULL at this point.
Moreover we have done a NULL check on match just before this.
Signed-off-by: default avatarSudip Mukherjee <sudip@vectorindia.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 9e5b3d6f
......@@ -265,7 +265,7 @@ void component_match_add_release(struct device *master,
}
if (match->num == match->alloc) {
size_t new_size = match ? match->alloc + 16 : 15;
size_t new_size = match->alloc + 16;
int ret;
ret = component_match_realloc(master, match, new_size);
......
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