* cofflink.c (_bfd_coff_link_input_bfd): Don't try to optimize a
struct/union/enum type with no elements. PR 9024.
This commit is contained in:
parent
110b814dba
commit
bdec62283a
|
@ -1,3 +1,8 @@
|
||||||
|
Mon Feb 26 14:01:13 1996 Ian Lance Taylor <ian@cygnus.com>
|
||||||
|
|
||||||
|
* cofflink.c (_bfd_coff_link_input_bfd): Don't try to optimize a
|
||||||
|
struct/union/enum type with no elements.
|
||||||
|
|
||||||
Sat Feb 24 11:38:58 1996 Ian Lance Taylor <ian@cygnus.com>
|
Sat Feb 24 11:38:58 1996 Ian Lance Taylor <ian@cygnus.com>
|
||||||
|
|
||||||
* bfd.c (bfd_errmsg): Handle a NULL return from strerror.
|
* bfd.c (bfd_errmsg): Handle a NULL return from strerror.
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/* COFF specific linker code.
|
/* COFF specific linker code.
|
||||||
Copyright 1994, 1995 Free Software Foundation, Inc.
|
Copyright 1994, 1995, 1996 Free Software Foundation, Inc.
|
||||||
Written by Ian Lance Taylor, Cygnus Support.
|
Written by Ian Lance Taylor, Cygnus Support.
|
||||||
|
|
||||||
This file is part of BFD, the Binary File Descriptor library.
|
This file is part of BFD, the Binary File Descriptor library.
|
||||||
|
@ -365,7 +365,7 @@ coff_link_add_symbols (abfd, info)
|
||||||
value -= section->vma;
|
value -= section->vma;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (! (_bfd_generic_link_add_one_symbol
|
if (! (bfd_coff_link_add_one_symbol
|
||||||
(info, abfd, name, flags, section, value,
|
(info, abfd, name, flags, section, value,
|
||||||
(const char *) NULL, copy, false,
|
(const char *) NULL, copy, false,
|
||||||
(struct bfd_link_hash_entry **) sym_hash)))
|
(struct bfd_link_hash_entry **) sym_hash)))
|
||||||
|
@ -1189,7 +1189,6 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
|
||||||
struct coff_debug_merge_element **epp;
|
struct coff_debug_merge_element **epp;
|
||||||
bfd_byte *esl, *eslend;
|
bfd_byte *esl, *eslend;
|
||||||
struct internal_syment *islp;
|
struct internal_syment *islp;
|
||||||
struct coff_debug_merge_type *mtl;
|
|
||||||
|
|
||||||
name = _bfd_coff_internal_syment_name (input_bfd, &isym, buf);
|
name = _bfd_coff_internal_syment_name (input_bfd, &isym, buf);
|
||||||
if (name == NULL)
|
if (name == NULL)
|
||||||
|
@ -1293,7 +1292,14 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
|
||||||
}
|
}
|
||||||
|
|
||||||
/* See if we already have a definition which matches this
|
/* See if we already have a definition which matches this
|
||||||
type. */
|
type. We always output the type if it has no elements,
|
||||||
|
for simplicity. */
|
||||||
|
if (mt->elements == NULL)
|
||||||
|
bfd_release (input_bfd, (PTR) mt);
|
||||||
|
else
|
||||||
|
{
|
||||||
|
struct coff_debug_merge_type *mtl;
|
||||||
|
|
||||||
for (mtl = mh->types; mtl != NULL; mtl = mtl->next)
|
for (mtl = mh->types; mtl != NULL; mtl = mtl->next)
|
||||||
{
|
{
|
||||||
struct coff_debug_merge_element *me, *mel;
|
struct coff_debug_merge_element *me, *mel;
|
||||||
|
@ -1331,6 +1337,7 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
|
||||||
skip = true;
|
skip = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/* We now know whether we are to skip this symbol or not. */
|
/* We now know whether we are to skip this symbol or not. */
|
||||||
if (! skip)
|
if (! skip)
|
||||||
|
|
Loading…
Reference in New Issue