aboutsummaryrefslogtreecommitdiff
path: root/bfd/som.c
diff options
context:
space:
mode:
authorJeff Law <law@redhat.com>1995-01-05 00:34:07 +0000
committerJeff Law <law@redhat.com>1995-01-05 00:34:07 +0000
commiteb57c776702450b08f37a187f96f59ff13f67009 (patch)
treed03e2355c775168dd6a175ccda2f56f5c978c90f /bfd/som.c
parente2a8da6a507e716c3cc80a9a8f8d3ced1edc0fa9 (diff)
downloadgdb-eb57c776702450b08f37a187f96f59ff13f67009.zip
gdb-eb57c776702450b08f37a187f96f59ff13f67009.tar.gz
gdb-eb57c776702450b08f37a187f96f59ff13f67009.tar.bz2
* som.c (bfd_section_from_som_symbol): Only return sections which
correspond to subspaces.
Diffstat (limited to 'bfd/som.c')
-rw-r--r--bfd/som.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/bfd/som.c b/bfd/som.c
index d0c9fc6..bec94b8 100644
--- a/bfd/som.c
+++ b/bfd/som.c
@@ -3685,7 +3685,7 @@ bfd_section_from_som_symbol (abfd, symbol)
{
unsigned int index = symbol->symbol_info;
for (section = abfd->sections; section != NULL; section = section->next)
- if (section->target_index == index)
+ if (section->target_index == index && som_is_subspace (section))
return section;
/* Could be a symbol from an external library (such as an OMOS
@@ -3702,7 +3702,8 @@ bfd_section_from_som_symbol (abfd, symbol)
for (section = abfd->sections; section; section = section->next)
{
if (value >= section->vma
- && value <= section->vma + section->_cooked_size)
+ && value <= section->vma + section->_cooked_size
+ && som_is_subspace (section))
return section;
}