summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard W.M. Jones <rjones@redhat.com>2011-06-08 22:14:21 +0100
committerRichard W.M. Jones <rjones@redhat.com>2011-06-13 14:22:04 +0100
commit01cdc3d593146a60e7c7e26b91b96625cda0ba1b (patch)
treecaa698827898afdcdca35930b668157b3d8d1650
parentfab0de07f0debb497245a7d525c9db28730065fa (diff)
downloadlibguestfs-01cdc3d593146a60e7c7e26b91b96625cda0ba1b.tar.gz
libguestfs-01cdc3d593146a60e7c7e26b91b96625cda0ba1b.tar.xz
libguestfs-01cdc3d593146a60e7c7e26b91b96625cda0ba1b.zip
Coverity: Check return value of sysroot_path.
For some reason we were checking the parameter! (cherry picked from commit 7fae594df719d1d81a043c4d0280b359f750facb)
-rw-r--r--daemon/mount.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/daemon/mount.c b/daemon/mount.c
index a379d39e..098283a0 100644
--- a/daemon/mount.c
+++ b/daemon/mount.c
@@ -352,7 +352,7 @@ do_mount_loop (const char *file, const char *mountpoint)
}
buf = sysroot_path (file);
- if (!file) {
+ if (!buf) {
reply_with_perror ("malloc");
free (mp);
return -1;