提交 c10a6d50 编写于 作者: D Daniel P. Berrangé

lxc: allow empty path in URI for historical compatibility

The use of 'lxc://' was mistakenly broken in:

  commit 4c8574c8
  Author: Daniel P. Berrangé <berrange@redhat.com>
  Date:   Wed Mar 28 12:49:29 2018 +0100

    driver: ensure NULL URI isn't passed to drivers with whitelisted URIs

Allow it again for historical compatibility.
Signed-off-by: NDaniel P. Berrangé <berrange@redhat.com>
上级 f8862714
......@@ -140,7 +140,8 @@ static virDrvOpenStatus lxcConnectOpen(virConnectPtr conn,
virCheckFlags(VIR_CONNECT_RO, VIR_DRV_OPEN_ERROR);
/* If path isn't '/' then they typoed, tell them correct path */
if (STRNEQ(conn->uri->path, "/") &&
if (STRNEQ(conn->uri->path, "") &&
STRNEQ(conn->uri->path, "/") &&
STRNEQ(conn->uri->path, "/system")) {
virReportError(VIR_ERR_INTERNAL_ERROR,
_("Unexpected LXC URI path '%s', try lxc:///system"),
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册