buildworld Stop in /usr/src/usr.sbin/bsnmpd/bsnmpd
Jason Evans
jasone at FreeBSD.org
Wed Mar 22 22:56:31 UTC 2006
Kevin Oberman wrote:
>>Date: Wed, 22 Mar 2006 14:24:08 -0800
>>From: Jason Evans <jasone at FreeBSD.org>
>>Kevin Oberman wrote:
>>>Not only did the fix to Makefile.inc1 not do the trick, but
>>>hand-building gnesnmptree and hand executing the commands to make the
>>>oid.h file didn't help a bit.
>>>
>>>I'm baffled. (And probably missing the obvious.)
>>
>>This isn't a very satisfying solution, but if you do the buildworld with
>>MALLOC_OPTIONS=jZ, you will avoid the gensnmptree bug.
>
> Thanks! It worked like a charm.
>
> Any explanation as to why zeroing a malloc makes this work (as opposed
> to filling with 0xa5)? I'm sure confused.
If I remember correctly, gensnmptree uses a bitflag as a field in a
malloc'ed structure. phkmalloc uses 0xd0 for junk filling (2 at 11010000),
whereas jemalloc uses 0xa5 (2 at 10100101). Older versions of gensnmptree
didn't initialize the flag, and the jemalloc junk filling in the least
significant four bits caused it to think that the flag was set.
Jason
More information about the freebsd-current
mailing list