]> git.ipfire.org Git - thirdparty/elfutils.git/commitdiff
2005-08-13 Roland McGrath <roland@redhat.com>
authorRoland McGrath <roland@redhat.com>
Sat, 13 Aug 2005 20:56:52 +0000 (20:56 +0000)
committerRoland McGrath <roland@redhat.com>
Sat, 13 Aug 2005 20:56:52 +0000 (20:56 +0000)
* elflint.c (check_program_header): Use ebl_segment_type_name and
allow any p_type it recognizes.  Include p_type value in error
message for unknown type.

src/ChangeLog
src/elflint.c

index ce6887ba3c8053666182b9eb0f991250e4593b7f..5dd61f2e565d1eb91494afce9353e36f9daf203f 100644 (file)
@@ -1,3 +1,9 @@
+2005-08-13  Roland McGrath  <roland@redhat.com>
+
+       * elflint.c (check_program_header): Use ebl_segment_type_name and
+       allow any p_type it recognizes.  Include p_type value in error
+       message for unknown type.
+
 2005-08-13  Ulrich Drepper  <drepper@redhat.com>
 
        * elflint.c (check_symtab): Simplify last change a bit.  Pass ehdr
index 59e6eaf94605fbe971371829a2810c1bf43354e5..65b3fb7273edbc0501402bbf5ce254184b7a1eba 100644 (file)
@@ -3088,10 +3088,12 @@ only executables, shared objects, and core files can have program headers\n"));
        }
 
       if (phdr->p_type >= PT_NUM && phdr->p_type != PT_GNU_EH_FRAME
-         && phdr->p_type != PT_GNU_STACK && phdr->p_type != PT_GNU_RELRO)
+         && phdr->p_type != PT_GNU_STACK && phdr->p_type != PT_GNU_RELRO
+         /* Check for a known machine-specific type.  */
+         && ebl_segment_type_name (ebl, phdr->p_type, NULL, 0) == NULL)
        ERROR (gettext ("\
-program header entry %d: unknown program header entry type\n"),
-              cnt);
+program header entry %d: unknown program header entry type %#" PRIx64 "\n"),
+              cnt, (uint64_t) phdr->p_type);
 
       if (phdr->p_type == PT_LOAD)
        has_loadable_segment = true;