aboutsummaryrefslogtreecommitdiff
path: root/bfd/som.c
diff options
context:
space:
mode:
Diffstat (limited to 'bfd/som.c')
-rw-r--r--bfd/som.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/bfd/som.c b/bfd/som.c
index 3aa44c1..dfba504 100644
--- a/bfd/som.c
+++ b/bfd/som.c
@@ -1802,6 +1802,10 @@ setup_sections (abfd, file_hdr)
space.space_number) == false)
goto error_return;
+ /* If the space has no subspaces, then we're done. */
+ if (space.subspace_quantity == 0)
+ continue;
+
/* Now, read in the first subspace for this space */
if (bfd_seek (abfd, file_hdr->subspace_location
+ space.subspace_index * sizeof subspace,