]> git.ipfire.org Git - thirdparty/elfutils.git/commitdiff
Drop mtrace calls.
authorMax Filippov <jcmvbkbc@gmail.com>
Sun, 3 May 2015 23:25:40 +0000 (02:25 +0300)
committerMark Wielaard <mjw@redhat.com>
Mon, 4 May 2015 14:05:04 +0000 (16:05 +0200)
mtrace is a GNU extension not supported by uClibc and it's believed to
not be really used. Drop mtrace() calls and #include <mcheck.h>.

Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
src/ChangeLog
src/addr2line.c
src/ar.c
src/ld.c
src/nm.c
src/objdump.c
src/ranlib.c
src/size.c
src/strip.c
src/unstrip.c

index 0aa85eee3f4626968005c5a714445476c0574aca..957eeb36b56787cb49597b9c89eedcc7e2cc78ff 100644 (file)
@@ -1,3 +1,15 @@
+2015-05-04  Max Filippov  <jcmvbkbc@gmail.com>
+
+       * addr2line.c (main): Drop mtrace() call and #include <mcheck.h>.
+       * ar.c: Likewise.
+       * ld.c: Likewise.
+       * nm.c: Likewise.
+       * objdump.c: Likewise.
+       * ranlib.c: Likewise.
+       * size.c: Likewise.
+       * strip.c: Likewise.
+       * unstrip.c: Likewise.
+
 2015-05-04  Anthony G. Basile  <blueness@gentoo.org>
 
        * Makefile.am (readelf_LDADD, nm_LDADD, size_LDADD, strip_LDADD)
index de802941092079e0326ca03727ce22b11eb14555..281a91e1c055f11ee45bc2bba750e0bbe76543d9 100644 (file)
@@ -30,7 +30,6 @@
 #include <dwarf.h>
 #include <libintl.h>
 #include <locale.h>
-#include <mcheck.h>
 #include <stdbool.h>
 #include <stdio.h>
 #include <stdio_ext.h>
@@ -131,9 +130,6 @@ main (int argc, char *argv[])
   int remaining;
   int result = 0;
 
-  /* Make memory leak detection possible.  */
-  mtrace ();
-
   /* We use no threads here which can interfere with handling a stream.  */
   (void) __fsetlocking (stdout, FSETLOCKING_BYCALLER);
 
index f51f0efdd7170fec4d11a24360a4d782a609ad3d..caed7f3f8e45edba659c2603fc8713f8e3f05425 100644 (file)
--- a/src/ar.c
+++ b/src/ar.c
@@ -28,7 +28,6 @@
 #include <libintl.h>
 #include <limits.h>
 #include <locale.h>
-#include <mcheck.h>
 #include <search.h>
 #include <stdbool.h>
 #include <stdlib.h>
