Typo in Fri Sep 23 15:15:31 1994 changes for elfcode.h
H.J. Lu
hjl@nynexst.com
Sun Sep 25 17:37:00 GMT 1994
Hi,
--
H.J. Lu
NYNEX Science and Technology, Inc. hjl@nynexst.com
---
Fri Sep 23 15:15:31 1994 Ian Lance Taylor (ian@sanguine.cygnus.com)
* elfcode.h (map_program_segments): Don't abort if we allocated
too much space for the program header, only if we allocated too
little.
(assign_file_positions_except_relocs): Similar change.
diff -u -r --new-file --show-function-line=^[A-Za-z_] /cygint/s1/users/raeburn/offsite/snap/old/gas-940923/bfd/elfcode.h ./bfd/elfcode.h
--- /cygint/s1/users/raeburn/offsite/snap/old/gas-940923/bfd/elfcode.h Wed Sep 14 12:08:35 1994
+++ ./bfd/elfcode.h Fri Sep 23 12:53:51 1994
@@ -1924,8 +1924,9 @@ map_program_segments (abfd, off, first,
}
/* Make sure the return value from get_program_header_size matches
- what we computed here. */
- if (phdr_count != phdr_size / sizeof (Elf_External_Phdr))
+ what we computed here. Actually, it's OK if we allocated too
+ much space in the program header. */
+ if (phdr_count > phdr_size / sizeof (Elf_External_Phdr))
abort ();
/* Set up program header information. */
@@ -2102,7 +2103,7 @@ assign_file_positions_except_relocs (abf
phdr_map = map_program_segments (abfd, phdr_off, first, phdr_size);
if (phdr_map == (file_ptr) -1)
return false;
- BFD_ASSERT (phdr_map == phdr_off + phdr_size);
+ BFD_ASSERT (phdr_map < phdr_off + phdr_size);
^^^
Should that be
+ BFD_ASSERT (phdr_map <= phdr_off + phdr_size);
}
/* Place the section headers. */
More information about the Gas2
mailing list