diff options
author | Alan Modra <amodra@bigpond.net.au> | 2000-07-10 02:05:40 +0000 |
---|---|---|
committer | Alan Modra <amodra@bigpond.net.au> | 2000-07-10 02:05:40 +0000 |
commit | a60d48abe63511f0ef51f5e04bf946888a3b61d7 (patch) | |
tree | 2386c1fdb155e2445b8320ab5c3498ba7373a833 /bfd | |
parent | eb3b90e35ab3937dff2edd607cd5022e75697fd3 (diff) | |
download | gdb-a60d48abe63511f0ef51f5e04bf946888a3b61d7.tar.gz |
Avoid negative section sequence ids.
Diffstat (limited to 'bfd')
-rw-r--r-- | bfd/ChangeLog | 5 | ||||
-rw-r--r-- | bfd/section.c | 6 |
2 files changed, 8 insertions, 3 deletions
diff --git a/bfd/ChangeLog b/bfd/ChangeLog index c1ebe2a6b9b..ee300e79992 100644 --- a/bfd/ChangeLog +++ b/bfd/ChangeLog @@ -1,3 +1,8 @@ +2000-07-10 Alan Modra <alan@linuxcare.com.au> + + * section.c (bfd_make_section_anyway): Start section_id at 0x10. + (STD_SECTION): Avoid negative ids, instead use 0 to 3. + 2000-07-09 Koundinya K <kk@ddeorg.soft.net> * elf32-mips.c (sort_dynamic_relocs): New Function. diff --git a/bfd/section.c b/bfd/section.c index 3b5162983e2..9006d195f84 100644 --- a/bfd/section.c +++ b/bfd/section.c @@ -552,8 +552,8 @@ static const asymbol global_syms[] = #define STD_SECTION(SEC, FLAGS, SYM, NAME, IDX) \ const asymbol * const SYM = (asymbol *) &global_syms[IDX]; \ const asection SEC = \ - /* name, id, index, next, flags, user_set_vma, reloc_done, */ \ - { NAME, -1-(IDX), 0, NULL, FLAGS, 0, 0, \ + /* name, id, index, next, flags, user_set_vma, reloc_done, */ \ + { NAME, IDX, 0, NULL, FLAGS, 0, 0, \ \ /* linker_mark, gc_mark, vma, lma, _cooked_size, _raw_size, */ \ 0, 0, 0, 0, 0, 0, \ @@ -693,7 +693,7 @@ bfd_make_section_anyway (abfd, name) bfd *abfd; const char *name; { - static int section_id = 0; + static int section_id = 0x10; /* id 0 to 3 used by STD_SECTION. */ asection *newsect; asection **prev = &abfd->sections; asection *sect = abfd->sections; |