diff options
author | Harsh Prateek Bora | 2011-04-14 11:24:40 +0200 |
---|---|---|
committer | Venkateswararao Jujjuri | 2011-04-27 17:27:25 +0200 |
commit | 4f8dee2dec9c6d590c8a7844b2824935542ca122 (patch) | |
tree | 5a04dbaff4fb1b81799aadaabd3311991d2fbe1b /hw/9pfs/virtio-9p.h | |
parent | hw/virtio-9p-local.c: Remove unnecessary null char in symlink file (diff) | |
download | qemu-4f8dee2dec9c6d590c8a7844b2824935542ca122.tar.gz qemu-4f8dee2dec9c6d590c8a7844b2824935542ca122.tar.xz qemu-4f8dee2dec9c6d590c8a7844b2824935542ca122.zip |
v9fs_walk: As per 9p2000 RFC, MAXWELEM >= nwnames >= 0.
The nwnames field in TWALK message is assumed to be >=0 and <= MAXWELEM
which is defined as macro P9_MAXWELEM (16) in virtio-9p.h as per 9p2000
RFC. Appropriate changes are required in V9fsWalkState and v9fs_walk.
Signed-off-by: Harsh Prateek Bora <harsh@linux.vnet.ibm.com>
Reviewed-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
Signed-off-by: Venkateswararao Jujjuri <jvrao@linux.vnet.ibm.com>
Diffstat (limited to 'hw/9pfs/virtio-9p.h')
-rw-r--r-- | hw/9pfs/virtio-9p.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/hw/9pfs/virtio-9p.h b/hw/9pfs/virtio-9p.h index 95e4977363..622928fce5 100644 --- a/hw/9pfs/virtio-9p.h +++ b/hw/9pfs/virtio-9p.h @@ -282,7 +282,7 @@ typedef struct V9fsStatStateDotl { typedef struct V9fsWalkState { V9fsPDU *pdu; size_t offset; - int16_t nwnames; + uint16_t nwnames; int name_idx; V9fsQID *qids; V9fsFidState *fidp; |