YAH8LP (Yet another H8 Ld Problem :)
Alan Modra
alan@linuxcare.com.au
Thu Nov 2 16:41:00 GMT 2000
On Thu, 2 Nov 2000, Joel Sherrill wrote:
> We are back to a core dump. It appears to be for a different reason.
> This is from the free at the bottom of the routine
> bfd_coff_reloc16_get_relocated_section_contents(). Is the pointer
> being corrupted? There is some aliasing of it going on.
It's probably not the pointer but some piece of code writing outside of an
allocated memory block. eg.
struct foobie *p = malloc (n * sizeof (struct foobie));
.
p[-1].field = crasho;
.
p[n+1].field = alternate_crasho; // might not bomb on free (p), but free
. // of something else.
free (p);
These sorts of bugs can be difficult to find. Tools like purify and
electric-fence help.
--
Linuxcare. Support for the Revolution.
More information about the Binutils
mailing list