From: Daniel P. Berrange Date: Thu, 20 Nov 2008 14:33:59 +0000 (+0000) Subject: Fix crash on NULL uri scheme X-Git-Tag: LIBVIRT_0_5_0~36 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d378791480274e33744cc183838fd41268688fe0;p=thirdparty%2Flibvirt.git Fix crash on NULL uri scheme --- diff --git a/ChangeLog b/ChangeLog index 71a511ec7a..295675fb8c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +Thu Nov 20 14:31:00 GMT 2008 Daniel Berrange + + * src/remote_internal.c: Avoid crash on NULL URI scheme + Wed Nov 19 16:51:00 GMT 2008 Daniel Berrange Add User Mode Linux driver diff --git a/src/remote_internal.c b/src/remote_internal.c index 7ca6ec10c9..21f716d3db 100644 --- a/src/remote_internal.c +++ b/src/remote_internal.c @@ -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") &&