Re: longjmp handling vs. glibc LD_POINTER_GUARD problems

Pedro Alves
2008-05-14T18:16:47Z

A Wednesday 14 May 2008 19:00:18, Ulrich Weigand wrote:
> I'm now wondering how we should handle this. Should be
> implement an ad-hoc solution to retrieve the guard, which
> may break in the future if glibc changes? Should we require
> use of LD_POINTER_GUARD=0 (which switches off the pointer
> guard mechanism) to enable debugging? Am I overlooking some
> defined interface to get at the value?

No, you're not. There is none. And still
LD_POINTER_GUARD=0 doesn't help when attaching to an already
running target.

> Why are we using the get_longjmp_target mechanism instead of
> just stepping through longjmp until we see where we come out?

You tell me. :-) I had assumed there was a reason. Perhaps
to support longjumping to a different stack, but that's hardly
a portable and frequent use case. This seems to be the path
to go.

--
Pedro Alves