aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTimothy Wall <twall@alum.mit.edu>2000-02-09 14:42:48 +0000
committerTimothy Wall <twall@alum.mit.edu>2000-02-09 14:42:48 +0000
commit9e4ed18ce8311c39a07b5fe267ac737eb7782cf7 (patch)
treea950f9530a9ac08f664b62082938c3edef943f9a
parent363d7b14a5363ce7ea4997ec6ebba4d7a28fe536 (diff)
downloadgdb-9e4ed18ce8311c39a07b5fe267ac737eb7782cf7.zip
gdb-9e4ed18ce8311c39a07b5fe267ac737eb7782cf7.tar.gz
gdb-9e4ed18ce8311c39a07b5fe267ac737eb7782cf7.tar.bz2
These snippets were missed in the previous bytes vs octets patch to
the linker.
-rw-r--r--ld/ChangeLog5
-rw-r--r--ld/ldlang.c8
2 files changed, 11 insertions, 2 deletions
diff --git a/ld/ChangeLog b/ld/ChangeLog
index 8ceaf8b..1ceee7a 100644
--- a/ld/ChangeLog
+++ b/ld/ChangeLog
@@ -1,5 +1,10 @@
2000-02-04 Timothy Wall <twall@redhat.com>
+ * ldlang.c (lang_check_section_addresses): Use bytes instead of
+ octets when calculating section end addresses.
+
+2000-02-04 Timothy Wall <twall@redhat.com>
+
* ldlang.c (lang_size_sections): Fix typo in ALIGN_N invocation.
2000-02-03 Timothy Wall <twall@redhat.com>
diff --git a/ld/ldlang.c b/ld/ldlang.c
index 10e41c2..6913a38 100644
--- a/ld/ldlang.c
+++ b/ld/ldlang.c
@@ -2672,8 +2672,8 @@ lang_check_section_addresses ()
overlapping VMAs but they must have distinct LMAs. */
s_start = bfd_section_lma (output_bfd, s);
os_start = bfd_section_lma (output_bfd, os);
- s_end = s_start + bfd_section_size (output_bfd, s) - 1;
- os_end = os_start + bfd_section_size (output_bfd, os) - 1;
+ s_end = s_start + bfd_section_size (output_bfd, s) / opb - 1;
+ os_end = os_start + bfd_section_size (output_bfd, os) / opb - 1;
/* Look for an overlap. */
if ((s_end < os_start) || (s_start > os_end))
@@ -2906,6 +2906,8 @@ lang_size_sections (s, output_section_statement, prev, fill, dot, relax)
switch (s->data_statement.type)
{
+ default:
+ abort();
case QUAD:
case SQUAD:
size = QUAD_SIZE;
@@ -3150,6 +3152,8 @@ lang_do_assignments (s, output_section_statement, fill, dot)
int size;
switch (s->data_statement.type)
{
+ default:
+ abort();
case QUAD:
case SQUAD:
size = QUAD_SIZE;