In case anyone cares, the answer seems to be that you cannot trap an
operator CANCEL using signals. The trick is searching on Sx22. Here is what
the LE P/G has to say:

When TRAP(ON,SPIE) is in effect, Language Environment is notified of abends
and program interrupts. Language semantics, C/C++ signal handlers, PL/I
ON-units, and user-written condition handlers can then be invoked to handle
them. An exception to this behavior is that Language Environment cannot
handle Sx22 abends, even if TRAP(ON) is specified.

An experiment over the weekend verified that this seems to be true.

I might quibble with "cannot"; LE chooses not to process Sx22 ABENDs.

I am exploring establishing my own ESTAE and taking it from there.

Charles

-----Original Message-----
From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On
Behalf Of Charles Mills
Sent: Friday, July 13, 2012 11:07 AM
To: IBM-MAIN@LISTSERV.UA.EDU
Subject: Re: Relationship of C signals to z/OS terminology?

Thanks! That is indeed part of it.

My SIGABND was *not* driven for an operator CANCEL, however. No answer for
what signal if any might be driven by an operator CANCEL.

I guess I am going to have to experiment. Annoying. I will have to build
something just to test this because my "real" program is too likely to make
a mess if cancelled (as it currently stands). 

Not directed at you, Steve, but just in general: it is so easy to respond to
these questions with "RTFM" but it's a heck of a lot easier to point out
information that you already know than to find answers that you don't know.
I searched on signal and cancel, signal and s0c1, etc., etc. The page you
cite of course has the "S0c1" answer, but all the searching in the world
won't find "s0c1" on that page.

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN

Reply via email to