提交 d3787914 编写于 作者: D Daniel P. Berrange

Fix crash on NULL uri scheme

上级 714bef5b
Thu Nov 20 14:31:00 GMT 2008 Daniel Berrange <berrange@redhat.com>
* src/remote_internal.c: Avoid crash on NULL URI scheme
Wed Nov 19 16:51:00 GMT 2008 Daniel Berrange <berrange@redhat.com>
Add User Mode Linux driver
......
......@@ -855,6 +855,7 @@ remoteOpen (virConnectPtr conn,
*/
if (conn->uri &&
!conn->uri->server &&
conn->uri->scheme &&
!strchr(conn->uri->scheme, '+')) {
DEBUG0("Auto-remote UNIX socket");
rflags |= VIR_DRV_OPEN_REMOTE_UNIX;
......@@ -869,6 +870,7 @@ remoteOpen (virConnectPtr conn,
if (conn->uri &&
!conn->uri->server &&
conn->uri->path &&
conn->uri->scheme &&
((strchr(conn->uri->scheme, '+') == 0)||
(strstr(conn->uri->scheme, "+unix") != NULL)) &&
STREQ(conn->uri->path, "/session") &&
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册