@@ -141,9 +140,6 @@ static enum { ipos_none, ipos_before, ipos_after } ipos;
 int
 main (int argc, char *argv[])
 {
-  /* Make memory leak detection possible.  */
-  mtrace ();
-
   /* We use no threads here which can interfere with handling a stream.  */
   (void) __fsetlocking (stdin, FSETLOCKING_BYCALLER);
   (void) __fsetlocking (stdout, FSETLOCKING_BYCALLER);
index 73e4f04fda90a359b5e1da281f4d046c5bafc61c..6e96ae26b4f6f52ebba05dd712d82a4f80d8f4eb 100644 (file)
--- a/src/ld.c
+++ b/src/ld.c
@@ -26,7 +26,6 @@
 #include <libelf.h>
 #include <libintl.h>
 #include <locale.h>
-#include <mcheck.h>
 #include <stdio.h>
 #include <stdio_ext.h>
 #include <stdlib.h>
@@ -277,11 +276,6 @@ main (int argc, char *argv[])
   int remaining;
   int err;
 
-#ifndef NDEBUG
-  /* Enable memory debugging.  */
-  mtrace ();
-#endif
-
   /* Sanity check.  We always want to use the LFS functionality.  */
   if (sizeof (off_t) != sizeof (off64_t))
     abort ();
index 67fb4c295211ea3c1edbec6ade165ea21775a78f..b6a1e6ebc1c24386a7acbc5f5735189f3b28b6df 100644 (file)
--- a/src/nm.c
+++ b/src/nm.c
@@ -33,7 +33,6 @@
 #include <libdw.h>
 #include <libintl.h>
 #include <locale.h>
-#include <mcheck.h>
 #include <obstack.h>
 #include <search.h>
 #include <stdbool.h>
@@ -217,9 +216,6 @@ main (int argc, char *argv[])
   int remaining;
   int result = 0;
 
-  /* Make memory leak detection possible.  */
-  mtrace ();
-
   /* We use no threads here which can interfere with handling a stream.  */
   (void) __fsetlocking (stdin, FSETLOCKING_BYCALLER);
   (void) __fsetlocking (stdout, FSETLOCKING_BYCALLER);
index b689024b76cb145748e1ef7afbbc81708662c8e7..0aa41e89cd4bc1012e150c2c1db557275b3a8be9 100644 (file)
@@ -26,7 +26,6 @@
 #include <inttypes.h>
 #include <libintl.h>
 #include <locale.h>
-#include <mcheck.h>
 #include <stdbool.h>
 #include <stdio.h>
 #include <stdio_ext.h>
@@ -131,9 +130,6 @@ static bool print_disasm;
 int
 main (int argc, char *argv[])
 {
-  /* Make memory leak detection possible.  */
-  mtrace ();
-
   /* We use no threads here which can interfere with handling a stream.  */
   (void) __fsetlocking (stdin, FSETLOCKING_BYCALLER);
   (void) __fsetlocking (stdout, FSETLOCKING_BYCALLER);
index 8435fc1b9b38c96f349e779f7a4e4b22d370b7d0..c93c5ac8ec2601b09bfbb3bf798c90d2fc6ca321 100644 (file)
@@ -29,7 +29,6 @@
 #include <gelf.h>
 #include <libintl.h>
 #include <locale.h>
-#include <mcheck.h>
 #include <obstack.h>
 #include <stdlib.h>
 #include <stdio.h>
@@ -78,9 +77,6 @@ static const struct argp argp =
 int
 main (int argc, char *argv[])
 {
-  /* Make memory leak detection possible.  */
-  mtrace ();
-
   /* We use no threads here which can interfere with handling a stream.  */
   (void) __fsetlocking (stdin, FSETLOCKING_BYCALLER);
   (void) __fsetlocking (stdout, FSETLOCKING_BYCALLER);
index 0ec1139bc16e19d7ce3cd41b1bcf70c6e4f05de1..7c03ccef7c17ebb0a8c23092725254a29e7a40ac 100644 (file)
@@ -28,7 +28,6 @@
 #include <libelf.h>
 #include <libintl.h>
 #include <locale.h>
-#include <mcheck.h>
 #include <stdbool.h>
 #include <stdio.h>
 #include <stdio_ext.h>
@@ -160,9 +159,6 @@ main (int argc, char *argv[])
   int remaining;
   int result = 0;
 
-  /* Make memory leak detection possible.  */
-  mtrace ();
-
   /* We use no threads here which can interfere with handling a stream.  */
   __fsetlocking (stdin, FSETLOCKING_BYCALLER);
   __fsetlocking (stdout, FSETLOCKING_BYCALLER);
index c003647a1afb447b50171c0fee626ba4824f65da..e81001eb3341b5ca341a8fe8d5ba2d3aca6a3e50 100644 (file)
@@ -30,7 +30,6 @@
 #include <libelf.h>
 #include <libintl.h>
 #include <locale.h>
-#include <mcheck.h>
 #include <stdbool.h>
 #include <stdio.h>
 #include <stdio_ext.h>
@@ -155,9 +154,6 @@ main (int argc, char *argv[])
   int remaining;
   int result = 0;
 
-  /* Make memory leak detection possible.  */
-  mtrace ();
-
   /* We use no threads here which can interfere with handling a stream.  */
   __fsetlocking (stdin, FSETLOCKING_BYCALLER);
   __fsetlocking (stdout, FSETLOCKING_BYCALLER);
index 989ac5ff2848650cdff65c7fa6ab1b81c1706b81..4a8e5fa9cc0fed4a92db26a9298dde884e0cceaf 100644 (file)
@@ -36,7 +36,6 @@
 #include <fnmatch.h>
 #include <libintl.h>
 #include <locale.h>
-#include <mcheck.h>
 #include <stdbool.h>
 #include <stdio.h>
 #include <stdio_ext.h>
@@ -2252,9 +2251,6 @@ handle_implicit_modules (const struct arg_info *info)
 int
 main (int argc, char **argv)
 {
-  /* Make memory leak detection possible.  */
-  mtrace ();
-
   /* We use no threads here which can interfere with handling a stream.  */
   __fsetlocking (stdin, FSETLOCKING_BYCALLER);
   __fsetlocking (stdout, FSETLOCKING_BYCALLER);