aboutsummaryrefslogtreecommitdiff
path: root/bfd/peXXigen.c
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2008-07-30 04:34:58 +0000
committerAlan Modra <amodra@gmail.com>2008-07-30 04:34:58 +0000
commit0af1713e7cd57b52f6c81f73aa58934132198880 (patch)
treeaf4b52a6c5f3c8cd570e4f266f019cf552d6f442 /bfd/peXXigen.c
parent22ad7fee2a313665df38ad7177f962f7c13ad0b6 (diff)
downloadgdb-0af1713e7cd57b52f6c81f73aa58934132198880.zip
gdb-0af1713e7cd57b52f6c81f73aa58934132198880.tar.gz
gdb-0af1713e7cd57b52f6c81f73aa58934132198880.tar.bz2
Silence gcc printf warnings
Diffstat (limited to 'bfd/peXXigen.c')
-rw-r--r--bfd/peXXigen.c29
1 files changed, 15 insertions, 14 deletions
diff --git a/bfd/peXXigen.c b/bfd/peXXigen.c
index 7be1f54..0c56067 100644
--- a/bfd/peXXigen.c
+++ b/bfd/peXXigen.c
@@ -1310,7 +1310,7 @@ pe_print_idata (bfd * abfd, void * vfile)
&& first_thunk != 0
&& first_thunk != hint_addr)
fprintf (file, "\t%04lx",
- (long) bfd_get_32 (abfd, ft_data + ft_idx + j));
+ (unsigned long) bfd_get_32 (abfd, ft_data + ft_idx + j));
fprintf (file, "\n");
}
#else
@@ -1342,7 +1342,7 @@ pe_print_idata (bfd * abfd, void * vfile)
&& first_thunk != 0
&& first_thunk != hint_addr)
fprintf (file, "\t%04lx",
- (long) bfd_get_32 (abfd, ft_data + ft_idx + j));
+ (unsigned long) bfd_get_32 (abfd, ft_data + ft_idx + j));
fprintf (file, "\n");
}
@@ -1961,7 +1961,7 @@ pe_print_reloc (bfd * abfd, void * vfile)
fprintf (file,
_("\nVirtual Address: %08lx Chunk size %ld (0x%lx) Number of fixups %ld\n"),
- (unsigned long) virtual_address, size, size, number);
+ (unsigned long) virtual_address, size, (unsigned long) size, number);
for (j = 0; j < number; ++j)
{
@@ -1974,7 +1974,7 @@ pe_print_reloc (bfd * abfd, void * vfile)
fprintf (file,
_("\treloc %4d offset %4x [%4lx] %s"),
- j, off, (long) (off + virtual_address), tbl[t]);
+ j, off, (unsigned long) (off + virtual_address), tbl[t]);
/* HIGHADJ takes an argument, - the next record *is* the
low 16 bits of addend. */
@@ -2064,11 +2064,11 @@ _bfd_XX_print_private_bfd_data_common (bfd * abfd, void * vfile)
fprintf (file, "\t(%s)",name);
fprintf (file, "\nMajorLinkerVersion\t%d\n", i->MajorLinkerVersion);
fprintf (file, "MinorLinkerVersion\t%d\n", i->MinorLinkerVersion);
- fprintf (file, "SizeOfCode\t\t%08lx\n", i->SizeOfCode);
+ fprintf (file, "SizeOfCode\t\t%08lx\n", (unsigned long) i->SizeOfCode);
fprintf (file, "SizeOfInitializedData\t%08lx\n",
- i->SizeOfInitializedData);
+ (unsigned long) i->SizeOfInitializedData);
fprintf (file, "SizeOfUninitializedData\t%08lx\n",
- i->SizeOfUninitializedData);
+ (unsigned long) i->SizeOfUninitializedData);
fprintf (file, "AddressOfEntryPoint\t");
fprintf_vma (file, i->AddressOfEntryPoint);
fprintf (file, "\nBaseOfCode\t\t");
@@ -2091,10 +2091,10 @@ _bfd_XX_print_private_bfd_data_common (bfd * abfd, void * vfile)
fprintf (file, "MinorImageVersion\t%d\n", i->MinorImageVersion);
fprintf (file, "MajorSubsystemVersion\t%d\n", i->MajorSubsystemVersion);
fprintf (file, "MinorSubsystemVersion\t%d\n", i->MinorSubsystemVersion);
- fprintf (file, "Win32Version\t\t%08lx\n", i->Reserved1);
- fprintf (file, "SizeOfImage\t\t%08lx\n", i->SizeOfImage);
- fprintf (file, "SizeOfHeaders\t\t%08lx\n", i->SizeOfHeaders);
- fprintf (file, "CheckSum\t\t%08lx\n", i->CheckSum);
+ fprintf (file, "Win32Version\t\t%08lx\n", (unsigned long) i->Reserved1);
+ fprintf (file, "SizeOfImage\t\t%08lx\n", (unsigned long) i->SizeOfImage);
+ fprintf (file, "SizeOfHeaders\t\t%08lx\n", (unsigned long) i->SizeOfHeaders);
+ fprintf (file, "CheckSum\t\t%08lx\n", (unsigned long) i->CheckSum);
switch (i->Subsystem)
{
@@ -2149,15 +2149,16 @@ _bfd_XX_print_private_bfd_data_common (bfd * abfd, void * vfile)
fprintf_vma (file, i->SizeOfHeapReserve);
fprintf (file, "\nSizeOfHeapCommit\t");
fprintf_vma (file, i->SizeOfHeapCommit);
- fprintf (file, "\nLoaderFlags\t\t%08lx\n", i->LoaderFlags);
- fprintf (file, "NumberOfRvaAndSizes\t%08lx\n", i->NumberOfRvaAndSizes);
+ fprintf (file, "\nLoaderFlags\t\t%08lx\n", (unsigned long) i->LoaderFlags);
+ fprintf (file, "NumberOfRvaAndSizes\t%08lx\n",
+ (unsigned long) i->NumberOfRvaAndSizes);
fprintf (file, "\nThe Data Directory\n");
for (j = 0; j < IMAGE_NUMBEROF_DIRECTORY_ENTRIES; j++)
{
fprintf (file, "Entry %1x ", j);
fprintf_vma (file, i->DataDirectory[j].VirtualAddress);
- fprintf (file, " %08lx ", i->DataDirectory[j].Size);
+ fprintf (file, " %08lx ", (unsigned long) i->DataDirectory[j].Size);
fprintf (file, "%s\n", dir_names[j]);
}