9p: fix marshalling bug in tcreate with empty extension field
PATCH 1/1 9p: fix marshalling bug in tcreate with empty extension field
Quoted 1 line
From
c4610f24dbaa1fbd2e1c15162b76200a2ac40204Mon Sep 17 00:00:00 2001
From: Eric Van Hensbergen <ericvh@ericvh-laptop.(none)>
Date: Fri, 28 Jul 2006 13:18:35 -0500
Subject: [PATCH] marshalling bug in tcreate with empty extension field
Signed-off-by Russ Ross <[email protected]>
Signed-off-by Eric Van Hensbergen <[email protected]>
--- fs/9p/conv.c | 6 ++++-- 1 files changed, 4 insertions(+), 2 deletions(-)
fs/9p/conv.c +4 -2
@@ -673,8 +673,10 @@ struct v9fs_fcall *v9fs_create_tcreate(ustruct cbuf *bufp = &buffer; size =4 +2 +strlen (name) +4 +1 ;/* fid[4] name[s] perm[4] mode[1] */ -if (extended && extension!=NULL ) - size +=2 +strlen (extension);/* extension[s] */ +if (extended) { + size +=2 +/* extension[s] */ + (extension ==NULL ?0 :strlen (extension)); + } fc =v9fs_create_common (bufp, size,TCREATE );if (IS_ERR (fc))
Signature · 1 line
1.4.2.rc1.g83e1