aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel P. Berrange <berrange@redhat.com>2012-06-15 13:48:34 +0100
committerDaniel P. Berrange <berrange@redhat.com>2012-06-15 15:33:51 +0100
commit50312d4b911a3b1c67c1ae60e18ac261e6e438e9 (patch)
tree4ffe23f9758829c1d9ac7a4e2968ce462de44e9c /src/libvirt.c
parentschema: Update domain XML schema (diff)
downloadlibvirt-50312d4b911a3b1c67c1ae60e18ac261e6e438e9.tar.gz
libvirt-50312d4b911a3b1c67c1ae60e18ac261e6e438e9.tar.bz2
libvirt-50312d4b911a3b1c67c1ae60e18ac261e6e438e9.zip
Add more debug logging for libvirtd startup
To facilitate future troubleshooting add a bunch more debugging statements into important startup parts of libvirt
Diffstat (limited to 'src/libvirt.c')
-rw-r--r--src/libvirt.c15
1 files changed, 9 insertions, 6 deletions
diff --git a/src/libvirt.c b/src/libvirt.c
index 16afd586f..99e85e49b 100644
--- a/src/libvirt.c
+++ b/src/libvirt.c
@@ -769,20 +769,23 @@ virRegisterStateDriver(virStateDriverPtr driver)
* Returns 0 if all succeed, -1 upon any failure.
*/
int virStateInitialize(int privileged) {
- int i, ret = 0;
+ int i;
if (virInitialize() < 0)
return -1;
for (i = 0 ; i < virStateDriverTabCount ; i++) {
- if (virStateDriverTab[i]->initialize &&
- virStateDriverTab[i]->initialize(privileged) < 0) {
- VIR_ERROR(_("Initialization of %s state driver failed"),
+ if (virStateDriverTab[i]->initialize) {
+ VIR_DEBUG("Running global init for %s state driver",
virStateDriverTab[i]->name);
- ret = -1;
+ if (virStateDriverTab[i]->initialize(privileged) < 0) {
+ VIR_ERROR(_("Initialization of %s state driver failed"),
+ virStateDriverTab[i]->name);
+ return -1;
+ }
}
}
- return ret;
+ return 0;
}
/**