aboutsummaryrefslogtreecommitdiff
path: root/gas/write.c
diff options
context:
space:
mode:
Diffstat (limited to 'gas/write.c')
-rw-r--r--gas/write.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/gas/write.c b/gas/write.c
index ea0349c..38771b4 100644
--- a/gas/write.c
+++ b/gas/write.c
@@ -718,7 +718,8 @@ write_contents (abfd, sec, xxx)
fragS *f;
/* Write out the frags. */
- if (! (bfd_get_section_flags (abfd, sec) & SEC_HAS_CONTENTS))
+ if (seginfo == NULL
+ || ! (bfd_get_section_flags (abfd, sec) & SEC_HAS_CONTENTS))
return;
for (f = seginfo->frchainP->frch_root;