[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH -V3 31/32] virtio-9p: Return proper errors from crea
From: |
Aneesh Kumar K.V |
Subject: |
[Qemu-devel] [PATCH -V3 31/32] virtio-9p: Return proper errors from create paths. |
Date: |
Thu, 25 Mar 2010 22:13:39 +0530 |
From: Sripathi Kodi <address@hidden>
Create first calls lstat to see if the file exists. Errors from lstat are
not handled properly. For most of the errors we return EEXIST. We should
return the errno instead.
Signed-off-by: Sripathi Kodi <address@hidden>
Signed-off-by: Aneesh Kumar K.V <address@hidden>
---
hw/virtio-9p.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/hw/virtio-9p.c b/hw/virtio-9p.c
index 5ccaeac..1b791ca 100644
--- a/hw/virtio-9p.c
+++ b/hw/virtio-9p.c
@@ -1644,7 +1644,7 @@ static void v9fs_create_post_lstat(V9fsState *s,
V9fsCreateState *vs, int err)
{
if ( err == 0 || errno != ENOENT) {
- err = -EEXIST;
+ err = -errno;
goto out;
}
--
1.7.0.2.323.g0d092
- [Qemu-devel] [PATCH -V3 20/32] virtio-9p: Remove BUG_ON and add proper error handling, (continued)
- [Qemu-devel] [PATCH -V3 20/32] virtio-9p: Remove BUG_ON and add proper error handling, Aneesh Kumar K.V, 2010/03/25
- [Qemu-devel] [PATCH -V3 24/32] qemu-malloc: Add qemu_asprintf, Aneesh Kumar K.V, 2010/03/25
- [Qemu-devel] [PATCH -V3 26/32] virtio-9p: Create a commandline option -fsdev, Aneesh Kumar K.V, 2010/03/25
- [Qemu-devel] [PATCH -V3 25/32] virtio-9p: Move V9fs File system specific options to a separate header file., Aneesh Kumar K.V, 2010/03/25
- [Qemu-devel] [PATCH -V3 27/32] virtio-9p: Create qemu_fsdev_opts, Aneesh Kumar K.V, 2010/03/25
- [Qemu-devel] [PATCH -V3 28/32] virtio-9p: Handle the fsdev command line options., Aneesh Kumar K.V, 2010/03/25
- [Qemu-devel] [PATCH -V3 29/32] virtio-9p: Decouple share_path details from virtio-9p-dev, Aneesh Kumar K.V, 2010/03/25
- [Qemu-devel] [PATCH -V3 30/32] virtio-9p: Create a syntactic shortcut for the file-system pass-thru, Aneesh Kumar K.V, 2010/03/25
- [Qemu-devel] [PATCH -V3 31/32] virtio-9p: Return proper errors from create paths.,
Aneesh Kumar K.V <=
- [Qemu-devel] [PATCH -V3 32/32] virtio-9p: Handle unknown 9P protocol versions as per the standards., Aneesh Kumar K.V, 2010/03/25