[OB] Add cleanup, source.c
Daniel Jacobowitz
drow@false.org
Fri Jun 29 00:24:00 GMT 2007
On Thu, Jun 28, 2007 at 03:59:23PM -0700, Michael Snyder wrote:
>
>
> > There's no call to do_cleanups in this function, so it's quite hard to
> > see if this cleanup will be run or discarded if error is not called.
>
> When are they ever discarded?
>
> My last understanding of the mechanism was that the cleanups
> always get called, eventually. Presumably when we return to
> the command / event loop.
No, that's not right. Cleanups are often discarded after a successful
operation, in order to not free something that would have been cleaned
up on error.
--
Daniel Jacobowitz
CodeSourcery
More information about the Gdb-patches
mailing list