On Thu, Nov 29, 2012 at 11:29:25AM -0800, Kent Overstreet wrote:
> There's some kind of symmetry going on here, and if I'd been awake more
> in college I could probably say exactly why it works, but it does.

I think the catch is that using only a 32 bit counter is something the 
user could arbitrarily control the sum of all parts.  I think a 64 bit 
counter may be required to ensure no overflow occurs.  Otherwise, an 
overflow could result in a premature free when there are still 2^32 
objects active thanks to a malicious user (possible on systems with lots 
of memory these days -- remote, but possible).

                -ben
-- 
"Thought is the essence of where you are now."
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Reply via email to