diff options
author | Miklos Szeredi <miklos@szeredi.hu> | 2005-11-07 03:59:49 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2005-11-07 10:53:42 -0500 |
commit | cc4e69dee4a080f6eae3f410daec2593f4fa6f00 (patch) | |
tree | b9be8984a0be5f7997d836603963dcf8f2e728ff /fs/exec.c | |
parent | 481bed454247538e9f57d4ea37b153ccba24ba7b (diff) |
[PATCH] VFS: pass file pointer to filesystem from ftruncate()
This patch extends the iattr structure with a file pointer memeber, and adds
an ATTR_FILE validity flag for this member.
This is set if do_truncate() is invoked from ftruncate() or from
do_coredump().
The change is source and binary compatible.
Signed-off-by: Miklos Szeredi <miklos@szeredi.hu>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'fs/exec.c')
-rw-r--r-- | fs/exec.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -1511,7 +1511,7 @@ int do_coredump(long signr, int exit_code, struct pt_regs * regs) | |||
1511 | goto close_fail; | 1511 | goto close_fail; |
1512 | if (!file->f_op->write) | 1512 | if (!file->f_op->write) |
1513 | goto close_fail; | 1513 | goto close_fail; |
1514 | if (do_truncate(file->f_dentry, 0) != 0) | 1514 | if (do_truncate(file->f_dentry, 0, file) != 0) |
1515 | goto close_fail; | 1515 | goto close_fail; |
1516 | 1516 | ||
1517 | retval = binfmt->core_dump(signr, regs, file); | 1517 | retval = binfmt->core_dump(signr, regs, file); |