提交 4877bb91 编写于 作者: S Sudip Mukherjee 提交者: 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: NSudip Mukherjee <sudip@vectorindia.org>
Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
上级 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% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册