Commit bf71a676 authored by Anton Altaparmakov's avatar Anton Altaparmakov

NTFS: Disable the file size changing code from

      fs/ntfs/aops.c::ntfs_prepare_write() for now as it is not safe.
Signed-off-by: default avatarAnton Altaparmakov <aia21@cantab.net>
parent 551f668f
......@@ -49,11 +49,6 @@ ToDo/Notes:
- In fs/ntfs/aops.c::ntfs_writepage(), if the page is fully outside
i_size, i.e. race with truncate, invalidate the buffers on the page
so that they become freeable and hence the page does not leak.
- Implement extension of resident files in the regular file write code
paths (fs/ntfs/aops.c::ntfs_{prepare,commit}_write()). At present
this only works until the data attribute becomes too big for the mft
record after which we abort the write returning -EOPNOTSUPP from
ntfs_prepare_write().
- Remove unused function fs/ntfs/runlist.c::ntfs_rl_merge(). (Adrian
Bunk)
- Fix stupid bug in fs/ntfs/attrib.c::ntfs_attr_find() that resulted in
......
......@@ -1884,6 +1884,12 @@ static int ntfs_prepare_write(struct file *file, struct page *page,
/* If we do not need to resize the attribute allocation we are done. */
if (new_size <= vi->i_size)
goto done;
// FIXME: We abort for now as this code is not safe.
ntfs_error(vi->i_sb, "Changing the file size is not supported yet. "
"Sorry.");
return -EOPNOTSUPP;
/* Map, pin, and lock the (base) mft record. */
if (!NInoAttr(ni))
base_ni = ni;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment