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:	Fri, 18 Apr 2008 23:09:38 -0400 (EDT)
From:	Steven Rostedt <rostedt@...dmis.org>
To:	Andrew Morton <akpm@...ux-foundation.org>
cc:	linux-kernel@...r.kernel.org, mingo@...e.hu, peterz@...radead.org,
	sandmann@...hat.com, pq@....fi, srostedt@...hat.com
Subject: Re: [PATCH 1/5] ftrace: simple clean ups


On Fri, 18 Apr 2008, Andrew Morton wrote:

> On Fri, 18 Apr 2008 16:05:39 -0400
> Steven Rostedt <rostedt@...dmis.org> wrote:
>
> > -	r = snprintf(buf, 64, "%ld\n",
> > +	r = snprintf(buf, sizeof(buf), "%ld\n",
>
> If you use scnprintf here

Cool, I didn't know of that function.

>
> >  		     *ptr == (unsigned long)-1 ? -1 : nsecs_to_usecs(*ptr));
> > -	if (r > 64)
> > -		r = 64;
> > +	if (r > sizeof(buf))
> > +		r = sizeof(buf);
>
> This becomes a cant-happen (I think).

Yep it does. New patch on the way.

Thanks,

-- Steve

--
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