[patch] BFD ieee.c fix
Alan Modra
alan@linuxcare.com.au
Tue Oct 17 18:38:00 GMT 2000
More information about the Binutils mailing list
Tue Oct 17 18:38:00 GMT 2000
- Previous message (by thread): [patch] BFD ieee.c fix
- Next message (by thread): [patch] BFD ieee.c fix
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On 17 Oct 2000, Chris G. Demetriou wrote: > The patch looks trivially correct (or at least "better than what was > there" -- it's hard to describe that function's memory handling as > "correct" 8-), and i've compiled the file, but made no attempt to test > it. I recommend this patch _not_ be applied, nor any future patch mentioning the word trivial associated with bfd_release! The reason that changes involving bfd_release are non-trivial is that bfd_release frees not only it's arg, but all memory more recently bfd_alloc'd to the bfd as well. That means you need to rummage through all called functions (and any functions they call) between the point of allocation and the release, checking each function for calls to bfd_alloc. If any do so, then you need to convince yourself that there is no possibility of leaving dangling pointers. This is not to say that your patch is wrong. It may in fact be correct. It's just that I don't think you have done the checking I mention above, especially since a quick check shows at least one of the called functions does a bfd_alloc (but in the case I found leaves no dangling pointer) Regards, Alan Modra -- Linuxcare. Support for the Revolution.
- Previous message (by thread): [patch] BFD ieee.c fix
- Next message (by thread): [patch] BFD ieee.c fix
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Binutils mailing list