summaryrefslogtreecommitdiff
path: root/gas/config/tc-mips.c
diff options
context:
space:
mode:
Diffstat (limited to 'gas/config/tc-mips.c')
-rw-r--r--gas/config/tc-mips.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/gas/config/tc-mips.c b/gas/config/tc-mips.c
index 8a970ceada2..55a116ffd90 100644
--- a/gas/config/tc-mips.c
+++ b/gas/config/tc-mips.c
@@ -15449,8 +15449,7 @@ mips_frob_file (void)
there isn't supposed to be a matching LO. Ignore %gots against
constants; we'll report an error for those later. */
if (got16_reloc_p (l->fixp->fx_r_type)
- && !(l->fixp->fx_addsy
- && pic_need_relax (l->fixp->fx_addsy)))
+ && !pic_need_relax (l->fixp->fx_addsy))
continue;
/* Check quickly whether the next fixup happens to be a matching %lo. */
@@ -17705,6 +17704,9 @@ pic_need_relax (symbolS *sym)
{
asection *symsec;
+ if (!sym)
+ return false;
+
/* Handle the case of a symbol equated to another symbol. */
while (symbol_equated_reloc_p (sym))
{