summaryrefslogtreecommitdiffstats
path: root/fs/xfs/xfs_dfrag.c
diff options
context:
space:
mode:
authorIngo Molnar <mingo@elte.hu>2009-02-11 10:17:42 +0100
committerIngo Molnar <mingo@elte.hu>2009-02-11 10:17:42 +0100
commitf437e8b53eab92a5829e65781e29aed23d8ffd0c (patch)
tree48982c8818a4ac5cddb84ca6a1d55620eb9680ee /fs/xfs/xfs_dfrag.c
parent140573d33b703194b7e1893711e78b7f546cca7c (diff)
parent8e4921515c1a379539607eb443d51c30f4f7f338 (diff)
downloadlinux-stable-f437e8b53eab92a5829e65781e29aed23d8ffd0c.tar.gz
linux-stable-f437e8b53eab92a5829e65781e29aed23d8ffd0c.tar.bz2
linux-stable-f437e8b53eab92a5829e65781e29aed23d8ffd0c.zip
Merge commit 'v2.6.29-rc4' into sched/core
Diffstat (limited to 'fs/xfs/xfs_dfrag.c')
-rw-r--r--fs/xfs/xfs_dfrag.c10
1 files changed, 1 insertions, 9 deletions
diff --git a/fs/xfs/xfs_dfrag.c b/fs/xfs/xfs_dfrag.c
index b4c1ee713492..f8278cfcc1d3 100644
--- a/fs/xfs/xfs_dfrag.c
+++ b/fs/xfs/xfs_dfrag.c
@@ -55,17 +55,11 @@ xfs_swapext(
struct file *file, *target_file;
int error = 0;
- sxp = kmem_alloc(sizeof(xfs_swapext_t), KM_MAYFAIL);
- if (!sxp) {
- error = XFS_ERROR(ENOMEM);
- goto out;
- }
-
/* Pull information for the target fd */
file = fget((int)sxp->sx_fdtarget);
if (!file) {
error = XFS_ERROR(EINVAL);
- goto out_free_sxp;
+ goto out;
}
if (!(file->f_mode & FMODE_WRITE) || (file->f_flags & O_APPEND)) {
@@ -109,8 +103,6 @@ xfs_swapext(
fput(target_file);
out_put_file:
fput(file);
- out_free_sxp:
- kmem_free(sxp);
out:
return error;
}