aboutsummaryrefslogtreecommitdiff
path: root/gold/main.cc
diff options
context:
space:
mode:
authorFranz Sirl <franz.sirl-kernel@lauterbach.com>2018-01-24 13:39:11 +0000
committerCary Coutant <ccoutant@gmail.com>2018-07-11 08:39:36 -0700
commit04879304dea94c02f19fa5c219d2cbee6269f9af (patch)
tree326723b2ac9765e771a2afb974f4d00f3c42f71a /gold/main.cc
parent12863263d6f610ec161aead53df89586787b2ce4 (diff)
downloadgdb-04879304dea94c02f19fa5c219d2cbee6269f9af.zip
gdb-04879304dea94c02f19fa5c219d2cbee6269f9af.tar.gz
gdb-04879304dea94c02f19fa5c219d2cbee6269f9af.tar.bz2
Fix printing the size of GOLD's memory areana on Cygwin based systems.
I just stumbled over this with 2.29.1 while building a cross-toolchain, on Cygwin64, but it's still the same for 2.30. m.arena has size_t on Cygwin64 and thus errors out due to -Werror=format. gold * main.cc: Print m.arena as long long.
Diffstat (limited to 'gold/main.cc')
-rw-r--r--gold/main.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/gold/main.cc b/gold/main.cc
index aa6c698..06d810f 100644
--- a/gold/main.cc
+++ b/gold/main.cc
@@ -292,8 +292,8 @@ main(int argc, char** argv)
#ifdef HAVE_MALLINFO
struct mallinfo m = mallinfo();
- fprintf(stderr, _("%s: total space allocated by malloc: %d bytes\n"),
- program_name, m.arena);
+ fprintf(stderr, _("%s: total space allocated by malloc: %lld bytes\n"),
+ program_name, static_cast<long long>(m.arena));
#endif
File_read::print_stats();
Archive::print_stats();