use MALLOC_PERTURB_ ... or lose

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



If you are into development on glibc-based systems
and do not set MALLOC_PERTURB_ to a nonzero value, then you
are missing an easy opportunity to detect subtle bugs early.

Sure, you can use valgrind, and it will detect whatever a
MALLOC_PERTURB_ setting would have caught, and more, but it's
far more expensive and takes some effort, however minimal.

If you use zsh or bash, put this in one of your startup files:

    # http://udrepper.livejournal.com/11429.html
    export MALLOC_PERTURB_=$(($RANDOM % 255 + 1))

and remember that when you find surprising bugs, that others
who are also running tests (but without MALLOC_PERTURB_)
will not see the same failures.

This is useful enough that it is worth considering for inclusion
in /etc/profile.
-- 
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxxx
https://admin.fedoraproject.org/mailman/listinfo/devel

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Fedora Announce]     [Fedora Kernel]     [Fedora Testing]     [Fedora Formulas]     [Fedora PHP Devel]     [Kernel Development]     [Fedora Legacy]     [Fedora Maintainers]     [Fedora Desktop]     [PAM]     [Red Hat Development]     [Gimp]     [Yosemite News]
  Powered by Linux