On Wed, Aug 29, 2001 at 11:22:26PM -0500, Kelly Martin wrote:
> On Thu, 30 Aug 2001 13:42:05 +1000, Stephen Robert Norris <[EMAIL PROTECTED]> said:
> >I'd be interested to know how to avoid that. I'm pretty sure I can
> >construct a scenario (with multiple threads and memory mapping, for
> >example) where it's impossible to tell until you get the SEGV. For
> >instance, I memory map a file, pass a pointer into the mapped region
> >into the library and then unmap it some time later from another
> >Even if the library were checking (and I'm not sure how it could)
> >that the pointer points to valid address space, there will be a time
> >gap between the check and the use, and my unmapping can get in there.
> >Having the library install its' own signal handler is not an
> >acceptable solution, either.
> Sounds like a fundamental problem with the UNIX environment design,
It's a fundamental problem with having pointers. If you were restricted
to some sort of object references that the OS controlled (something
like MONADS had, or MULTICS sort of had) then you can avoid the problem.
Otherwise, it's hard to fix.
Stephen Norris [EMAIL PROTECTED]
Farrow Norris Pty Ltd +61 417 243 239
Gimp-developer mailing list