From: John Ferlan Date: Tue, 22 Jan 2013 14:15:43 +0000 (-0500) Subject: virfile: Need to initialize 'looppath' X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=50adf8271d7d85025fedf64b44470bff2471b43f;p=libvirt.git virfile: Need to initialize 'looppath' It was possible to call VIR_FREE in cleanup prior to initialization. --- diff --git a/src/util/virfile.c b/src/util/virfile.c index 50999aa0d3..5cca54df4f 100644 --- a/src/util/virfile.c +++ b/src/util/virfile.c @@ -602,7 +602,7 @@ static int virFileLoopDeviceOpen(char **dev_name) int fd = -1; DIR *dh = NULL; struct dirent *de; - char *looppath; + char *looppath = NULL; struct loop_info64 lo; VIR_DEBUG("Looking for loop devices in /dev");