]> git.proxmox.com Git - qemu.git/commitdiff
hw/9pfs: Fix crash when mounting with synthfs
authorAneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Thu, 19 Jan 2012 06:51:12 +0000 (12:21 +0530)
committerAneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Mon, 30 Jan 2012 05:24:16 +0000 (10:54 +0530)
Some Fsdriver backend don't have fs_root. So check for that in
migrate message.

Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
hw/9pfs/virtio-9p.c

index e6ba6ba30bb26196388d586d4b8ae2628fb8d922..dfe2025ed29c22f978ddd48774eb1086fbcd56df 100644 (file)
@@ -986,7 +986,7 @@ static void v9fs_attach(void *opaque)
     s->root_fid = fid;
     /* disable migration */
     error_set(&s->migration_blocker, QERR_VIRTFS_FEATURE_BLOCKS_MIGRATION,
-              s->ctx.fs_root, s->tag);
+              s->ctx.fs_root ? s->ctx.fs_root : "NULL", s->tag);
     migrate_add_blocker(s->migration_blocker);
 out:
     put_fid(pdu, fidp);