This is the mail archive of the libc-help@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]

Re: Persistent malloc


On 11/07/2017 09:25 PM, Carlos O'Donell wrote:
I just managed to make a persistent malloc by replacing MORECORE. My init
routine opens a file and maps it to a huge space at a fixed address, then I
just ftruncate the file when somebody asks my MORECORE for more:

We are going to remove the MORECORE hook soon. Newly compiled binaries will no longer call it.

You need to provide your own malloc if you want to change this behavior:

<https://www.gnu.org/software/libc/manual/html_node/Replacing-malloc.html>

Thanks,
Florian


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