xfs
[Top] [All Lists]

Re: [PATCH 5/6] xfs: xlog_recover_process_data leaks like a sieve

To: Dave Chinner <david@xxxxxxxxxxxxx>
Subject: Re: [PATCH 5/6] xfs: xlog_recover_process_data leaks like a sieve
From: Christoph Hellwig <hch@xxxxxxxxxxxxx>
Date: Mon, 16 Dec 2013 07:23:39 -0800
Cc: Christoph Hellwig <hch@xxxxxxxxxxxxx>, xfs@xxxxxxxxxxx
Delivered-to: xfs@xxxxxxxxxxx
In-reply-to: <20131213221102.GX10988@dastard>
References: <1386826478-13846-1-git-send-email-david@xxxxxxxxxxxxx> <1386826478-13846-6-git-send-email-david@xxxxxxxxxxxxx> <20131213123205.GA17935@xxxxxxxxxxxxx> <20131213221102.GX10988@dastard>
User-agent: Mutt/1.5.21 (2010-09-15)
On Sat, Dec 14, 2013 at 09:11:02AM +1100, Dave Chinner wrote:
> I'll rework it, but hte main issue is that it has to be freed
> regardless of the error value in commit record processing, so it's
> not as simple as just freeing it on error....

Indeed, but think that's another reason to move the freeing to
xlog_recover_process_data.  Right now or with the proposed patch
xlog_recover_commit_trans frees trans, but there's nothing that
breaks out of the loop in xlog_recover_process_data after that case.

By moving the freeing there for all cases we can add a corruption
check for that case, and we have a single function that controls
the lifetime of the xlog_recover structure.

<Prev in Thread] Current Thread [Next in Thread>