summaryrefslogtreecommitdiffstats
path: root/fs/xfs
diff options
context:
space:
mode:
authortinguely@sgi.com <tinguely@sgi.com>2013-09-27 09:00:55 -0500
committerBen Myers <bpm@sgi.com>2013-09-30 17:52:43 -0500
commit519ccb81ac1c8e3e4eed294acf93be00b43dcad6 (patch)
tree05d11ca11b2e0011419122fc49d2ee8eac761fb4 /fs/xfs
parent367993e7c6428cb7617ab7653d61dca54e2fdede (diff)
downloadtalos-obmc-linux-519ccb81ac1c8e3e4eed294acf93be00b43dcad6.tar.gz
talos-obmc-linux-519ccb81ac1c8e3e4eed294acf93be00b43dcad6.zip
xfs: fix memory leak in xlog_recover_add_to_trans
Free the memory in error path of xlog_recover_add_to_trans(). Normally this memory is freed in recovery pass2, but is leaked in the error path. Signed-off-by: Mark Tinguely <tinguely@sgi.com> Reviewed-by: Eric Sandeen <sandeen@redhat.com> Signed-off-by: Ben Myers <bpm@sgi.com>
Diffstat (limited to 'fs/xfs')
-rw-r--r--fs/xfs/xfs_log_recover.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/xfs/xfs_log_recover.c b/fs/xfs/xfs_log_recover.c
index cc179878fe41..43240583fd5b 100644
--- a/fs/xfs/xfs_log_recover.c
+++ b/fs/xfs/xfs_log_recover.c
@@ -1585,6 +1585,7 @@ xlog_recover_add_to_trans(
"bad number of regions (%d) in inode log format",
in_f->ilf_size);
ASSERT(0);
+ free(ptr);
return XFS_ERROR(EIO);
}
OpenPOWER on IntegriCloud