From 07d94e35293d6c6e0d028b51f1dd343259ad7edb Mon Sep 17 00:00:00 2001 From: George Rimar Date: Mon, 16 Jan 2017 11:35:38 +0000 Subject: [ELF] - Fix format specifiers in writeOutSecLine() I had a error in map-file.s testcase under MSVS2015/win32: map-file.s:30:16: error: expected string not found in input // CHECK-NEXT: 0000000000200158 0000000000000030 8 .eh_frame :2:1: note: scanning from here 0000000000200158 10 30 .eh_frame Format string '%0*x' requires an argument of type 'unsigned int', but argument has type 'uint64_t'. Proper format is '%0*llx' then. This fixes testcase failture for me. llvm-svn: 292102 --- lld/ELF/MapFile.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lld/ELF/MapFile.cpp') diff --git a/lld/ELF/MapFile.cpp b/lld/ELF/MapFile.cpp index 8986b9f78f7..60eee7ce00c 100644 --- a/lld/ELF/MapFile.cpp +++ b/lld/ELF/MapFile.cpp @@ -35,7 +35,7 @@ using namespace lld::elf; static void writeOutSecLine(raw_fd_ostream &OS, int Width, uint64_t Address, uint64_t Size, uint64_t Align, StringRef Name) { - OS << format("%0*x %0*x %5x ", Width, Address, Width, Size, Align) + OS << format("%0*llx %0*llx %5llx ", Width, Address, Width, Size, Align) << left_justify(Name, 7); } -- cgit v1.2.3