提交 234b7f8d 编写于 作者: G Gustavo A. R. Silva 提交者: Greg Kroah-Hartman

vmci: fix duplicated code for different branches

Refactor code in order to avoid identical code for different branches.

This issue was detected with the help of Coccinelle.

Addresses-Coverity-ID: 1226762
Signed-off-by: NGustavo A. R. Silva <gustavo@embeddedor.com>
Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
上级 006dbb38
......@@ -2235,14 +2235,8 @@ int vmci_qp_broker_detach(struct vmci_handle handle, struct vmci_ctx *context)
handle.context, handle.resource,
result);
if (entry->vmci_page_files)
qp_host_unregister_user_memory(entry->produce_q,
entry->
consume_q);
else
qp_host_unregister_user_memory(entry->produce_q,
entry->
consume_q);
qp_host_unregister_user_memory(entry->produce_q,
entry->consume_q);
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册