* exec.c (print_section_info): Add FIXME comments regarding format
authorKevin Buettner <kevinb@redhat.com>
Mon, 23 Dec 2002 23:36:39 +0000 (23:36 +0000)
committerKevin Buettner <kevinb@redhat.com>
Mon, 23 Dec 2002 23:36:39 +0000 (23:36 +0000)
string choices.

gdb/ChangeLog
gdb/exec.c

index 14514fdb083716706ef2a53293b9de618866e3c8..2e32e656d56cc5ad4582991f79cfe68b71182a3c 100644 (file)
@@ -1,3 +1,8 @@
+2002-12-20  Kevin Buettner  <kevinb@redhat.com>
+
+       * exec.c (print_section_info): Add FIXME comments regarding format
+       string choices.
+
 2002-12-23  Daniel Jacobowitz  <drow@mvista.com>
 
        * config/pa/nm-hppab.h: Delete duplicate CANNOT_STORE_REGISTER decl.
index 16b7e5f4e8d8347c40785382f720965e7fc118dd..b495a0096418d28a32cb21d51d5ae66e44aaaeb2 100644 (file)
@@ -545,6 +545,7 @@ void
 print_section_info (struct target_ops *t, bfd *abfd)
 {
   struct section_table *p;
+  /* FIXME: "016l" is not wide enough when TARGET_ADDR_BIT > 64.  */
   char *fmt = TARGET_ADDR_BIT <= 32 ? "08l" : "016l";
 
   printf_filtered ("\t`%s', ", bfd_get_filename (abfd));
@@ -560,6 +561,12 @@ print_section_info (struct target_ops *t, bfd *abfd)
     {
       printf_filtered ("\t%s", local_hex_string_custom (p->addr, fmt));
       printf_filtered (" - %s", local_hex_string_custom (p->endaddr, fmt));
+
+      /* FIXME: A format of "08l" is not wide enough for file offsets
+        larger than 4GB.  OTOH, making it "016l" isn't desirable either
+        since most output will then be much wider than necessary.  It
+        may make sense to test the size of the file and choose the
+        format string accordingly.  */
       if (info_verbose)
        printf_filtered (" @ %s",
                         local_hex_string_custom (p->the_bfd_section->filepos, "08l"));
This page took 0.039611 seconds and 4 git commands to generate.