summaryrefslogtreecommitdiffstats
path: root/bfd/coffcode.h
diff options
context:
space:
mode:
authorKai Tietz <kai.tietz@onevision.com>2010-04-27 17:26:09 +0000
committerKai Tietz <kai.tietz@onevision.com>2010-04-27 17:26:09 +0000
commitef72a554d982f439fb9be357386681c1d4fb475c (patch)
tree5eeb461c5d93df2c31c6101172f9b670cd529201 /bfd/coffcode.h
parente78f4312c58a798df3fe09566a1f714eaf61294a (diff)
downloadppe42-binutils-ef72a554d982f439fb9be357386681c1d4fb475c.tar.gz
ppe42-binutils-ef72a554d982f439fb9be357386681c1d4fb475c.zip
2010-04-27 Kai Tietz <kai.tietz@onevision.com>
* pe-x86_64.c (TARGET_UNDERSCORE): Set value dependent to USE_MINGW64_LEADING_UNDERSCORES. * pei-x86_64.c (TARGET_UNDERSCORE): Likewise. * config.bfd: Change underscoring default for x64 mingw to false. * coffcode.h (coff_write_relocs): Add check that dereferenced sym_ptr_ptr isn't NULL. * config.in (USE_MINGW64_LEADING_UNDERSCORES): New. * configure: Regenerated. * configure.in: Add option '--enable-leading-mingw64-underscores' and define config.in variable USE_MINGW64_LEADING_UNDERSCORES.
Diffstat (limited to 'bfd/coffcode.h')
-rw-r--r--bfd/coffcode.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/bfd/coffcode.h b/bfd/coffcode.h
index 159df27f94..364daaad5c 100644
--- a/bfd/coffcode.h
+++ b/bfd/coffcode.h
@@ -2648,7 +2648,7 @@ coff_write_relocs (bfd * abfd, int first_undef)
entries know which symbol index they point to. So we
have to look up the output symbol here. */
- if (q->sym_ptr_ptr[0]->the_bfd != abfd)
+ if (q->sym_ptr_ptr[0] != NULL && q->sym_ptr_ptr[0]->the_bfd != abfd)
{
int j;
const char *sname = q->sym_ptr_ptr[0]->name;
@@ -2677,7 +2677,7 @@ coff_write_relocs (bfd * abfd, int first_undef)
n.r_symndx = q->addend;
else
#endif
- if (q->sym_ptr_ptr)
+ if (q->sym_ptr_ptr && q->sym_ptr_ptr[0] != NULL)
{
#ifdef SECTION_RELATIVE_ABSOLUTE_SYMBOL_P
if (SECTION_RELATIVE_ABSOLUTE_SYMBOL_P (q, s))
OpenPOWER on IntegriCloud