>>>>"HN" == Hrvoje Niksic
<hniksic(a)xemacs.org> writes:
HN> This change will probably not fix any bug.
In C, '\0' is another
HN> way to spell 0, and in C++ '\0' will be cast to 0 anyway, since
HN> memset's second argument is int.
HN> Not that I'm against the change -- using '\0' makes the
HN> *intention* a bit clearer -- but it should be applied with
HN> understanding that it doesn't resolve any real problem.
Right, this part of the patch does not address the problem. I just
stumbled across this memset call and adjusted it to the others.
HN>> + memset (&mc_allocator_globals, '\0', sizeof
HN>> (mc_allocator_globals_type));
HN> This shouldn't be necessary unless init_mc_allocator is called
HN> twice (which it shouldn't be, judging by the comments and the
HN> code). A global variable is 0-initialized by default and calling
HN> memset doesn't accomplish anything.
An uninitialized lookup table is the only thing I can currently think
of that may cause the reported failure. Although, I was quite
surprised that this bug didn't hit earlier and more often. I'll keep
on investigating. Do you want me to revert this change?
--
Marcus