提交 c67daf4a 编写于 作者: L linzhecheng 提交者: Jason Wang

vhost-user: delete net client if necessary

As qemu_new_net_client create new ncs but error happens later,
ncs will be left in global net_clients list and we can't use them any
more, so we need to cleanup them.

Cc: qemu-stable@nongnu.org
Signed-off-by: Nlinzhecheng <linzhecheng@huawei.com>
Signed-off-by: NJason Wang <jasowang@redhat.com>
上级 2285a00c
......@@ -345,6 +345,9 @@ err:
s->vhost_user = NULL;
}
}
if (nc0) {
qemu_del_net_client(nc0);
}
return -1;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册