Re: make checkpatch warn about memset with swapped arguments.

From: Steven Rostedt
Date: Thu Mar 17 2011 - 18:05:18 EST


On Thu, 2011-03-17 at 14:57 -0700, Andrew Morton wrote:

> I'm OK with switching from memset to bzero as the preferred way of
> clearing memory (shorter, clearer, not susceptible to the arg reversal
> bug). Is Linus?

I suspect that a lot of memset(foo, 0, size); are before a kmalloc and
can also be replaced with kzalloc();

-- Steve


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