Fix an uninitialized variable in Unix socket open

* src/qemu_driver.c: qemudOpenMonitorUnix() had an uninitialized loop
  counter
This commit is contained in:
Jun Koi 2009-07-21 11:57:54 +02:00 committed by Daniel Veillard
parent 7641c3c782
commit b2fd033cd5

View File

@ -874,7 +874,7 @@ qemudOpenMonitorUnix(virConnectPtr conn,
struct sockaddr_un addr; struct sockaddr_un addr;
int monfd; int monfd;
int timeout = 3; /* In seconds */ int timeout = 3; /* In seconds */
int ret, i; int ret, i = 0;
if ((monfd = socket(AF_UNIX, SOCK_STREAM, 0)) < 0) { if ((monfd = socket(AF_UNIX, SOCK_STREAM, 0)) < 0) {
virReportSystemError(conn, errno, virReportSystemError(conn, errno,