This is the mail archive of the glibc-bugs@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug malloc/12140] mallopt(M_PERTURB) free() anomaly


http://sourceware.org/bugzilla/show_bug.cgi?id=12140

--- Comment #6 from Siddhesh Poyarekar <siddhesh at redhat dot com> 2012-10-17 13:02:01 UTC ---
Yes, that's the fun part.  The fd and bk pointers are written within the usable
area for a free block - it saves 2*sizeof(void *) per chunk.  In any case, a
user should not expect to be able to use them anyway for doing a check similar
to what you did after free, because that is undefined - you could cause a
segfault if the chunk was allocated using mmap.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]