diff options
author | Nick Clifton <nickc@redhat.com> | 2007-09-26 08:12:59 +0000 |
---|---|---|
committer | Nick Clifton <nickc@redhat.com> | 2007-09-26 08:12:59 +0000 |
commit | 06dcabb0579335e3db3825385d41de58e529c7c0 (patch) | |
tree | cab7088dc60abeb7ed528e52fede989080f04958 /bfd/som.c | |
parent | 0a7b15ff9a901c96669d1efe7f68b19efc061013 (diff) | |
download | gdb-06dcabb0579335e3db3825385d41de58e529c7c0.zip gdb-06dcabb0579335e3db3825385d41de58e529c7c0.tar.gz gdb-06dcabb0579335e3db3825385d41de58e529c7c0.tar.bz2 |
* som.c (som_get_reloc_upper_bound): If there are no relocs return enough
space to hold a NULL pointer.
Diffstat (limited to 'bfd/som.c')
-rw-r--r-- | bfd/som.c | 7 |
1 files changed, 5 insertions, 2 deletions
@@ -4939,8 +4939,11 @@ som_get_reloc_upper_bound (bfd *abfd, sec_ptr asect) return -1; return (asect->reloc_count + 1) * sizeof (arelent *); } - /* There are no relocations. */ - return 0; + + /* There are no relocations. Return enough space to hold the + NULL pointer which will be installed if som_canonicalize_reloc + is called. */ + return sizeof (arelent *); } /* Convert relocations from SOM (external) form into BFD internal |