From 841dd882a4b2fc8e8e6213349dcb99a6c5364e1b Mon Sep 17 00:00:00 2001 From: "Daniel P. Berrange" Date: Thu, 12 Jun 2008 13:48:29 +0000 Subject: [PATCH] Fix misc compile warnings --- ChangeLog | 7 +++++++ src/lxc_driver.c | 2 ++ src/openvz_conf.c | 5 ++--- src/openvz_driver.c | 3 +++ tests/testutils.c | 5 +---- 5 files changed, 15 insertions(+), 7 deletions(-) diff --git a/ChangeLog b/ChangeLog index 532782234a..5d0c20009e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +Thu Jun 12 14:46:08 BST 2008 Daniel P. Berrange + + * src/lxc_driver.c, src/openvz_driver.c: Add missing driver + entry points + * src/lxc_conf.c: Re-arrange headers to comply with standard + * tests/testutils.c: Fix use of signed/unsigned ints + Thu Jun 12 14:46:08 BST 2008 Daniel P. Berrange * src/qemu_driver.c: Fix saving of iptables rules diff --git a/src/lxc_driver.c b/src/lxc_driver.c index 33fa766bea..dea3aff0ed 100644 --- a/src/lxc_driver.c +++ b/src/lxc_driver.c @@ -1202,6 +1202,8 @@ static virDriver lxcDriver = { NULL, /* domainMigrateFinish */ NULL, /* domainBlockStats */ NULL, /* domainInterfaceStats */ + NULL, /* domainBlockPeek */ + NULL, /* domainMemoryPeek */ NULL, /* nodeGetCellsFreeMemory */ NULL, /* getFreeMemory */ }; diff --git a/src/openvz_conf.c b/src/openvz_conf.c index 090c0a4fd5..28c5ef3a21 100644 --- a/src/openvz_conf.c +++ b/src/openvz_conf.c @@ -41,13 +41,14 @@ #include #include #include +#include #include #include #include #include -#include "libvirt/virterror.h" +#include "internal.h" #include "openvz_driver.h" #include "openvz_conf.h" @@ -55,8 +56,6 @@ #include "buf.h" #include "memory.h" -#include - static char *openvzLocateConfDir(void); static void error (virConnectPtr conn, virErrorNumber code, const char *info); static struct openvz_vm_def *openvzParseXML(virConnectPtr conn, xmlDocPtr xml); diff --git a/src/openvz_driver.c b/src/openvz_driver.c index a20438f091..80e4ae5dd9 100644 --- a/src/openvz_driver.c +++ b/src/openvz_driver.c @@ -761,6 +761,8 @@ static virDriver openvzDriver = { NULL, /* domainMigrateFinish */ NULL, /* domainBlockStats */ NULL, /* domainInterfaceStats */ + NULL, /* domainBlockPeek */ + NULL, /* domainMemoryPeek */ NULL, /* nodeGetCellsFreeMemory */ NULL, /* nodeGetFreeMemory */ }; @@ -770,6 +772,7 @@ static virStateDriver openvzStateDriver = { openvzShutdown, openvzReload, openvzActive, + NULL, /* sigHandler */ }; int openvzRegister(void) { diff --git a/tests/testutils.c b/tests/testutils.c index d998d1fdf4..3a799d6950 100644 --- a/tests/testutils.c +++ b/tests/testutils.c @@ -329,10 +329,7 @@ int virtTestMain(int argc, int oomCount; if ((debugStr = getenv("VIR_TEST_DEBUG")) != NULL) { - if (virStrToLong_i(debugStr, NULL, 10, &testDebug) < 0) - testDebug = 0; - - if (testDebug < 0) + if (virStrToLong_ui(debugStr, NULL, 10, &testDebug) < 0) testDebug = 0; }