Re: [RFA] Ensure result of make_cleanup is never NULL.

Joel Brobecker
2012-04-16T14:40:35Z

> +/* A fencepost used to mark the end of a cleanup chain.
> + The value is chosen to be non-NULL so that make_cleanup never returns NULL,
> + and cause a segv if dereferenced. */
> +#define CLEANUP_FENCEPOST ((struct cleanup *) 1)

Just a tiny idea, not really important, but JIC: Could we use an enum
intead of a define so that GDB prints "CLEANUP_FENCEPOST" rather than
a numeric value when we print a cleanup pointer that's the fencepost?

--
Joel