aboutsummaryrefslogtreecommitdiff
path: root/hw/9pfs
diff options
context:
space:
mode:
authorAneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>2011-05-26 14:41:15 +0530
committerAneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>2011-09-09 14:45:53 +0530
commit407fee0f026faf3296f08231e862799fbc2740c5 (patch)
tree25bef544c8682529960f32ccc376079b8c9755eb /hw/9pfs
parent07ff2c4475df77e38a31d50ee7f3932631806c15 (diff)
hw/9pfs: Update the fidp path before opendir
We need to update the fidp path before opendir. Since we don't use the fid returned by mkdir, earlier code should not have much issue. We do a double v9fs_string_copy here. The later patch cleanup the entire function. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Diffstat (limited to 'hw/9pfs')
-rw-r--r--hw/9pfs/virtio-9p.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/hw/9pfs/virtio-9p.c b/hw/9pfs/virtio-9p.c
index 94b7090e7d..71bc51b3ca 100644
--- a/hw/9pfs/virtio-9p.c
+++ b/hw/9pfs/virtio-9p.c
@@ -2106,6 +2106,7 @@ static void v9fs_create(void *opaque)
if (err < 0) {
goto out;
}
+ v9fs_string_copy(&fidp->path, &fullname);
err = v9fs_co_opendir(pdu->s, fidp);
if (err < 0) {
goto out;