lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Tue, 22 Jan 2013 14:16:47 +0100
From:	Jiri Olsa <jolsa@...hat.com>
To:	Steven Rostedt <rostedt@...dmis.org>
Cc:	linux-kernel@...r.kernel.org,
	Arnaldo Carvalho de Melo <acme@...hat.com>,
	Corey Ashford <cjashfor@...ux.vnet.ibm.com>,
	Frederic Weisbecker <fweisbec@...il.com>,
	Ingo Molnar <mingo@...e.hu>,
	Namhyung Kim <namhyung@...nel.org>,
	Paul Mackerras <paulus@...ba.org>,
	Peter Zijlstra <a.p.zijlstra@...llo.nl>
Subject: Re: [PATCH] tools lib traceevent: Handle dynamic array's element
 size properly

On Mon, Jan 21, 2013 at 11:45:42PM -0500, Steven Rostedt wrote:
> On Mon, 2013-01-21 at 13:44 +0100, Jiri Olsa wrote:

SNIP

> > +	for (i = 0; table[i].type; i++) {
> > +		if (!strcmp(table[i].type, field->type_dyn))
> > +			return table[i].size;
> > +	}
> > +
> > +	return 0;
> > +}
> > +
> >  static int event_read_fields(struct event_format *event, struct format_field **fields)
> >  {
> >  	struct format_field *field = NULL;
> > @@ -1390,7 +1418,7 @@ static int event_read_fields(struct event_format *event, struct format_field **f
> >  				field->type = new_type;
> >  				strcat(field->type, " ");
> >  				strcat(field->type, field->name);
> > -				free_token(field->name);
> > +				field->type_dyn = field->name;
> 
> This is only used in this function (the field_dynamic_elem_size() is
> only called here). Can we not add the field->type_dyn, and just use a
> local variable here. You just need to make sure you free it correctly.

ook, will send v2

thanks,
jirka
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