CONFIG_PREEMPT and JFFS2 oops

Joakim Tjernlund joakim.tjernlund at transmode.se
Thu Jan 26 11:48:15 EST 2012


Paul Walmsley <paul at pwsan.com> wrote on 2012/01/26 17:38:46:
>
> On Thu, 26 Jan 2012, Paul Walmsley wrote:
>
> > On Thu, 26 Jan 2012, Joakim Tjernlund wrote:
> >
> > > I think I found one bug by looking at the patch. You need 2 buffers, one
> > > that holds the latest compressed data and one working buffer.
> >
> > Thanks, I think you're right.  Here's an updated patch.
>
> ... which has another minor bug: it leaks memory if the first allocation
> fails.  Here's a version with that fixed.

Still leeks:
+		 		 		 		 best_slen = tdl;
+		 		 		 		 best_buf = tmp_buf;
+		 		 		 		 best = this;

You just throw away best_buf here, don't you?





More information about the linux-mtd mailing list