Any advice on problem with longjmp, please

Peter Jackson pedro at stl.stc.co.uk
Thu Mar 30 11:12:48 AEST 1989


I have some software developed for a range of different flavours of Unix,
including Sun, which contains a lightweight tasking package; it was
developed under Sun 3.x and so does not contain the sun lightweight
tasking, nor for portability reasons do I wish to convert it to use the
same.

The package `malloc's stack areas, and then uses setjmp and longjmp to
switch between tasks/stacks.  This seemed to work fine on the developers
machine, but on our 4.0.1 system produces illegal instruction errors in
longjmp when I try to restore a previously saved context from setjmp.  I
wonder if longjmp is performing some checking of the stack area or
something like that.

Does anyone know anything about this -- has longjmp changed in 4.0/4.0.1,
is there a fix??

     Peter Jackson
     STC Technology, London Road, Harlow,UK (+44 279 29531)



More information about the Comp.sys.sun mailing list