diff options
author | Steve French <sfrench@us.ibm.com> | 2007-02-08 18:14:13 +0000 |
---|---|---|
committer | Steve French <sfrench@us.ibm.com> | 2007-02-08 18:14:13 +0000 |
commit | 7ba526316ae122e60c0c7a40793491f71b9ec590 (patch) | |
tree | 5cac6a04506e79823245cd2996572b48b468e736 /fs/cifs/readdir.c | |
parent | 595dcfecf642c8b0772989ed46f15ee03c25a205 (diff) | |
download | op-kernel-dev-7ba526316ae122e60c0c7a40793491f71b9ec590.zip op-kernel-dev-7ba526316ae122e60c0c7a40793491f71b9ec590.tar.gz |
[CIFS] Allow update of EOF on remote extend of file
Signed-off-by: Steve French <sfrench@us.ibm.com>
Diffstat (limited to 'fs/cifs/readdir.c')
-rw-r--r-- | fs/cifs/readdir.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/cifs/readdir.c b/fs/cifs/readdir.c index 782940b..c6220bd 100644 --- a/fs/cifs/readdir.c +++ b/fs/cifs/readdir.c @@ -222,7 +222,7 @@ static void fill_in_inode(struct inode *tmp_inode, int new_buf_type, atomic_set(&cifsInfo->inUse, 1); } - if (is_size_safe_to_change(cifsInfo)) { + if (is_size_safe_to_change(cifsInfo, end_of_file)) { /* can not safely change the file size here if the client is writing to it due to potential races */ i_size_write(tmp_inode, end_of_file); @@ -351,10 +351,10 @@ static void unix_fill_in_inode(struct inode *tmp_inode, tmp_inode->i_gid = le64_to_cpu(pfindData->Gid); tmp_inode->i_nlink = le64_to_cpu(pfindData->Nlinks); - if (is_size_safe_to_change(cifsInfo)) { + if (is_size_safe_to_change(cifsInfo, end_of_file)) { /* can not safely change the file size here if the client is writing to it due to potential races */ - i_size_write(tmp_inode,end_of_file); + i_size_write(tmp_inode, end_of_file); /* 512 bytes (2**9) is the fake blocksize that must be used */ /* for this calculation, not the real blocksize */ |