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

Re: Basic question about malloc



mudongliang wrote:
But the result has no feature about a ,b ,c!
Can someone tell me what's wrong with me?
My GCC version is gcc (Debian 4.9.2-10) 4.9.2
mudongliang

malloc is not part of gcc, it is part of glibc.  I think that recent
versions of glibc deliberately return random addresses, so the
addresses are unpredictable and cannot be used to write malware.
This is probably documented in the sources of glibc but first,
see malloc(3) and mallopt(3) (e.g. "man malloc" and "man mallopt" on
the command line).

--
Ludovic Brenta.


Reply to: