lkml.org 
[lkml]   [2009]   [Dec]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH 05/13] ftrace: Call trace_parser_clear() properly
From
Date
On Tue, 2009-12-08 at 18:03 +0800, Li Zefan wrote:

> >
> > I'm missing something. How that can happen. Anytime we reopen
> > the file, the parser is re-allocated.
> >
>
> It happened at file closing..
>
> static int
> ftrace_regex_release(struct inode *inode, struct file *file, int enable)
> {
> ...
> parser = &iter->parser;
> if (trace_parser_loaded(parser)) {
> parser->buffer[parser->idx] = 0;
> /* here ! */
> ftrace_match_records(parser->buffer, parser->idx, enable);
> }
> ...
> }
>
> > I guess that happens if you open in rw mode? But not using the
> > example in the changelog?
>
> I've confirmed that example I was using can reveal this bug.

This explanation should have been in the change log. I'll add it.

Thanks,

-- Steve




\
 
 \ /
  Last update: 2009-12-08 14:33    [W:0.053 / U:6.092 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site