summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2002-01-22 07:27:02 +0000
committerJeremy Allison <jra@samba.org>2002-01-22 07:27:02 +0000
commitc99d2a436ff3c83c102c8c01b39861d0e6955f66 (patch)
treebac879c5ffba96e5188020aac041276e93ae516e
parent3065fecbd878daf969079552fd4b859e24d87a53 (diff)
downloadsamba-c99d2a436ff3c83c102c8c01b39861d0e6955f66.tar.gz
samba-c99d2a436ff3c83c102c8c01b39861d0e6955f66.tar.xz
samba-c99d2a436ff3c83c102c8c01b39861d0e6955f66.zip
Ensure fsp->size is up to date.
Jeremy.
-rw-r--r--source/smbd/reply.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/source/smbd/reply.c b/source/smbd/reply.c
index 01127b6977a..0e4e466b33e 100644
--- a/source/smbd/reply.c
+++ b/source/smbd/reply.c
@@ -2192,9 +2192,7 @@ int reply_readbraw(connection_struct *conn, char *inbuf, char *outbuf, int dum_s
if (size < sizeneeded) {
SMB_STRUCT_STAT st;
if (vfs_fstat(fsp,fsp->fd,&st) == 0)
- size = st.st_size;
- if (!fsp->can_write)
- fsp->size = size;
+ fsp->size = size = st.st_size;
}
if (startpos >= size)