Index: ossp-pkg/pth/ChangeLog RCS File: /v/ossp/cvs/ossp-pkg/pth/ChangeLog,v rcsdiff -q -kk '-r1.628' '-r1.629' -u '/v/ossp/cvs/ossp-pkg/pth/ChangeLog,v' 2>/dev/null --- ChangeLog 2004/10/18 19:35:45 1.628 +++ ChangeLog 2004/12/03 16:17:54 1.629 @@ -21,6 +21,11 @@ Changes between 2.0.2 and 2.0.3 (12-Sep-2004 to xx-xxx-2004) + *) Enhance internal pth_mctx_save() if getcontext(3) is used for the + machine context saving by better emulating the setjmp(3) style + return code semantics. + [Ralf S. Engelschall] + *) Do not break in pth_msgport_find() if a message port was created with a NULL name. [Ralf S. Engelschall] Index: ossp-pkg/pth/pth_mctx.c RCS File: /v/ossp/cvs/ossp-pkg/pth/pth_mctx.c,v rcsdiff -q -kk '-r1.59' '-r1.60' -u '/v/ossp/cvs/ossp-pkg/pth/pth_mctx.c,v' 2>/dev/null --- pth_mctx.c 2004/07/13 10:50:49 1.59 +++ pth_mctx.c 2004/12/03 16:17:54 1.60 @@ -47,6 +47,7 @@ struct pth_mctx_st { #if PTH_MCTX_MTH(mcsc) ucontext_t uc; + int restored; #elif PTH_MCTX_MTH(sjlj) pth_sigjmpbuf jb; #else @@ -69,7 +70,9 @@ #if PTH_MCTX_MTH(mcsc) #define pth_mctx_save(mctx) \ ( (mctx)->error = errno, \ - getcontext(&(mctx)->uc) ) + (mctx)->restored = 0, \ + getcontext(&(mctx)->uc), \ + (mctx)->restored ) #elif PTH_MCTX_MTH(sjlj) && PTH_MCTX_DSP(sjlje) #define pth_mctx_save(mctx) \ ( (mctx)->error = errno, \ @@ -90,6 +93,7 @@ #if PTH_MCTX_MTH(mcsc) #define pth_mctx_restore(mctx) \ ( errno = (mctx)->error, \ + (mctx)->restored = 1, \ (void)setcontext(&(mctx)->uc) ) #elif PTH_MCTX_MTH(sjlj) #define pth_mctx_restore(mctx) \