Dr Andrew Scott G7VAV

My photo
 
April 2024
Mo Tu We Th Fr Sa Su
1 2 3 4 5 6 7
8 9 10 11 12 13 14
15 16 17 18 19 20 21
22 23 24 25 26 27 28
29 30 1 2 3 4 5
6 7 8 9 10 11 12


MTRACE

Section: Linux Programmer's Manual (3)
Updated: 2002-07-20
Index Return to Main Contents
 

NAME

mtrace, muntrace - malloc debugging  

SYNOPSIS

#include <mcheck.h>

void mtrace(void);

void muntrace(void);  

DESCRIPTION

The function mtrace() installs handlers for malloc(3), realloc(3) and free(3). The function muntrace() disables these handlers.
The environment variable MALLOC_TRACE defines a file where mtrace() writes its output. This file must be writable to the user or mtrace() will do nothing. If the file is not empty it will be truncated.  

CONFORMING TO

These are GNU extensions.  

NOTES

The output of mtrace() will be ASCII but not in a friendly format. So glibc comes with a perl-script called mtrace to make sense of it.  

SEE ALSO

malloc(3), malloc_hook(3)  

COLOPHON

This page is part of release 3.35 of the Linux man-pages project. A description of the project, and information about reporting bugs, can be found at http://man7.org/linux/man-pages/.


 

Index

NAME
SYNOPSIS
DESCRIPTION
CONFORMING TO
NOTES
SEE ALSO
COLOPHON


for client 18.219.22.169
© Andrew Scott 2006 - 2024,
All Rights Reserved
http://www.andrew-scott.uk/
Andrew Scott
http://www.andrew-scott.co.uk/